-
Notifications
You must be signed in to change notification settings - Fork 481
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
Show multiple versions of csd course in EditSectionForm #22113
Conversation
…d include version metadata
This reverts commit cfe58ff07a3268592607d62c77336375b98d679a.
…ry assignment" dropdown
…g all hidden scripts
FYI @poorvasingal , mostly to see that things are happening, but also to review the insidious terminology comparison spreadsheet |
8a4c5f2
to
ce3c64b
Compare
13e302c
to
1786742
Compare
@islemaster I should add that I'm actively soliciting better names for "assignment group" (e.g. "all versions of the CSD course"). I don't like any of the names I've come up with, but in case any of them help inspire you, here are the alternatives I've considered:
|
Stream-of-consciousness on terminology: There's a partial fit here with terminology for car models, model years and design revisions; it's too bad 'model' is taken in our namespace. My one takeaway from this idea is that I like 'revision' a little better than 'version' in this context, and having a hard time saying why - there's no agreement on how the two terms are different, but outside of software 'revision' seems to be associated with annual releases and incremental improvements. It's also less likely to collide with how we usually talk about software versions. It looks like one of the gaps is an umbrella term for courses and scripts. I like "assignable" better than "assignment" but either might still be too generic. AFAIK we're not using "curriculum/curricula" as an exact term anywhere, and this might be an appropriate place for it. Of course, I tend to be overly verbose in all things, so consider this food for thought and not a finalized proposal:
|
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.
Awesome work in a very tangled system. Now that I understand the terms, changes LGTM.
…ntry for it in the assignment family dropdown
|
||
// If our current secondaryId is in this course, default to that |
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've removed the behavior which did the following -- when a section is assigned to a course and unit, and you change the primary assignment to something else and then back again, try to set the secondary assignment back to the originally assigned unit.
strangely, this was passing in unit tests but not working end to end. This is because the reportChange
method caused redux to clear the assigned script id, which doesn't happen in the unit test on the unconnected component.
Apologies for all the commit spam, @islemaster . I believe this is ready to go now. If you'd feel guilty not re-reviewing, you can probably focus on 9008231 and 0cf32e6 which make sure that users assigned to e.g. csp1 but not csp will have csp1 added back to the assignment family dropdown. Just for fun, I counted and there are 331 users in prod assigned to scripts csp1-6 or csd1-6 but not the corresponding course, whom this would affect. |
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.
👍
@@ -15,11 +15,17 @@ const noAssignment = assignmentId(null, null); | |||
const decideLater = '__decideLater__'; | |||
const isValidAssignment = id => id !== noAssignment && id !== decideLater; | |||
|
|||
const hasAssignmentFamily = (assignmentFamilies, assignment) => ( | |||
assignment && !!assignmentFamilies.find(assignmentFamily => ( |
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.
Nit: array.some(predicate)
would be more idiomatic here than !!array.find(predicate)
.
Background
Description
Show multiple versions of the CSD course in the EditSectionForm component, which is visible when creating or editing a section from the teacher homepage.
before:
after:
Terminology
It's worth calling out that the terminology in this part of the product is not very good at all. See spec for product terminology. Also see terminology comparison spreadsheet for my desperate attempt to make sense of it all.
Under the hood
Although the visible difference is minimal, this required the following changes under the hood:
Caveats
base_nameassignment_group_name, version_year) are "fudged". for courses, these are derived from the course name (tbd whether this will change in the future). for scripts, we assume the year is 2017 and that the assignment_group_name is equal to the script name (this will definitely change in the future).script
s (code term) csd2-2018, csd3-2018, etc will show up under thecourse
csd-2018. If we can unhide these scripts before launch, then this behavior can be removed before the experiment is launched, as described in comments. if not, we'll need to find a way for valid_scripts to return only the hidden scripts associated with additional course versions. Poorva will get back to us on whether this is necessary.