Skip to content

Implement Maine PTFC unknown-utilities 15% rule (Schedule PTFC line 5c) - #9267

Open
DTrim99 wants to merge 1 commit into
PolicyEngine:mainfrom
DTrim99:fix/me-ptfc-utilities-in-rent-v2
Open

Implement Maine PTFC unknown-utilities 15% rule (Schedule PTFC line 5c)#9267
DTrim99 wants to merge 1 commit into
PolicyEngine:mainfrom
DTrim99:fix/me-ptfc-utilities-in-rent-v2

Conversation

@DTrim99

@DTrim99 DTrim99 commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Surfaced by PolicyEngine/policyengine-taxsim#1126 (ME renter with rent that includes utilities).

Problem

Maine's property tax fairness credit treats 15% of rent as "rent constituting property taxes," after first excluding any heat/utilities included in the rent. Per 2022 Schedule PTFC/STFC line 5c: if the rent includes utilities and the amount is known, subtract it; if the rent includes utilities and the amount is not known, subtract 15% of gross rent instead.

me_property_tax_fairness_credit_countable_rent only handled the known-amount case (utilities_included_in_rent * utility_expense) and its comment noted the unknown-amount branch was "not implemented." So a filer whose rent includes utilities but who did not itemize a utility amount received no utility exclusion at all, overstating the countable rent (and the credit).

Fix

  • Implement the line-5c fallback: when utilities_included_in_rent is true and the utility amount is unknown (utility_expense is 0), deduct 15% of gross rent before applying the 15% rent-constituting-property-tax rate.
  • Add parameter gov.states.me.tax.income.credits.fairness.property_tax.rate.utilities_included_in_rent (0.15) for the utility fraction.
  • Add a countable-rent test for the unknown-amount case.

Example

Rent $17,139 with utilities included, amount unknown: utility portion = 15% × 17,139 = 2,571; countable rent = 15% × (17,139 − 2,571) = 2,185, matching the Maine worksheet (previously PE used the full 15% × 17,139 = 2,571). The known-amount and utilities-not-included cases are unchanged.

Maine's property tax fairness credit computes rent constituting property
taxes as 15% of rent, after excluding any heat/utilities included in the
rent. Schedule PTFC/STFC line 5c provides that when the rent includes
utilities but the amount is not known, 15% of gross rent is treated as
the utility portion. me_property_tax_fairness_credit_countable_rent
previously left that fallback unimplemented, so a filer whose rent
includes utilities but who did not itemize a utility amount received no
utility exclusion. Add the 15% fallback and a parameter for the fraction.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@codecov

codecov Bot commented Aug 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (a6acf1f) to head (cafacda).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #9267   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            5         1    -4     
  Lines           83        18   -65     
=========================================
- Hits            83        18   -65     
Flag Coverage Δ
unittests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@PavelMakarchuk PavelMakarchuk left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The implementation mechanics check out — all 34 tests in the ME PTFC suite pass on the branch, the new parameter loads with correct metadata, utilities_included_in_rent defaults to false so microsim defaults are unaffected, no partner contract tests are touched, and the worksheet math in the new test (127.5 = (1000 − 150) × 0.15) is internally consistent with the quoted form text.

Requesting changes for two findings on the rewritten formula, detailed inline:

  1. utility_expense is the wrong "amount known" discriminator — it's the household's general SNAP-style utility expense total, not the utility portion of rent, so the new 15% fallback only fires when the household reports zero utility expenses of any kind, and separately-paid utilities get subtracted from rent.
  2. No clamp when utilities exceed rent — countable rent can go negative and offsets real_estate_taxes downstream; line 5d on the form can never be negative.

Caveat: maine.gov was unreachable from the review environment, so the line-5c rule was verified against the PR's quoted form text and worksheet example rather than the form PDF itself.


Generated by Claude Code

# Schedule PTFC/STFC line 5c: when rent includes heat/utilities, exclude
# the utility portion before taking 15% of rent. If the amount is known,
# subtract it; if it is not known, subtract 15% of gross rent instead.
amount_known = utility_expenses > 0

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utility_expense is the wrong discriminator for "is the utility portion of rent known?". It's the SPM-unit total of heating/cooling, gas, electricity, trash, and water expenses the household pays (the same variable SNAP uses) — not "the portion of rent attributable to utilities." That has two effects:

  1. The new 15% fallback is unreachable for any household that reports any utility expense, since utility_expenses > 0 then reads as "amount known."
  2. Separately-paid utilities are subtracted from rent as if they were included in it (this subtraction predates the PR, but the PR newly overloads the same variable as the known/unknown flag).

Concrete case: a ME renter with $12,000 rent that includes heat (portion unknown, so line 5c's 15% rule should apply) who also pays $600/yr of electricity separately gets amount_known = True and countable rent of (12,000 − 600) × 0.15 = $1,710 instead of the form's (12,000 − 1,800) × 0.15 = $1,530. A dedicated variable for the utilities-included-in-rent amount (rather than reusing the household's general utility expenses) would make the known/unknown split match the form.


Generated by Claude Code

deductible_utility_expenses = utilities_included_in_rent * where(
amount_known, utility_expenses, rent * p.rate.utilities_included_in_rent
)
net_rent = rent - deductible_utility_expenses

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The known-amount branch has no clamp: when utility_expenses exceeds rent, net_rent goes negative and so does countable rent. Example: rent = 2,400, utilities_included_in_rent = true, utility_expense = 3,600 (plausible for low/subsidized rent with high utilities) → net_rent = −1,200 → countable rent = −180. On the real form, line 5d (5a minus 5c) can never be negative because 5c is a portion of 5a, and downstream me_property_tax_fairness_credit_countable_rent_property_tax adds this negative value to real_estate_taxes, understating the credit for part-year owner/renters.

Since this PR rewrote exactly these lines, a min_(utility_expenses, rent) on the deductible (or max_(net_rent, 0)) would close it.


Generated by Claude Code

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.

2 participants