Add the simulation report tables (reports and report_results)

Geschlossen
#846 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 2 Tagen

Dieses Issue hat noch niemand übernommen.

  • #849 von @anth-volk — ohne Merge geschlossen

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
35/100
Issue-Typ
Feature
Klarheit
Größtenteils klar
Aktivitätsstatus
Veraltet
Tech-Stack
postgresql, python, sqlalchemy

Rechercherichtung

Read the persistence foundation and job store migrations, then trace how the initial migration sets default privileges for the runtime role. Add the simulation.reports and simulation.report_results tables with the fields and validation described in the issue. Done means the migration defines both tables and grants the runtime role access through those default privileges; the issue names no specific test or migration file.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

Context

Step 1 of the API v2 migration (item 1A-5) adds the tables that v2 economy and household reports will use in Step 2, and that the one-time migration of API v1 reports will fill.

Scope

  • simulation.reports: kind (economy or household), a nullable legacy_report_id for reports migrated from the Public API, and a not_started status for migrated rows that have not been computed.
  • simulation.report_results: the report aggregate as JSONB validated by a Pydantic model, its schema version and SHA-256, summary columns and artifact URIs.

Nothing uses the tables yet.

Operator prerequisites

None beyond those of the persistence foundation (database roles and secrets) and the job store (Cloud Tasks configuration), which this builds on. The runtime role receives its table privileges from the default privileges set by the initial migration.

Vorherrschende Sprache
Python
Sterne
1
Forks
1
Ø Merge
1 T. 23 Std.
Gemergte PRs (30 T.)
83

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus PolicyEngine/policyengine-sim-api

Alle Issues in PolicyEngine/policyengine-sim-api

Ähnliche Issues

Weitere Issues zu Python

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.