Skip to content

PM-4821: preserve immediate challenge start mode#1710

Merged
jmgasper merged 1 commit intodevfrom
PM-4821
Apr 10, 2026
Merged

PM-4821: preserve immediate challenge start mode#1710
jmgasper merged 1 commit intodevfrom
PM-4821

Conversation

@jmgasper
Copy link
Copy Markdown
Collaborator

@jmgasper jmgasper commented Apr 10, 2026

What was broken
When users selected Immediately for the challenge start mode, saving or launching the challenge caused the reopened schedule view to show Scheduled instead.

Root cause
The schedule editor did not persist the selected start-mode radio anywhere durable. After reloading a saved challenge, the UI only saw a concrete startDate and inferred Scheduled from that value alone.

What was changed
Persisted the selected challenge start mode in challenge metadata under challengeStartMode.
Updated ChallengeScheduleSection to restore the radio state from that metadata before falling back to startDate.
Kept the metadata in sync when users switch between Immediately and Scheduled.
Updated the challenge editor README to document the persisted behavior.

Any added/updated tests
Added a regression test covering a saved challenge with a concrete startDate plus persisted immediate-mode metadata.
Updated the schedule section component tests to assert the metadata value changes when the start mode changes.


Open with Devin

What was broken
When users selected Immediately for the challenge start mode, saving or launching the challenge caused the reopened schedule view to show Scheduled instead.

Root cause
The schedule editor did not persist the selected start-mode radio anywhere durable. After reloading a saved challenge, the UI only saw a concrete startDate and inferred Scheduled from that value alone.

What was changed
Persisted the selected challenge start mode in challenge metadata under challengeStartMode.
Updated ChallengeScheduleSection to restore the radio state from that metadata before falling back to startDate.
Kept the metadata in sync when users switch between Immediately and Scheduled.
Updated the challenge editor README to document the persisted behavior.

Any added/updated tests
Added a regression test covering a saved challenge with a concrete startDate plus persisted immediate-mode metadata.
Updated the schedule section component tests to assert the metadata value changes when the start mode changes.
@jmgasper jmgasper requested a review from kkartunov as a code owner April 10, 2026 03:02
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 3 additional findings.

Open in Devin Review

@jmgasper jmgasper merged commit 066712e into dev Apr 10, 2026
9 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