Skip to content

Commit

Permalink
minor
Browse files Browse the repository at this point in the history
  • Loading branch information
PavelMakarchuk committed Jan 20, 2025
1 parent 1e48895 commit 9e208ae
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 28 deletions.
4 changes: 2 additions & 2 deletions changelog_entry.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
- bump: patch
- bump: minor
changes:
fixed:
added:
- Limit the SALT deduction to property taxes reform.
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
description: Alabama subtracts the following credits for the federal tax deduction.
values:
2021-01-01:
- state_and_local_sales_or_income_tax
- real_estate_taxes

metadata:
unit: list
period: year
label: SALT and real estate tax deduction
reference:
- title: 26 U.S. Code § 164 - Taxes
href: https://www.law.cornell.edu/uscode/text/26/164
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,15 @@


def create_limit_salt_deduction_to_property_taxes() -> Reform:
class salt_deduction(Variable):
value_type = float
entity = TaxUnit
label = "SALT deduction"
unit = USD
documentation = "State and local taxes plus real estate tax deduction from taxable income."
definition_period = YEAR
reference = "https://www.law.cornell.edu/uscode/text/26/164"

def formula(tax_unit, period, parameters):
salt_amount = add(
tax_unit,
period,
["real_estate_taxes"],
)
salt = parameters(
period
).gov.irs.deductions.itemized.salt_and_real_estate
cap = salt.cap[tax_unit("filing_status", period)]
return min_(cap, salt_amount)
def modify_parameters(parameters):
parameters.gov.states.ut.tax.income.rate.update(
period="2023", value=new_tax_rate
)
return parameters

class reform(Reform):
def apply(self):
self.update_variable(salt_deduction)
self.modify_parameters(modify_parameters)

return reform

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,11 @@ class salt_deduction(Variable):
reference = "https://www.law.cornell.edu/uscode/text/26/164"

def formula(tax_unit, period, parameters):
p = parameters(period).gov.irs.deductions.itemized.salt_and_real_estate
salt_amount = add(
tax_unit,
period,
["state_and_local_sales_or_income_tax", "real_estate_taxes"],
p.sources,
)
salt = parameters(
period
).gov.irs.deductions.itemized.salt_and_real_estate
cap = salt.cap[tax_unit("filing_status", period)]
cap = p.cap[tax_unit("filing_status", period)]
return min_(cap, salt_amount)

0 comments on commit 9e208ae

Please sign in to comment.