Fix how students are deduplicated #70123
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This work was done in collaboration with Liam!
This addresses a problem Teacher Tools has run into occasionally on our progress page, both in the "legacy" and V2 views.
In legacy view, this would show up in some sections when toggling over to level view. While scrolling down the page would suddenly break and show the below error.

In V2, the progress view would just constantly show "loading" skeleton as the data would constantly load and re-load.
The "fix" was always to add or remove one student from the section. This would fix the errors, but was not the ideal user experience
We were able to re-create this issue locally. It seems like the issue is able to be re-created if you put 60 students all with the same name in the section AND give progress to one of the students. We suspect that this issue was revealing itself in production when a section:
The fix here is to modify how we "deduplicate" students so we rely solely on ID.
Links
Jira ticket
Thread
Testing story
Deployment strategy