Repository navigation
Conversation
PR Summary by QodoImprove course filters and surface unavailable cutoffs
AI Description
Diagram
High-Level Assessment
Files changed (4)
|
Code Review by Qodo
1. Cutoff tab always empty
|
| const cutoffUnavailable = useMemo( | ||
| () => [...(res?.groups?.cutoffUnavailable ?? [])].sort((a, b) => a.courseName.localeCompare(b.courseName)), |
There was a problem hiding this comment.
1. Cutoff tab always empty 🐞 Bug ≡ Correctness
The UI reads a new groups.cutoffUnavailable array, but the checker backend still returns only eligible and notEligible and places missing-cutoff recommendations in notEligible. Consequently, the new tab always shows zero courses while NQC/new courses remain under Non-Eligible.
Agent Prompt
## Issue description
The frontend introduces a `cutoffUnavailable` recommendation group, but the backend response does not define or populate it. Courses that meet handbook requirements but have no district cutoff are therefore returned under `notEligible`, leaving the new tab empty.
## Issue Context
Keep frontend and backend response contracts aligned. During backend grouping, place recommendations where `meetsHandbookRequirements` is true and `officialCutoff` is null into `cutoffUnavailable`, and include that group in the response type, initialization, and sorting/tests.
## Fix Focus Areas
- frontend/src/api/checker.ts[102-140]
- frontend/src/components/checker/checker-results.tsx[251-278]
- backend/src/db/official-handbook-query.ts[116-127]
- backend/src/db/official-handbook-query.ts[474-478]
- backend/src/db/official-handbook-query.ts[531-540]
- backend/src/db/official-handbook-query.ts[596-620]
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools
No description provided.