Skip to content

Restore Custom Experiments - #241

Merged
jdpigeon merged 3 commits into
mainfrom
restore-custom-experiments
Aug 18, 2026
Merged

Restore Custom Experiments#241
jdpigeon merged 3 commits into
mainfrom
restore-custom-experiments

Conversation

@jdpigeon

@jdpigeon jdpigeon commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Restores the V1 custom-experiment authoring path.

  • Custom card on Home, getExperimentFromType(CUSTOM), Conditions/Trials via StimuliDesignColumn / StimuliRow
  • Persist appState.json even when the workspace dir is missing (persistExperimentState)
  • Debounce workspace saves (400ms) so Overview typing does not write on every key
  • Load user stimulus images over bwfile:// + CSP img-src (Vite /@fs cannot serve ~/Documents)
  • Restore PYODIDE_SOURCE_DIR / FILE_TYPES imports dropped from main

Test plan

  • Preview custom experiment with ~/Documents/cartoons images (no Vite 403, no CSP block)
  • Click-through: name workspace → two image folders → preview → Collect
  • Muse ERP still a follow-up

jdpigeon added a commit that referenced this pull request Aug 18, 2026
- Add concrete defaults merge for sparse custom params (fixes Ubuntu typecheck)
- Capture workspace state before debounce to survive navigation cleanup
- Serialize async condition rebuilds with revision guards
- Replace raw bwfile:// path concatenation with authorized URL registry
- Add .jpeg/.webp support and cross-platform URL encoding
- Add regression tests for all fixed behaviors
Rewire the Custom bank path so students can pick image folders, preview
stimuli, and persist workspace state. Serve user images over bwfile://
(Vite /@fs 403s paths outside the repo). Debounce workspace saves on
keystroke. Restore PYODIDE_SOURCE_DIR after it was dropped from main.
- Add concrete defaults merge for sparse custom params (fixes Ubuntu typecheck)
- Capture workspace state before debounce to survive navigation cleanup
- Serialize async condition rebuilds with revision guards
- Replace raw bwfile:// path concatenation with authorized URL registry
- Add .jpeg/.webp support and cross-platform URL encoding
- Add regression tests for all fixed behaviors
@jdpigeon
jdpigeon force-pushed the restore-custom-experiments branch from caf56de to fac93c9 Compare August 18, 2026 20:15
@jdpigeon
jdpigeon merged commit 047643f into main Aug 18, 2026
10 checks passed
@jdpigeon
jdpigeon deleted the restore-custom-experiments branch August 18, 2026 20:18
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