Skip to content

PM-6599: Restore Marathon Match submission ranks - #2501

Merged
jmgasper merged 2 commits into
devfrom
PM-6599
Oct 16, 2026
Merged

jmgasper merged 2 commits into
devfrom
PM-6599

Conversation

@jmgasper

Copy link
Copy Markdown
Collaborator

What was broken

Marathon Match All Submissions was missing the Final Rank and Provisional Rank columns shown on the old platform.

Root cause

The Opportunities table rendered scores without calculating ranks. Its default date ordering fetched individual pages, which cannot produce challenge-wide rankings.

What was changed

  • Add sortable Final Rank and Provisional Rank columns only to Marathon Match All Submissions, with mobile labels and sort options.
  • Rank the complete latest-submission collection before sorting and pagination. Reuse the existing score resolver and final-score release gate; missing or pending scores remain unranked.
  • Match community-app: provisional ties favor earlier submission times, while equal final scores share competition ranks (1, 1, 3).
  • Adjust the eight-column layout and table-card scrolling, and update the Opportunities README.

Files changed: ChallengeDetailsPage.tsx, ChallengeDetailsPage.module.scss, ChallengeDetailsPage.flows.spec.tsx, marathon-match.utils.ts, marathon-match.utils.spec.ts, and src/apps/opportunities/README.md.

Any added/updated tests

  • Add 10 regression cases covering score ties, missing/pending scores, summation precedence, both rank-sort directions, global pagination, mobile sorting, final-rank release timing, and non-MM exclusions. Extend My Submissions coverage to verify that its columns stay unchanged.
  • Run nvm use before all Node/Yarn commands.
  • yarn lint: passed.
  • NODE_OPTIONS=--max-old-space-size=12288 yarn run build: passed with existing repository warnings. The initial default-heap build exhausted Node's heap.
  • yarn test:no-watch --runInBand src/apps/opportunities: all 713 tests in 61 suites passed.
  • yarn test:no-watch --runInBand: 387 suites and 2,736 tests passed; 22 suites failed, including 19 failed tests. The identical failing suites and test cases reproduce on untouched origin/dev (2,726 passing tests). These existing failures include module-resolution, mocks, and unrelated expectation failures and require separate fixes.
  • Fixture-backed Chromium checks at 1440px, 1024px, and 390px: rank values, sorting, responsive rendering, and no viewport overflow passed; screenshots inspected.

What was broken
Marathon Match All Submissions omitted the provisional and final rank columns available on the old platform.

Root cause
The Opportunities table displayed scores but did not calculate or render ranks. Date sorting loaded individual pages, which cannot provide challenge-wide rankings.

What was changed
Add sortable Final Rank and Provisional Rank columns exclusively to Marathon Match All Submissions, with mobile labels and sort options. Rank the complete latest-submission collection before pagination using the existing score resolver and final-score release gate. Preserve the legacy provisional timestamp tie-break and shared final competition ranks. Update the table widths and documentation.

Any added/updated tests
Add 10 regression cases covering ties, missing and pending scores, resolved summations, both rank sort directions, global pagination, mobile sorting, release timing, and non-MM exclusions. Extend My Submissions coverage to verify its columns remain unchanged.
All 713 Opportunities tests pass. The full suite's 22 failing suites and 19 failed tests also reproduce on untouched origin/dev.
@jmgasper
jmgasper requested a review from kkartunov as a code owner October 15, 2026 19:46
Preserve global Marathon Match ranks alongside the 200-row default from dev. Update pagination coverage and API expectations for full-collection ranking.
@jmgasper
jmgasper merged commit f403f8d into dev Oct 16, 2026
6 of 8 checks passed
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