Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unbreak AP/IB requirement computation #411

Merged
merged 1 commit into from
Mar 31, 2021
Merged

Unbreak AP/IB requirement computation #411

merged 1 commit into from
Mar 31, 2021

Conversation

SamChou19815
Copy link
Contributor

Summary

This bug is introduced during my live coding session. In that change, I will remove all edges when there is no user choice associated with a unique ID. However, I forget to consider the case when all the AP/IB equivalent courses all have the same unique ID -1. If we do the same for AP/IB courses, then all these courses will never be able to fulfill anything.

Therefore, we must bail out when uniqueID == -1.

Test Plan

Added a regression test about this bug.

Notes

This change will fix #397.

@SamChou19815 SamChou19815 requested a review from a team as a code owner March 31, 2021 03:37
@dti-github-bot
Copy link
Member

[diff-counting] Significant lines: 23.

@github-actions
Copy link
Contributor

github-actions bot commented Mar 31, 2021

Visit the preview URL for this PR (updated for commit a2b4a97):

https://cornelldti-courseplan-dev--pr411-unbreak-ap-ib-p3x30cjq.web.app

(expires Wed, 07 Apr 2021 03:50:29 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Copy link
Collaborator

@benjamin-shen benjamin-shen left a comment

Choose a reason for hiding this comment

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

That makes sense. Thanks Sam!!

src/requirements/requirement-graph-builder.ts Outdated Show resolved Hide resolved
@SamChou19815 SamChou19815 merged commit 73052b5 into master Mar 31, 2021
@SamChou19815 SamChou19815 deleted the unbreak-ap-ib branch March 31, 2021 03:50
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.

Incorrect courseplan AP credit logic
3 participants