Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Music: use default pack if project has already been started #58783

Merged
merged 2 commits into from
May 21, 2024

Conversation

sanchitmalhotra126
Copy link
Contributor

As we prepare for launch, we found a scenario where if a student has started a project with a library that doesn't have restricted sounds, and then opens their project later on a library that does have restricted sounds, they'll be prompted with the pack selection dialog. This may be confusing for users because once they select a pack, they are locked into the standard flow which means that if they want to change their pack, they need to start over, which is much more impactful if a student has already worked a lot on a project. This change sets the pack to the "default" Code.org pack if any changes have been made on an existing project, so when the library does update, they will be able to continue working on their project seamlessly.

Testing story

Scenarios I tried:

  • Open a project that was edited with the current (non-restricted library) with ?library=launch2024-prep. Pack dialog does not appear (automatically set to Code.org sounds).
  • Starting a project and making changes on current (non-restricted) library. Refresh with ?library=launch2024-prep. Pack dialog does not appear (automatically set to Code.org sounds)
  • Starting a project and saving, but making no changes. Refresh with ?library=launch2024-prep. Pack dialog does appear (because current code matches starter code).
  • Open an existing project with edits, but then reverting back to blank (only when run block). Refresh with ?library=launch2024-prep. Pack dialog does not appear (pack ID has already been set to "default").
  • Opening a blank project with ?library=launch2024-prep. Refreshing with the pack dialog still open. Pack dialog does appear since a pack has still not yet been selected.

@sanchitmalhotra126 sanchitmalhotra126 requested review from breville and a team May 20, 2024 19:57
Copy link
Member

@breville breville left a comment

Choose a reason for hiding this comment

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

Tested locally and appears to work well. Thanks for doing this!

@sanchitmalhotra126 sanchitmalhotra126 merged commit 5dae593 into staging May 21, 2024
2 checks passed
@sanchitmalhotra126 sanchitmalhotra126 deleted the sanchit/music-existing-project-pack branch May 21, 2024 21:47
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.

None yet

2 participants