Model/repositories/scenario_export
Khalim Conn-Kowlessar f1e190293b Address review: stream workbook to /tmp, repo the scenario-name SQL
Dan's review on #1546:

- Stream the workbook to a /tmp temp file and S3Client.upload_file it, instead
  of render_workbook -> bytes -> put_object. render_workbook now saves straight
  to a path; the orchestrator renders to a temp file, multipart-uploads it, and
  always cleans it up. Restores ADR-0065's "never an in-memory BytesIO" decision
  (the OOM path at the 100k-row cap).

- Move the raw `SELECT ... FROM scenario` out of the Lambda handler into
  ScenarioNamesPostgresRepository, so the handler stays composition-only and all
  SQL lives in repositories/.

- current_sap_points goes through _float, matching its Optional[float] read-model
  type and the sibling numeric facts.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-18 19:51:51 +00:00
..
__init__.py Read a scenario's default-plan properties as export rows 🟥 2026-07-13 23:26:17 +00:00
scenario_export_postgres_repository.py Address review: stream workbook to /tmp, repo the scenario-name SQL 2026-07-18 19:51:51 +00:00
scenario_export_repository.py Read a scenario's default-plan properties as export rows 🟥 2026-07-13 23:26:17 +00:00
scenario_names_postgres_repository.py Address review: stream workbook to /tmp, repo the scenario-name SQL 2026-07-18 19:51:51 +00:00