Skip to content

Track 4 staging (3/3): Run the ranking graph end to end on staging and check it - #170

Open
SuperNova-W wants to merge 1 commit into
t4/7b-staging-seedfrom
t4/7c-staging-runner
Open

SuperNova-W wants to merge 1 commit into
t4/7b-staging-seedfrom
t4/7c-staging-runner

Conversation

@SuperNova-W

Copy link
Copy Markdown
Collaborator

run-on-staging.sh starts a throwaway Postgres and a Python container on the
staging box (horizon-t4-* names only; nothing in the Coolify stack), seeds the
synthetic semester, and materializes ranking_run through publish_ranking with
their asset checks. run_t4.py prints the leaderboard and a member document,
checks every seeded case and every metric value seed.py worked out (exit 1 if
one is wrong), scores a v1 run to check the survey ratings, and writes a v1 vs
v2 compare report. --tests also runs the suite with the database tests, --ui
starts Dagster on 127.0.0.1:3070, --down removes everything.

ship-to-staging.sh runs from a Mac clone: over one ssh appdev-staging
connection it copies a branch's committed horizon/ folder to
/opt/horizon-t4/, runs it there and copies the compare report back, so
an unpushed branch can be tested.

Stack

Track 4, stacked on Michael's #147 → #149 → #151 → #153. Review and merge in order; each PR shows only its own change.

  1. t4/base-pr-153: a copy of T4.4: Delivery against the SOW metrics #153's head (90b8e5b, in Michael's fork), so this stack can target it. After T4.1: Ranking schema, rubric v1 and ranking runs #147–T4.4: Delivery against the SOW metrics #153 merge, retarget PR 1 to master.
  2. t4/4a-schema-upgrade T4.1 fix: add excluded_buckets to an existing ranked_members
  3. t4/4b-review-fixes T4.3 fix: real elapsed review hours, Co-authored-by trailers, roster-only contributors
  4. t4/4c-survey-roles T4.3 fix: count survey answers only from the respondents the card names
  5. t4/4d-inactive-stretch T4.2 fix: longest_inactive_stretch counts the gap since the last activity
  6. t4/5a-scoring T4.5 (1/4): Percentile, bucket and overall scoring
  7. t4/5b-read-models T4.5 (2/4): Published ranking document and leaderboard read models
  8. t4/5c-member-scores T4.5 (3/4): member_scores asset
  9. t4/5d-publish T4.5 (4/4): publish_ranking asset
  10. t4/6a-explanations T4.6 (1/4): Explanation input, Claude call and fallback
  11. t4/6b-member-explanations T4.6 (2/4): member_explanations asset and published notes
  12. t4/6c-admin-cli T4.6 (3/4): Admin CLI: finalize, compare, add-note
  13. t4/6d-rubric-v2 T4.6 (4/4): Rubric v2 without survey buckets as the default
  14. t4/7a-staging-inputs Track 4 staging (1/3): The deployed definitions of the input tables
  15. t4/7b-staging-seed Track 4 staging (2/3): A synthetic semester with expected metric values
  16. t4/7c-staging-runner Track 4 staging (3/3): Run the ranking graph end to end on staging and check it ← this PR

Testing

  • ./nx run horizon-dag:check passes on this branch. Database tests run when TEST_POSTGRES_URL points at a Postgres the tests may create databases on, for example postgresql://postgres@127.0.0.1:5432/postgres; without it they are skipped.
  • The top of the stack was checked three ways on 2026-11-20:
    • The staging harness (horizon/dev/t4-staging): every seeded case and every independently computed metric value matches. The same harness fails on the code before PRs 2–4.
    • The real Fall 2026 data from the deployed Supabase, in a copy: the metrics match the earlier implementation's for all 96 members. The only differences are the no-repository projects, which are NULL with a reason instead of 0.
    • On the test Supabase itself: v2 ran and was published, both asset checks passed and 24 engineers and 4 tech leads were ranked. The Horizon API serves it.

Size: 4 files changed, 397 insertions(+).

run-on-staging.sh starts a throwaway Postgres and a Python container on the
staging box (horizon-t4-* names only; nothing in the Coolify stack), seeds the
synthetic semester, and materializes ranking_run through publish_ranking with
their asset checks. run_t4.py prints the leaderboard and a member document,
checks every seeded case and every metric value seed.py worked out (exit 1 if
one is wrong), scores a v1 run to check the survey ratings, and writes a v1 vs
v2 compare report. --tests also runs the suite with the database tests, --ui
starts Dagster on 127.0.0.1:3070, --down removes everything.

ship-to-staging.sh runs from a Mac clone: over one ssh appdev-staging
connection it copies a branch's committed horizon/ folder to
/opt/horizon-t4/<branch>, runs it there and copies the compare report back, so
an unpushed branch can be tested.

This branch has not been deployed

No deployments
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.

1 participant