-
-
Notifications
You must be signed in to change notification settings - Fork 541
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
Grade school exercise: A student cannot simultaneously be in two grad… #1735
Merged
SleeplessByte
merged 1 commit into
exercism:master
from
pedrorolo:grade-school-new-test-only-one-grade-per-student-because-student-names-are-unique
Dec 11, 2020
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that this isn't a valid version 4 UUID (because the first character in the third group is
1
, not4
).It looks like all the other UUIDs in
problem-specifications
are valid version 4 UUIDs.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we have the limitation of it being a v4. 😬
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think for v3 we wanted to use v4 I think, but I don't know why anymore 🤷 @iHiD might know
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Someone can PR a change for this one. I don't necessarily think there's much value in forcing it to be totally random (instead of also using date-time and MAC address). The purpose is to be unique, and that it still is 🥇
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, it's not currently in the
problem-specifications
CI, or inconfiglet lint
. But I think it should be. As I understand it, we'll fix the (not-so-unique)uuid
s that are duplicated between tracks. So I think we might as well enforce a consistent format foruuid
s on track repos at the same time. Currently, about 2% ofuuid
s on Exercism are not valid version 4 UUIDs that are also lowercase.It's true that there isn't a meaningful difference in the collision probability, but UUID version 4 is the right version for a randomly generated UUID. It's also what
configlet uuid
generates (in both in the v2 and v3 versions ofconfiglet
), and every otherproblem-specifications
uuid
is version 4.Furthermore, a reader who is familiar with RFC 4122 might see a version 1 UUID and assume that the timestamp component is useful, causing them to wonder why the others are version 4.
I'll do that, but we'd also have to PR to any track that adds the old UUID to a
tests.toml
file. So far, that's only on thejavascript
track here. I'll PR there too.True. But we shouldn't go too far with that argument - otherwise it implies that we should merge a
uuid
that looks like this. That is the most uniqueuuid
, though :)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that's a good point!
Sweet thanks! I'll ✅ the PR if you ping me, and lets have reviewers ✅ it to, as to reduce the amount of tracks that will need to do this.
😏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd quite like to have
${PREFIX}-${v4 UUID}
everywhere. Where the prefix signifies the context (e.g. this would bePSTC
(Problem specs test case) or similar)