Skip to content

fix: reload page on SignalR manual_selection transition (closes #172) - #188

Merged
negativeeddy merged 1 commit into
masterfrom
fix/issue-172
Sep 6, 2026
Merged

fix: reload page on SignalR manual_selection transition (closes #172)#188
negativeeddy merged 1 commit into
masterfrom
fix/issue-172

Conversation

@negativeeddy

Copy link
Copy Markdown
Owner

Automated Fix

Fixes #172

Changes

When the SignalR live-update handler detects the job has transitioned to manual_selection (ManualSelectionStarted) but the submitManualSelection() function is not defined (meaning the page was initially loaded in a different state), trigger a full page reload. This ensures the server re-renders the track selection checkboxes, the select-all checkbox, and the submitManualSelection() function — all of which are only emitted in the Razor template when the page initially renders in ManualSelectionStarted.

Without this fix, clicking the "Continue Rip" button injected by SignalR causes a ReferenceError because submitManualSelection was never defined, and the track checkboxes are also missing from the DOM.

Testing

  • All 496 existing tests pass (113 + 80 + 303)
  • Build succeeds with 0 warnings, 0 errors

@negativeeddy

Copy link
Copy Markdown
Owner Author

Reviewed and approved. The fix reloads the page when the SignalR live-update path detects a transition to manual_selection while submitManualSelection() is undefined, so the server re-renders the track checkboxes, select-all checkbox, and the function. The manualSelectionSubmitted guard correctly avoids reloading after a user submission (issue #182). Build passes with 0 warnings/errors; all 496 tests pass. Ready for merge.

Note: this overlaps with PR #189 (issue #168) which adds a similar reload on the transition INTO manual_selection — both are valid; if merged together the guards are complementary (reload is idempotent).

@negativeeddy

Copy link
Copy Markdown
Owner Author

Rebased onto master (which now includes PR #189 / issue #168). The two reload guards are complementary: #189's transition guard (lastStatus !== 'manual_selection') fires first and covers this issue's scenario too; this PR's guard remains as a defensive safety net. Build passes with 0 warnings/errors; all 497 tests pass. Merging.

@negativeeddy
negativeeddy merged commit 200c1fd into master Sep 6, 2026
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.

Medium: submitManualSelection() is undefined in the SignalR live-update path — broken Continue Rip button

1 participant