Courses in nbgrader have the course_id property with several limitations (at least URL safe if used with JupyterHub). Would be great to have an additional property course_title. At the moment course list extension and assignment list extension show course_id to users (instructors and students). Showing a course_title would allow for whitespace, special characters, Unicode aso. in GUI.
Concrete use case: We (a small team at a university) are working on LMS integration of JupyterHub and nbgrader based on LTI. Coming to JupyterHub from the LMS our scripts and tools automatically sync course structures and enrolement lists from LMS to nbgrader. At the moment we have to convert LMS course titles to nbgrader course IDs losing information (if the LMS title is in Chinese, generating an equivalent nbgrader ID is almost impossible). Having identical titles in LMS and nbgrader would improve user experience and acceptance of the system.
Some details/ideas on how to implement this:
If running multiple formgrader services on a JupyterHub, one might add something like
c.NbGrader.course_titles = {
'course_1': 'Mathematics I for Engineers',
'course_2': 'Mathematics II for Engineers'
}
to global nbgrader config file.
If running with a local formgrader (no JupyterHub), then
c.CourseDirectory.course_id = 'testcourse'
c.CourseDirectory.course_title = 'My Test Course'
in the user's nbgrader config file would be reasonable.
The course list server extenion's formgraders API endpoint returns a list of course dicts. Each dict would get an additional item course_title based on above config values.
The course list labextension (and also nbextension) then use course_title instead of course_id from the API endpoint's dicts.
I've implemented above ideas and it works quite well. Similar should be possible for assignment list extension (not implemented yet).
If next to me there are other people looking for better course titles in nbgrader, I could make a PR. But not sure whether there are better ideas how to implement such a feature than mine.
Courses in nbgrader have the
course_id
property with several limitations (at least URL safe if used with JupyterHub). Would be great to have an additional propertycourse_title
. At the moment course list extension and assignment list extension showcourse_id
to users (instructors and students). Showing acourse_title
would allow for whitespace, special characters, Unicode aso. in GUI.Concrete use case: We (a small team at a university) are working on LMS integration of JupyterHub and nbgrader based on LTI. Coming to JupyterHub from the LMS our scripts and tools automatically sync course structures and enrolement lists from LMS to nbgrader. At the moment we have to convert LMS course titles to nbgrader course IDs losing information (if the LMS title is in Chinese, generating an equivalent nbgrader ID is almost impossible). Having identical titles in LMS and nbgrader would improve user experience and acceptance of the system.
Some details/ideas on how to implement this:
to global nbgrader config file.
in the user's nbgrader config file would be reasonable.
formgraders
API endpoint returns a list of course dicts. Each dict would get an additional itemcourse_title
based on above config values.course_title
instead ofcourse_id
from the API endpoint's dicts.I've implemented above ideas and it works quite well. Similar should be possible for assignment list extension (not implemented yet).
If next to me there are other people looking for better course titles in nbgrader, I could make a PR. But not sure whether there are better ideas how to implement such a feature than mine.