Fix missing prerequisite edges for units using enrolment_rules#6
Open
coldfinity wants to merge 1 commit into
Open
Fix missing prerequisite edges for units using enrolment_rules#6coldfinity wants to merge 1 commit into
coldfinity wants to merge 1 commit into
Conversation
…ent_rules 211 units (MTH2021, MTH2010, and others across Science, Pharmacy, and Education) store their PREREQUISITE and PROHIBITION relationships as HTML prose in enrolment_rules rather than the structured requisites field. This left requisite_refs empty for those units, so the tree graph showed no edges and "what does X unlock" views omitted them entirely. Fix the ingest pipeline to also extract unit code refs from enrolment_rules descriptions that carry a <strong>PREREQUISITE</strong> or <strong>PROHIBITION</strong> label with handbook unit links. Add a data migration (0007) to backfill all existing years — inserting 4,496 new prerequisite refs and 1,683 prohibition refs. Also fix a bug in requisite-tree-view where the units map title lookup was computed but leaf.academic_item_name was still rendered instead of the resolved name. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
@coldfinity is attempting to deploy a commit to the monash-coding's projects Team on Vercel. A member of the Team first needs to authorize it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
enrolment_rulesrather than the structuredrequisitesfield. This leftrequisite_refsempty for those units, so the tree graph showed no edges and "what does X unlock" views omitted them entirely.enrolment_rulesdescriptions that carry a<strong>PREREQUISITE</strong>or<strong>PROHIBITION</strong>label with handbook unit links.0007to backfill all existing years — inserting 4,496 new prerequisite refs and 1,683 prohibition refs.requisite-tree-viewwhere theunitsmap title lookup was computed butleaf.academic_item_namewas still rendered instead of the resolvedname.Test plan
/tree?unit=MTH1030&direction=downstream— MTH2021 and MTH2010 now appear as nodes