Skip to content

Comments

make grades page show true problem number#2912

Open
Alex-Jordan wants to merge 1 commit intoopenwebwork:developfrom
Alex-Jordan:grades-problem-number
Open

make grades page show true problem number#2912
Alex-Jordan wants to merge 1 commit intoopenwebwork:developfrom
Alex-Jordan:grades-problem-number

Conversation

@Alex-Jordan
Copy link
Contributor

Suppose there is an assignment with exercises that were originally numbered 1-10. Then an instructor deleted numbers 2 and 7, and did not renumber the problems in the assignment. Prior to the change here, the grades page shows scores for "number 1" through "number 8". But of course, "number 8" is labeled "number 10" when the student visits the set, and so on.

So this change makes it so that in the Grades page, the score for "number 10" is under the 10 column, and so on. In columns 2 and 7, there will be an empty cell.

So it will be with regular sets and jitar sets. But this PR should not change anything with tests. For those, it's too complicated to try to change the current behavior because of how exercises can be presented in a random order. I'm not even sure that other things don't break if an instructor deletes an exercise from a test template or test version. If someone thinks this should happen with tests as well, I will need help making that happen.

This is a preliminary PR so that later, I can make the cells link to the problem number in question.

@drgrice1
Copy link
Member

This definitely should not do this for tests. Note that in tests the problems are ALWAYS displayed for the student in consecutive order in the actual test regardless of the problem_id in the database and set definition. So they should be displayed that way on the grades page as well. This is true for the case that a problem was deleted (for example, if in the set definition the problem ids are 1, 3, 4) or the case that the problems are displayed in random order.

@drgrice1
Copy link
Member

My wording was not concise, so I want to clarify further. If the problem ids are 1, 3, 4 in the set definition, then in the test the problem numbers are shown as 1, 2, 3. They are displayed not only consecutively, but incrementally starting from 1.

The point is that the current numbering on the grades page is already consistent with the numbering that is shown for students in the test itself.

Comment on lines +194 to +195
# For other sets we just get the largest problem ID.
$max_problem_id = max($db->listGlobalProblems($setID));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is going to need to be a special case for tests that does what the previous else case did for those. For example, if a test has numbers 1, 3, 5, then this will get 5 for the largest problem id. However, the problems will be displayed under numbers 1, 2, and 3 (on both the grades page and in the test). So this may add extra problem numbers that are shown even though there may not be any sets with those problem numbers.

@Alex-Jordan
Copy link
Contributor Author

Alex-Jordan commented Feb 17, 2026 via email

@Alex-Jordan
Copy link
Contributor Author

I'm changing this so that the top row will only use problem labels that are actually used. For example, if all sets in the course have had the 3rd problem cut, then the numbering at the top row will be 1, 2, 4, ...

Is there any concern with that?

@drgrice1
Copy link
Member

Sounds appropriate.

Although with your setup of using text book numbering, it seems that might not help if the numbers happen to vary widely between sets.

@Alex-Jordan
Copy link
Contributor Author

Yeah, I'm prepared for that. It won't be quite as bad as I made it sound. The assigned problems are always even numbered, and there are at most 120 problems from any given section. So I think it may come to something less than 50 numbers in use.

@somiaj
Copy link
Contributor

somiaj commented Feb 18, 2026

@Alex-Jordan We did talk a bit about this page could use a full overhaul, would there be a better way to present things? Is a table really appropriate for sets that have different number of problems, there are lots of empty cells. Also how accessible is one of these cells, is <span class="name">attempts</span><br>grade going to make much sense in its current output to a screen reader. Is it really that useful to have attempts on a grade page for a student? Might be useful for the student progress page for instructors to see how many attempts students are taking, but maybe the grades page for students shouldn't include attempts, only grade.

So if you have any ideas on how to restructure the page to be more useful for students, that might be worthwhile vs trying to tweak the existing layout.

@Alex-Jordan
Copy link
Contributor Author

Alex-Jordan commented Feb 18, 2026 via email

@Alex-Jordan
Copy link
Contributor Author

Alex-Jordan commented Feb 18, 2026 via email

@Alex-Jordan
Copy link
Contributor Author

Alex-Jordan commented Feb 18, 2026 via email

@somiaj
Copy link
Contributor

somiaj commented Feb 18, 2026

@Alex-Jordan One of the ideas that came up was remove the grades page from students. The info you want is already on the ProblemSet page, but not in one place. Also the grade page is kinda ordered poorly for this.

so one though, was just put the percent grade on the main Assignments page, then students can see the % of what is currently open or in the reduced scoring period, and if it isn't 100%, they can click on it and then see exactly which problems they have left to finish.

@dlglin
Copy link
Member

dlglin commented Feb 18, 2026

@Alex-Jordan One of the ideas that came up was remove the grades page from students. The info you want is already on the ProblemSet page, but not in one place. Also the grade page is kinda ordered poorly for this.

so one though, was just put the percent grade on the main Assignments page, then students can see the % of what is currently open or in the reduced scoring period, and if it isn't 100%, they can click on it and then see exactly which problems they have left to finish.

Current brainstorm: could we add the ability to filter/sort the homepage based on incomplete assignments? I'm envisioning that the student clicks something and only assignments where they can still receive credit are shown, or are percolated to the top.

A variation of this would be to add another category on the homepage for "Completed Assignments", which would contain any sets where for every question the student has either achieved the maximum available credit (taking into account reduced scoring) or has used all of their attempts. This way the only things showing in "Open Assignments" would be things where they can still improve their grade.

@Alex-Jordan
Copy link
Contributor Author

What about assignments that are closed, but the student could use an achievement item to reopen or award credit?

@Alex-Jordan
Copy link
Contributor Author

My initial reaction to putting the grades on the assignments page is concern about privacy. Whatever the design might end up there, I'd want to look for a way where the student has to actively click something to reveal grades. So they aren't just showing by default when the student is in a computer lab or something like that.

@dlglin
Copy link
Member

dlglin commented Feb 18, 2026

What about assignments that are closed, but the student could use an achievement item to reopen or award credit?

This would be consistent with the current layout. Students can apply achievement items to sets in the "Past Due Assignments" section to move them back to "Open Assignments".

@somiaj
Copy link
Contributor

somiaj commented Feb 18, 2026

Grades are also shown on the ProblemSet page, and the current problem they are working on, so though I agree with your privacy concern remark, what makes the assignments page special in this regard, when grades are shown in plain view elsewhere.

I had a few more thoughts, though first the reason we thought about just putting the grade info on the assignments page, is as we thought about how to arrange/display things on the grade page, lots of thoughts would be a similar layout as to what is on the assignments page plus adding grades. So if the grade page looks almost identical to the assignments page with grades added, the idea of is it worth having two pages came up.

I too thought about the idea of making adding a 'complete' / 'incomplete' message to assignments based on if their grade is the maximum it can be or if they are out of attempts. I might have time in a few weeks to work on something, but the next two weeks I'm fairly swamped.

@somiaj
Copy link
Contributor

somiaj commented Feb 19, 2026

Here is a very rough workup of what a grades page could look like. It is mostly just a rough idea, there is a lot that would need to be done. somiaj/new-grades-page

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants