question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Command-line autograde assignments don't appear in formgrade web app

See original GitHub issue

I’ve been using nbgrader + JupyterHub for an introductory course the past couple of years, and in that time both platforms have seen extensive and backwards-incompatible architectural changes; I think I’ve stumbled upon another one.

Over the past few days, I’ve gone through the process of releasing, collecting, and autograding my first assignment, all via the command line:

nbgrader release A1
nbgrader collect A1
nbgrader autograde A1

However, when I click the “Formgrader” tab, I don’t see any assignments listed. Furthermore, none of my students appear there, either (I manually entered both them and the assignments into the nbgrader_config.py file at the start of the course). I feel like I may have missed a step in the configuration process.

Operating system

Ubuntu 16.04

nbgrader --version

0.5.4

jupyterhub --version (if used with JupyterHub)

0.8.1

jupyter notebook --version

5.5.0

Expected behavior

I’d expected to see the assignments (at least the autograded one, after running the aforementioned sequence of command-line options) listed in the formgrader web app.

Actual behavior

No assignments (or students) are listed.

Steps to reproduce the behavior

The nbgrader commands I listed out before were not done seconds after the other; the assignment was released last week, and I just collected and autograded them this morning (via command-line). Then, intent on fixing some grades manually, I went to the Formgrader tab and discovered it was empty.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
jhamrickcommented, Jul 7, 2018

My first thought is what’s going on is that you don’t have the nbgrader root directory properly configured in a way that the notebook server is able to understand. In particular, when you launch the notebook server, it will look for a nbgrader_config.py file in the current directory (or in the default Jupyter config paths, which you can find using jupyter --paths). If those nbgrader_config.py file(s) do not specify the config option for c.CourseDirectory.root = '/path/to/your/coursedir'.

This is documented in the JupyterHub config docs (https://nbgrader.readthedocs.io/en/stable/configuration/jupyterhub_config.html) but not for regular usage of nbgrader. There should probably be some instructions to this effect here: https://nbgrader.readthedocs.io/en/stable/user_guide/creating_and_grading_assignments.html#accessing-the-formgrader-extension

Can you try setting the root config and let me know if that fixes the problem?

0reactions
ttimberscommented, Jan 23, 2019

In the meantime, I’ve somehow fixed things. I think it was because I went ahead and copied over the gradebook.db file to the home user directory (that the formgrader seemed to want to point to), then suddenly it seemed aware of the main course directory. I could even delete all the course-specific folders I mentioned hard-copying over from the course directory to the home user directory, as well as the gradebook.db file itself (the one I’d copied), and the formgrader is still clearly pointing to the right course folder.

I’ll need to try and replicate this behavior later.

I can confirm that I just replicated a similar behaviour. On my laptop, gradebook.db needs to be in the root of the nbgrader directory (that has source, release, etc) but on the JupyterHub server, it needs to be one directory above that…

Read more comments on GitHub >

github_iconTop Results From Across the Web

Creating and grading assignments - nbgrader - Read the Docs
Instructions on how to manage assignments in the database from the command line. nbgrader db assignment add. Command line options for nbgrader db...
Read more >
Help | Gradescope
Save time grading your existing paper-based assignments and see exactly what your students learned, for free.
Read more >
How to fix NOT TURNED IN problem? - Google Classroom ...
It is likely because of the device they are using. When they submit the form, Classroom is not registering it as "turned in"....
Read more >
Grade, return, and reassign assignments - Microsoft Support
Their name will now show up in the Returned list. Their assignment status in the Grades tab will update, too. Return button with...
Read more >
Assignments FAQ - Introduction to Computer Science
Short videos on how to use basic command line commands: Linux/MacOS · Windows. Autolab. The web based automated grading tool used in programming...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found