Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create stub files for all exercises #365

Closed
kytrinyx opened this issue Aug 3, 2019 · 4 comments
Closed

Create stub files for all exercises #365

kytrinyx opened this issue Aug 3, 2019 · 4 comments
Assignees

Comments

@kytrinyx
Copy link
Member

kytrinyx commented Aug 3, 2019

We have decided to require all file-based tracks to provide stubs for their exercises.

The lack of stub file generates an unnecessary pain point within Exercism, contributing a significant proportion of support requests, making things more complex for our students, and hindering our ability to automatically run test-suites and provide automated analysis of solutions.

We believe that it’s essential to understand error messages, know how to use an IDE, and create files. However, getting this right as you’re just getting used to a language can be a frustrating distraction, as it can often require a lot of knowledge that tends to seep in over time. At the start, it can be challenging to google for all of these details: what file extension to use, what needs to be included, etc. Getting people up to speed with these things are not Exercism’s focus, and we’ve decided that we are better served by removing this source of confusion, letting people get on with actually solving the exercises.

The original discussion for this is at exercism/discussions#238.

Therefore, we’d like this track to provide a stub file for each exercise.

  • If this track already provides stub files for all exercises, please close this issue.
  • If this track already has an open issue for creating stubs, then my apologies. Please close one as a duplicate.
  • Otherwise, please respond to this issue with useful details about what needs to be done to complete this task in this track so that people who are not familiar with the track may easily contribute.
@guygastineau
Copy link
Contributor

@kytrinyx thank you for letting us know.

I have a couple questions. Our current testing software does not test individual functions, but rather the execution of their script. Because of this it is typically inappropriate for use to provide unimplemented function (there are many solutions where functions are overkill).

Do you find it suitable for our stub files simply to include:

  1. header, ie. 'this is a stub file for you implementation'
  2. Generic Instructions, ie. 'bash is flexible. You can write your code in functions or as a raw script. Keep in mind that more complicated solutions can greatly benefit from functions.'

Essentially, I want our stubs to be general advice/expectations like that, because we only enforce CLI argument interfaces, but the internal implementation is entirely up to the student.

We have talked about testing our exercises as libraries before, but we still aren't ready to make that shift.

Anyway, sorry to be long winded. I just want to confirm that these minimal stubs will acceptable under the new standard. Thank you for your time; I look forward to receiving your feedback.

@guygastineau
Copy link
Contributor

guygastineau commented Aug 3, 2019

For the time being I am going to move forward with the idea of these general stub files until we have resolved #366

This file is a template we already have example.sh. We don't use a template for our example implementation, so I would like to rename it to stub_template. I also will remove the unnecessary set options at the head and revise the contents to suit our purposes.

@kotp @glennj what do you all think of this? Once we've agreed on this revision I will apply it to all of our exercise directories. I will also link to this issue from the PR.

@kytrinyx
Copy link
Member Author

kytrinyx commented Aug 3, 2019

Do you find it suitable for our stub files simply to include:

Yeah, totally. In a language where there really isn't much to it, the stubs can be as simple as they need to be. We mainly want consistency across the board, and a way to reduce/eliminate support requests where necessary.

Thank you for the question. I'm really grateful that you've already taken some time to think through this!

@guygastineau
Copy link
Contributor

No problem. I have a proposal for our exercise_stub up, and pending approval I can just apply it with a script. At least we will have them in place while we are transitioning to a testing system that requires specific stubs 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants