Fix abolishing council tax having no budget impact (#1153)#1508
Open
Fix abolishing council tax having no budget impact (#1153)#1508
Conversation
The abolish_council_tax parameter had no effect because downstream variables (household_tax, pre_budget_change_household_tax, gov_tax) all applied the same special-case check, zeroing out the delta. Fix: introduce council_tax_applicable variable that returns 0 when abolished, replace council_tax with council_tax_applicable in all downstream adds/subtracts lists, and remove the special-case checks. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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
council_tax_applicablevariable that returns 0 whenabolish_council_taxis Truecouncil_taxwithcouncil_tax_applicablein all downstream aggregation variablesabolish_council_taxformula overrides (now unnecessary)Root cause
council_taxwas a pure input variable with no formula. Theabolish_council_taxparameter removed it from aggregation sums in bothhousehold_taxANDpre_budget_change_household_tax, so the reform-vs-baseline delta was always zero.Fix
New
council_tax_applicablevariable: returns 0 if abolished, otherwise returns thecouncil_taxinput. All downstream variables (gov_tax,household_tax,pre_budget_change_household_tax,hbai_household_net_income,household_benefits) now referencecouncil_tax_applicableinstead.Test plan
Fixes #1153