PolicyEngine / PolicyEngine/policyengine-core
Test that country packages don't have formulas with entity mismatches
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 22
- Forks
- 30
- Avg merge
- 14h 33m
- Merged PRs (30d)
- 7
Description
We've had several undetected crashes arising from formulas that mix up entity types, resulting in this type of error:
ValueError: operands could not be broadcast together with shapes (100000,) (279932,)
For example, https://github.com/PolicyEngine/policyengine-us/issues/3298
Let's test for this centrally.
@martinholmer could you share the command you executed in that issue to throw the error?
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
Review the linked PolicyEngine US issue and obtain the command requested from the issue thread. Then inspect policyengine-core's existing test entry points to determine where a centralized check belongs. Done means country packages are checked for formulas that combine mismatched entity types and the failure is covered by an automated test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100