Model the 2025 Canada Workers Benefit secondary-earner exemption
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 52/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- python
- Domain
- backend, fintech-quant
Research direction
Start by locating the existing general Canada Workers Benefit implementation referenced by issue #9 and read the CRA Schedule 6 Step 2 source linked in this issue. Trace the AFNI and reduction calculations, then add coverage for the standard, Alberta, Quebec, and Nunavut schedules; done means the exemption selects the lower earner and respects all stated caps without producing zero for an eligible spouse.
Written by the indexing model from the issue text.
Description
Problem
PolicyEngine Canada does not model the secondary-earner exemption used in the
2025 Canada Workers Benefit calculation. A repository search for
secondary_earner and equivalent terms returns no implementation.
CRA Schedule 6 Step 2 allows an eligible-spouse family to deduct up to $16,386
of the lower earner's qualifying amount from adjusted family net income. Without
this step, the final CWB amount is not comparable to the 2025 CRA calculation.
The older general CWB implementation issue was #9.
Scope
- Add the 2025 secondary-earner exemption parameter.
- Identify the secondary earner from claimant and eligible-spouse working
income. - Cap the exemption by the secondary earner's working income, adjusted net
income, and the published maximum. - Subtract the exemption from adjusted family net income before applying the
basic CWB and disability-supplement reductions. - Preserve an explicit pre-exemption AFNI variable or otherwise expose both
legal calculation boundaries.
Acceptance criteria
- No eligible spouse produces a zero exemption.
- The lower earner is selected correctly when claimant and spouse incomes
differ. - The exemption respects the working-income, adjusted-net-income, and $16,386
caps. - End-to-end tests cover the standard schedule and the Alberta, Quebec, and
Nunavut variants.
Official source:
https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5000-s6/5000-s6-25e.pdf
- Dominant language
- Python
- Stars
- 17
- Forks
- 35
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing 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.
More from PolicyEngine/policyengine-canada
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 45/100
-
enhancement
Difficulty 4/5 3-5 days Newbie friendliness 48/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 42/100
-
enhancement
Difficulty 4/5 3-5 days Newbie friendliness 68/100
All issues in PolicyEngine/policyengine-canada
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
huggingface/peft#3955 ·
Maintainers usually reply within 1 day
-
author-page correction
Difficulty 2/5 1-3 hours Newbie friendliness 60/100
acl-org/acl-anthology#10313 ·
Maintainers usually reply within 1 day
-
anime duplicate exception request-theme
Difficulty 1/5 Under an hour Newbie friendliness 82/100
LizardByte/ThemerrDB#8926 · 1 comment ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
huggingface/transformers#49556 ·
Maintainers usually reply within 1 day
-
area/security bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
mozilla-ai/otari#2245 ·
Maintainers usually reply within 1 day