I downloaded rational-numbers in CLI (exercism download --track=julia --exercise=rational-numbers) and found that no solution template file rational-numbers.jl appeared. This is because in this repository, the file exercises/practice/rational-numbers/rational-numbers.jl is existing, but empty.
There are twenty exercises with empty or whitespace solution files. In the online editor, this opens a blank file with the correct filename - not a problem - , but via CLI exercism download the file unexpectedly does not appear, causing minor inconvenience and confusion as the user may think the download is incomplete. The user then has to create the solution file with the correct filename, inconsistent with most exercises.
Is this a problem? I can add a function template to each.
I can guess at the rationale: since this is a “hard” exercise, by the time students are tackling rational-numbers, they are familiar with reading the tests and can figure out what the Julia solution file needs to contain.
Just my opinion. The track experts obviously have the final say.
The recommendation in the Exercism docs is for the stub to have enough starter code that a student can begin writing the logic although that does vary from track to track. I do provide the barebones function definitions on my own tracks.
Blank stub files are not a policy, either for Exercism or for the Julia track. Unfortunately, we failed to notice that these very old files have been blank for many years. Thank you for bringing it to our attention!
I’ve copied the formatting guidelines below, for reference (revised quite recently by @depial). We’re not very prescriptive about practice exercises (like Rational Numbers), but the stub file should at least contain a comment, and my own bias is for a function skeleton.
If you would like to submit a PR, we would be very happy to review it.
stub.jl
The solution file stub.jl takes the exercise name by default, in kebab case if necessary (e.g. exercise-name.jl).
The content of concept exercise stubs have function skeletons by default, (some of) which can be omitted if the exercise emphasizes manual coding of new concepts.
The content of practice exercise stubs is left to the discretion of the author.
When function skeletons are provided, they should include a blank new line with a four space indentation for the body.
function fun1(arg1)
end
function fun2(arg2, arg3)
end
Although the exercises with blank stubs are from before my time, from a pedagogical standpoint, I’m fine with leaving some of them blank, for the reasons @glennj pointed out.
That said, the stub not appearing when downloading through the CLI is something I was unaware of and seems to be an issue worth addressing, so I’m with @colinleach on being open to reviewing a PR.
Yeah, if we can independently confirm this behavior, that should be a separate thread for discussion. The exercism CLI should be pulling down the stub regardless of its contents.