Skip to content
This repository has been archived by the owner on Jun 30, 2024. It is now read-only.
This repository has been archived by the owner on Jun 30, 2024. It is now read-only.

Error handling in questions_report #1470

Closed
bnmnetp opened this issue Jul 11, 2020 · 6 comments
Closed

Error handling in questions_report #1470

bnmnetp opened this issue Jul 11, 2020 · 6 comments

Comments

@bnmnetp
Copy link
Member

bnmnetp commented Jul 11, 2020

I'm getting the following crash. when trying to view the assignment table

Traceback (most recent call last):
  File "/home/bmiller/Runestone/web2py/applications/runestone/controllers/assignments.py", line 1112, in grades_report
    auth.user.course_name, request.vars.chap_or_assign,
  File "/home/bmiller/Runestone/web2py/applications/runestone/modules/questions_report.py", line 585, in query_assignment
    None,
KeyError: 'epearson'

The epearson in question should be a student in the course.

I think this brings up two potential improvements.

  1. make sure grades contains a key before we use it.
  2. in the populateAssignmentTable function we should check for data.errors before we iterate. This way we can report to the user that something bad happened and ask them to report it rather than leaving them hanging with Loading...
@bjones1
Copy link
Contributor

bjones1 commented Jul 11, 2020

Will do. Is there any way I can recreate this? Or would you allow me to either run queries on your db, or run queries for me? I'd like to understand how this user didn't get found by the two queries in _headers_query and how to fix that.

@bnmnetp
Copy link
Member Author

bnmnetp commented Jul 11, 2020

I'm happy to run the queries for you, even be on zoom and running so we can discuss in real time while doing so.

@bjones1
Copy link
Contributor

bjones1 commented Jul 11, 2020

Wonderful! I'll put together some notes then find a time. Thanks!

@bjones1
Copy link
Contributor

bjones1 commented Jul 13, 2020

When are you free to do some debug?

@github-actions
Copy link

Stale issue message

@github-actions
Copy link

Stale issue message

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants