TA debugging online submissions
From 6.034 Wiki
This is a page of commonly encountered errors related to the online tester.
"Error: Either your key.py file is out of date, or online tests for lab0 are not currently available"
This is usually caused by an out-of-date key.py file, which is sometimes a result of the student changing their Athena password. However, if you believe it might be a server error or something more complicated, ask the student comment out the except block in tester.py starting with except xmlrpclib.Fault: (for Lab 0, this is lines 250-254 of tester.py), then try submitting again. This should result in an error traceback (printed in the command line). The end of the error traceback should say something like:
-
"<class 'tester.test.testutils.AuthenticationFailure'>:Error: invalid username or password. Please make sure your key.py file is up-to-date."
- This indicates an authentication problem, which could be caused by:
- out-of-date key.py due to student changing their password
- out-of-date key.py due to student using an expired certificate
- the database was reset, invalidating all previous key.py files (this should only happen when the database is cleared, which is unlikely to occur during a semester)
- If the student has tried re-downloading their key.py file and it didn't work, it's possible to manually update their password in the database so that their key will authenticate correctly. Instructions (may require superuser privileges):
- Go to a SHA1 hash generator such as [1].
- Open the student's key.py file in a text viewer and copy/paste the PASSWORD string (without the quotes) in the input string field.
- In the Django database, open the student's user page. (This is the step that may require superuser privileges.)
- In the Django database user page, find the Password field, which should look something like sha1$ac536$de872b11de91b01489ca980abeb89c0c9ed04463. The password is in the form [algo]$[salt]$[hexdigest]. Copy/paste the 5-character "salt" string into the "salt" field of the hash generator. If applicable, select the option of adding the salt before the string (not after).
- Copy the result from the hash generator. Delete the existing "hexdigest" portion of the student's Django password and paste the hashed result in its place.
- Click Save on the Django page.
-
"<class 'tester.test.models.DoesNotExist'>:Lab matching query does not exist."
- This means the server is not currently accepting submissions. This is probably a Django database issue (the "lab" object (e.g. "lab0") is missing in the database).