Repository navigation
fix(renderer): isolate compiler imports from CLI diagnostics - #418
Merged
Merged
Conversation
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This was referenced Sep 16, 2026
Owner
|
The merge-order question is resolved: import isolation will be integrated before #396. I could not push the dev refresh to the fork branch (permission denied), so #441 preserves this PR's commits and adds the current dev base plus the canonical ZIP rebuild. Its focused tests pass (19/19); final CI is pending. Keeping this PR open until the integration replacement is accepted. |
6 tasks done
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.
Problem and value
Importing
compileWorkflow()withARCHIFY_DIAGNOSTIC_FORMAT=jsoninstalls a process-level exception handler through shared SVG helpers. A later exception belonging to the embedding host can then produce a renderer receipt and exit the process.Install that boundary when
loadDiagram()starts instead. Compiler imports preserve the host's exception policy; all five CLI entrypoints still establish diagnostics before reading or validating input.Related to #222. This is the preparatory import-isolation fix, without introducing a public render API.
Stability impact
Tests run
Current base:
d15010a2d49f93388820f8a3b7474b77aef60006. Current candidate:8ae0d450b588fe5808959332f7296dfd7ae5ce5f.This revision merges main's benchmark visual-defect validation fix (#402). It adds no further import-isolation changes: the four-file PR diff against current main is byte-for-byte identical to the original patch at
72deba7.Fresh local checks use official Node 22.23.2. Linux checks run against the exact candidate source tree exported with
git archive, with a temporary Git snapshot for tracked-file package checks and the committed ZIP unchanged.npm testThe Windows full suite was not rerun or claimed green. Its earlier run on
72deba7had 1292 passed, 31 failed and 57 skipped; an aligned base replay reproduced 30 failures, and the remaining notifier timing case passed in isolation on both base and candidate.Earlier reproduction evidence remains tied to base
30fd463: the new tests fail twice on that base and pass with the fix. Historical Windows/Linux extracted-package smoke and all 13 extracted-module contracts also passed. These results are reused because the renderer sources, new contract tests and ZIP are unchanged; they are not relabeled as new-head runs.Reproduce focused checks from
archify/:git diff --checkpasses; the working tree is clean.Coordination with #396
Proposed merge order: land this independently useful import-isolation fix first, then update #396 while preserving boundary initialization in
loadDiagram(). Its two standalone diagnostic probes need explicit boundary initialization because they bypass that loader. If the maintainer prefers #396 first, this PR can be adapted afterward.At the unchanged #396 head
80187faf511740005c8982e4a2514f132e08e40b, the earlier local rehearsal passed all 28 targeted checks with those two probe adaptations and their assertions intact. Across the earlier main and #396 variants, 75 paired CLI comparisons preserved exit/stdout/stderr and all 15 successful HTML hash comparisons matched. This is historical compatibility evidence, not a full-suite or regenerated-package validation of #396 combined with today's main.Keeping this PR in Draft pending maintainer confirmation of the order.
Visual evidence
Not applicable: this changes host/CLI initialization, not geometry or Viewer behavior. HTML byte comparisons establish compatibility, not perceptual approval. Local optional browser tests remain skips; hosted browser checks are reported in the linked CI run.
Generated artifacts
archify.zipwas built with official Node 22.23.2 and verified byte-identical on Windows/Linux. A fresh official Node 22.23.2 Linux build after synchronization still matches it exactly. Of 79 entries, onlyarchify/renderers/shared/cli.mjschanges content relative to main.Archive SHA-256:
c8dbcbb916e29f2e1f33d6b4473c7c4f5e303ad0e3705a17f3a3740fb80613d8. No Gallery or Viewer inputs changed.