Sterling version update + viz options update#336
Open
sidprasad wants to merge 10 commits into
Open
Conversation
… mode Introduces `sterling_viz` (string | list-of-strings | #f, default #f): a CnD/JS visualization-script path (or paths) to auto-load in Sterling, path-translated relative to the model file like run_sterling's legacy path form. This separates "which viz file to load" from run_sterling, which stays the open mode (on/off/serve/headless). Motivation: tooling that forces headless Sterling (e.g. the VSCode webview integration, via `-O run_sterling headless`) no longer has to clobber a viz file the user specified — the file now lives in its own orthogonal option. Additive and non-breaking: run_sterling's dispatch is unchanged, and the previously-unused string/path form of run_sterling keeps its current behavior. - sigs-structs.rkt: default, validator, and type description for sterling_viz - sigs-functional.rkt: path-translate sterling_viz relative to the model file Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
sterling-viz-to-xml now sources the viz file(s) from the dedicated sterling_viz option, falling back to a legacy path/list in run_sterling for back-compat. This makes the embedded <visualizer cnd=.../script=.../> auto-apply in Sterling regardless of the launch mode (browser/headless/webview) — previously it only fired when run_sterling itself was the path, which also forced browser mode and was wiped by tooling that forces -O run_sterling headless. Completes the launch-options (run_sterling) vs viz-options (sterling_viz) split. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Separate Sterling launch options from viz options
Decouples where/whether Sterling opens from which visualization it loads, so a diagram auto-applies no matter the launch mode:
run_sterlingstays the launch mode:on/off/serve/headless(dispatch unchanged).sterling_vizoption (string | list of strings |#f) holds the CnD/JS viz file(s), path-translated relative to the model file.<visualizer cnd=.../script=.../>is now driven bysterling_viz, falling back to a legacy path/list inrun_sterlingfor backward compatibility. So the diagram auto-applies inbrowser,headless, orservemode alike.Motivation: tooling that forces headless Sterling (e.g. the VS Code webview integration, via
-O run_sterling headless) no longer clobbers a user's viz file — it now lives in its own orthogonal option. Additive and non-breaking:run_sterling's behavior is unchanged, and its previously-unused string/path form still works via the fallback.