Repository navigation
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3928 +/- ##
==========================================
- Coverage 92.30% 87.64% -4.67%
==========================================
Files 300 306 +6
Lines 17116 18743 +1627
Branches 2851 3240 +389
==========================================
+ Hits 15799 16427 +628
- Misses 791 1741 +950
- Partials 526 575 +49
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This was referenced Oct 14, 2026
Open
DTrim99
force-pushed
the
us-2036-economy-year
branch
from
October 26, 2026 19:14
b242eb4 to
a9907ba
Compare
DTrim99
force-pushed
the
us-2036-economy-year
branch
from
November 2, 2026 15:49
a9907ba to
b1d0f78
Compare
Add 2036 to the US time_period options and to the v2 catalog's METADATA_TIME_PERIODS, and update the canonical SPM contract doc's horizon. This must ship with the PolicyEngine bundle whose SPM forecast covers 2036; until then a 2036 request fails with SPM_YEAR_UNAVAILABLE. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LqCGPgxDukji8Bhs57c5rH
The year-after-forecast missing-input case runs against the certified bundle's installed forecast. Once the bundle carries spm-calculator 1.1.0, 2036 is inside the forecast, so the case moves to 2037, which is outside both the current and the 2036 forecast. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
US_ECONOMY_YEARS now runs from 2036 down to 2024, the last year of the canonical SPM forecast in the bundle (spm-calculator 1.1.0 covers 2022 to 2036). /us/metadata and the v2 catalog offer 2036, and the economy routes accept it. Tests that used 2036 as a year after the US years use 2037. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
DTrim99
force-pushed
the
us-2036-economy-year
branch
from
November 10, 2026 18:42
b1d0f78 to
feac42e
Compare
3 tasks done
This branch had an error being deployed
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.
Fixes #3927
Summary
This is the policyengine-api part of #3926: it lets US users pick 2036.
Rebased onto
masteron 2026-11-10, after #4212 moved each country's years intopolicyengine_api/economy_years.py. The earlier edits tocountry.pyand the v2 catalog extraction are gone, because both now read that module.policyengine_api/economy_years.py:US_ECONOMY_YEARSruns from 2036 down to 2024./us/metadata'seconomy_options.time_period, the v2 catalog'smetadata_time_periodsand the years the economy routes accept all follow it. A society-wide request for another year still gets the 400 withDATASET_YEAR_UNAVAILABLE, whose message now reads "US results are available for 2024 to 2036". The UK is unchanged (2024–2032).Docs:
docs/canonical-spm.mdgives the artifact horizon as 2022–2036 and the US years as 2024 to 2036;docs/migration/stage-9-v2-metadata.mdgives the same US years.Tests: tests that used 2036 as a year after the US years now use 2037:
test_economy_unavailable_years.py;test_spm_year_worker_polling.py, whose last accepted year is now 2036 and whose budget window runs 2036–2037;test_economy_service_budget_window_requests.py's docstring and job id;test_economy_years.pyandtest_country.py.test_country_spm.py'syear-after-forecastcase runs against the installed forecast, so it moves from 2036 to 2037. The tests on mocked forecasts withyears=(2022, 2035)don't depend on the installed artifact and are unchanged.Draft until the bundle with a 2036 SPM forecast is ready.
SPM_YEAR_UNAVAILABLE.Testing
These ran on Modal, as CI sets up: Python 3.12, uv 0.13.4,
uv sync --frozen --extra dev --group telemetry-error-issues.test_economy_years,test_economy_unavailable_years,test_spm_year_worker_polling,test_economy_service_budget_window_requests,test_country,test_country_spmand the v2 catalog time-period publication test.tests/unit: 4,809 passed. All 177 failures are deploy and CI-script tests that calljqor need a.gitcheckout, which the container lacked. None touch the year lists.After the bundle bump, on staging:
GET /us/metadatalists 2036."2036"in its SPM receipt.budget_window:2027:10completes.DATASET_YEAR_UNAVAILABLE.🤖 Generated with Claude Code