You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On the generic bulk-footprinting page, Load YAML from path updates st.session_state.current_config and the runnable YAML preview, but the visible form controls retain their previous widget-state values. The page therefore displays two conflicting configurations at once.
The loaded workflow can run successfully if the user ignores the form. However, clicking Update page config after loading silently replaces the loaded paths/options with the stale visible defaults, making this a data-loss/incorrect-run hazard.
The runnable preview correctly showed all loaded values, while the form still displayed the old defaults:
Field
Visible form
Runnable YAML
Sample Table
samples.tsv
absolute fixture TSV path
Comparison Table
comparisons.tsv
absolute fixture TSV path
Genome
genome.fa.gz
absolute genome.fa path
Outdir
results/bulk_footprinting
.../bulk-project-gui
Cores
4
2
Plot Aggregate
all
top
Review Format
auto
bundle
The newly introduced Normalization and Motifs fields did reflect loaded values because those widget keys did not exist before the load. Fields whose keys were already instantiated stayed stale.
Despite the visual mismatch, clicking Start run executed the loaded YAML and completed successfully: exit code 0, 10,261 project files, corrected bigWigs, footprint bigWigs, per-sample motif results, a 1,020-row differential result, interactive HTML, and combined review report.
Expected
After any of these actions:
Load example
Apply uploaded YAML
Load YAML from path
all visible controls on that page should immediately reflect the active current_config. The form, validation card, YAML preview, and eventual command must describe one configuration.
Likely cause
_render_page_loader() calls _set_config(), which currently only assigns:
The generic fields use persistent explicit widget keys such as bulk-footprinting_sample_table, bulk-footprinting_genome, etc. Streamlit gives existing widget state precedence over a newly supplied value=, so _current_single_params(tool) changes but already-created widgets retain old values.
_set_config() neither clears/reseeds page widget keys nor forces a rerun after synchronizing them.
Risk
This is not only cosmetic. A user can inspect the loaded YAML, edit one visible field, and click Update page config, unintentionally replacing every loaded field with stale defaults. The resulting command may fail validation or write to an unintended output directory.
Suggested implementation
Create a single config-to-widget synchronization path used by all loaders. Before rerunning:
Normalize and store the config.
Determine the relevant tool/page.
Clear or explicitly reseed every widget key owned by that page, including select boxes, numeric inputs, list text areas, and extra args.
Call st.rerun() only after state is consistent.
Avoid clearing unrelated navigation/run-history state. A generation/version suffix on form keys is another safe approach if comprehensive key cleanup is difficult.
Regression tests
Add a Streamlit/AppTest or frozen browser test that:
Opens bulk-footprinting with defaults.
Loads a YAML where every field differs from the default.
Asserts every visible control equals the loaded YAML.
Asserts preview YAML equals the same values.
Changes exactly one field and clicks Update page config.
Asserts only that field changed and all other loaded values were preserved.
Repeat via example loading and file upload, and cover at least one specialized page (diff-footprints) plus one other generic page.
Acceptance checklist
All visible controls refresh after YAML/example/upload loading.
No stale values survive from the pre-load page state.
Form, validation, preview, and launched command remain identical.
Editing one field after load preserves all other loaded values.
Windows paths, list fields, booleans, select boxes, and numeric inputs round-trip correctly.
Summary
On the generic
bulk-footprintingpage, Load YAML from path updatesst.session_state.current_configand the runnable YAML preview, but the visible form controls retain their previous widget-state values. The page therefore displays two conflicting configurations at once.The loaded workflow can run successfully if the user ignores the form. However, clicking Update page config after loading silently replaces the loaded paths/options with the stale visible defaults, making this a data-loss/incorrect-run hazard.
Tested candidate
dfd283e9a1d64f5728b310af6e0b2c373337de5a324526923359436464405c8cfbd635a2835980f69fa45ed8cb03787ffa2069706a174b91e811a742c389d0.2.0rc12Reproduction
bulk-footprinting.Current config updated.and the enabled Start run button.Test YAML contained:
Actual result
The runnable preview correctly showed all loaded values, while the form still displayed the old defaults:
samples.tsvcomparisons.tsvgenome.fa.gzgenome.fapathresults/bulk_footprinting.../bulk-project-gui42alltopautobundleThe newly introduced
NormalizationandMotifsfields did reflect loaded values because those widget keys did not exist before the load. Fields whose keys were already instantiated stayed stale.Despite the visual mismatch, clicking Start run executed the loaded YAML and completed successfully: exit code 0, 10,261 project files, corrected bigWigs, footprint bigWigs, per-sample motif results, a 1,020-row differential result, interactive HTML, and combined review report.
Expected
After any of these actions:
all visible controls on that page should immediately reflect the active
current_config. The form, validation card, YAML preview, and eventual command must describe one configuration.Likely cause
_render_page_loader()calls_set_config(), which currently only assigns:The generic fields use persistent explicit widget keys such as
bulk-footprinting_sample_table,bulk-footprinting_genome, etc. Streamlit gives existing widget state precedence over a newly suppliedvalue=, so_current_single_params(tool)changes but already-created widgets retain old values._set_config()neither clears/reseeds page widget keys nor forces a rerun after synchronizing them.Risk
This is not only cosmetic. A user can inspect the loaded YAML, edit one visible field, and click Update page config, unintentionally replacing every loaded field with stale defaults. The resulting command may fail validation or write to an unintended output directory.
Suggested implementation
Create a single config-to-widget synchronization path used by all loaders. Before rerunning:
st.rerun()only after state is consistent.Avoid clearing unrelated navigation/run-history state. A generation/version suffix on form keys is another safe approach if comprehensive key cleanup is difficult.
Regression tests
Add a Streamlit/AppTest or frozen browser test that:
bulk-footprintingwith defaults.diff-footprints) plus one other generic page.Acceptance checklist