Skip to content

Round tapered personal allowance up to nearest pound#1750

Closed
MaxGhenis wants to merge 1 commit into
mainfrom
codex/personal-allowance-rounding
Closed

Round tapered personal allowance up to nearest pound#1750
MaxGhenis wants to merge 1 commit into
mainfrom
codex/personal-allowance-rounding

Conversation

@MaxGhenis
Copy link
Copy Markdown
Collaborator

Summary

Notes

The formula stays vectorized: it applies numpy.ceil to the array returned by max_(0, personal_allowance - reduction) rather than using scalar control flow.

Fixes #1738.

Tests

  • uv run ruff check policyengine_uk/variables/gov/hmrc/income_tax/allowances/personal_allowance.py
  • uv run policyengine-core test policyengine_uk/tests/policy/baseline/gov/hmrc/income_tax/allowances/personal_allowance.yaml -c policyengine_uk
  • git diff --check

@MaxGhenis
Copy link
Copy Markdown
Collaborator Author

Closing as superseded by #1751, which merged the tapered Personal Allowance rounding fix and closed #1738. This older branch now conflicts with main.

@MaxGhenis MaxGhenis closed this Jun 4, 2026
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.

Round tapered personal allowance up to nearest pound

1 participant