Treat PE-US aggregate outputs as formula-owned - #182
Merged
Conversation
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
2 times, most recently
from
June 25, 2026 02:50
0bbf77f to
4ce6f23
Compare
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 25, 2026 03:12
4ce6f23 to
a06b0a2
Compare
Contributor
Author
|
This PR is green but should be merged/released after PolicyEngine/policyengine-us#8747 lands and a compatible policyengine-us release is available. The current Populace lock resolves policyengine-us==1.729.0, which does not expose ordinary_dividend_income or cbo_net_business_income; those are added in #8747 and are needed for the source-aligned target mappings here. The export-surface fix itself is assertion-only: formula-owned columns fail before export rather than being repaired or dropped. |
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 25, 2026 03:59
a06b0a2 to
10d2f5c
Compare
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 25, 2026 10:45
a258809 to
d2577fb
Compare
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 25, 2026 12:31
3cc69e3 to
dcdde76
Compare
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 26, 2026 12:20
4f33cdc to
b440c33
Compare
MaxGhenis
force-pushed
the
codex/target-alignment-audit-20260624
branch
from
June 26, 2026 12:26
b440c33 to
a56aefd
Compare
PavelMakarchuk
added a commit
that referenced
this pull request
Jul 1, 2026
…ding stacking (#246) The estate exemption is scored on estate_tax (#182) — estate tax is not a component of income_tax, so measuring it on income_tax is a structural zero. But stacked_obbba_effects required a single (budget_measure, period) across ALL provisions and otherwise fell back to isolated scoring for everything — so since #185 landed on top of #182, a real build would silently not stack at all. Stack per (measure, period) group instead: the income-tax provisions keep their JCX-order cumulative stack, the estate provision scores within its own group (single member = enacted alone), and the shared pre-OBBBA baseline still merges every revert so each group is scored in whole-bill context. Cross-group interactions are nil by construction since the measures are disjoint taxes. Removes the now-dead isolated fallback, documents the estate survey-data caveat, and adds a mixed-measure regression test that would KeyError on any isolated fallback. Co-authored-by: Claude Fable 5 <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
adds/subtractsvariables as formula-owned outputs in the adapter, matching direct formulasqualified_dividend_incomeand the non-qualified residual leaf, and blockdividend_income/ordinary_dividend_incomeordinary_dividend_income, while preservingsource_variable=ordinary_dividendsfor source/provenance semanticssocial_security_retirementsource support and blocking the aggregatesocial_securitypartnership_incomeands_corp_income; Populace no longer synthesizes a tax-unit partnership/S-corp aggregate in PUF supportTDD notes
dividend_income,social_security,partnership_s_corp_income, and genericaddsoutputs such asemployment_incomeblock exportTests
uv run ruff check packages/populace-build/src/populace/build/us_runtime/fiscal_targets.py packages/populace-build/tests/test_us_fiscal_targets.py tools/build_us_fiscal_refresh_release.pyuv run pytest packages/populace-build/tests/test_us_fiscal_targets.py— 63 passeduv run pytest packages/populace-frame/tests/test_policyengine_us_adapter.py packages/populace-build/tests/test_us_puf_support.py packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_export_frame_rejects_formula_owned_columns packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_export_frame_accepts_leaf_only_columns— 36 passed, 1 PE-US warninguv run pytest packages/populace-frame/tests/test_policyengine_us_adapter.py packages/populace-build/tests/test_us_puf_aggregate_records.py packages/populace-build/tests/test_us_source_runtime.py packages/populace-build/tests/test_us_plan.py packages/populace-build/tests/test_us_puf_support.py packages/populace-build/tests/test_us_fiscal_targets.py packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_export_frame_rejects_formula_owned_columns packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_export_frame_accepts_leaf_only_columns packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_soi_component_amounts_use_source_specific_signs packages/populace-build/tests/test_us_fiscal_refresh_builder.py::test_soi_indicator_rows_flag_positive_component_items— 158 passed, 1 PE-US warning