PolicyEngine / PolicyEngine/microcosm
Scorer reform-vector cache lane needs a real mode digest (advisory from #557 round 3)
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 0
- Forks
- 4
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 94
Description
From the #557 round-3 confirm, advisory severity — scorer-only, no release exposure. The explicit-None materializer declaration separates scorer vectors from release vectors, but within the scorer lane two collision routes remain: (1) --legacy-pe-flat-h5 changes frame loading but is absent from the retained cache keys, so a doubly-readable/hybrid H5 can share every retained key while producing different frames; (2) state-file vectors are positional while collection hashing sorts state names but concatenation uses tuple order. Fix shape: replace the bare None with a scorer/mode digest (loader mode + ordered collection identity) so the declaration is a complete identity rather than a lane tag. Cites: tools/score_us_fiscal_targets.py / tools/score_us_state_files.py cache-context blocks; PR #557 round-3 review.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing the cache-context blocks in tools/score_us_fiscal_targets.py and tools/score_us_state_files.py, then trace how loader mode and collection ordering enter the retained keys. Done means the scorer declaration uses a mode digest covering the loader mode and ordered collection identity, preventing both described collision routes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100