Repository navigation
fix(hierarchy): the views under a workflow instance are read from the hierarchy rooted at it - #240
Merged
Merged
Conversation
… hierarchy rooted at it A unit answered by a past run (`circuit = picorv32_flow(instance=RUN)`) runs nothing with its parent, and the parent's hierarchy export has nothing under it. Every view under it fell back to a plan of its own, and a workflow made by a factory there (`streamblocks_flow(design=...)()`) had no `design`: "ModuleNotFoundError: No module named 'streamblocks.designs.<design>'". Its insides are what that run elaborated: its workflow, as a root of its own. A view at or under the deepest crumb answered by a past run (`hierarchyRootAt`) is read from the hierarchy rooted at that crumb, by the instance names below it. The outline and the node lists stay the trail root's, whose paths the trail has. Claude-Session: https://claude.ai/code/session_011UYzzUKxNqKPdmLsRmJ6Xu
…t once, one crumb rule - Under a unit answered by a past run, the view carries no list of nodes: the trail root's nodes are not that run's, and the list's run is the view's (it would open the root's viewers against the past run). - The unit's export and the trail root's (for the outline) are asked at once; a view whose trail root does not export is drawn without an outline, and the log says so. - recordedRunOfTrail takes its crumb from hierarchyRootAt, so the run a view is drawn from and the hierarchy it is read from are rooted at the same crumb. - The tests' temporary folders are removed. Claude-Session: https://claude.ai/code/session_011UYzzUKxNqKPdmLsRmJ6Xu
Owner
Author
|
Review (
Not changed:
|
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.
What was wrong
Open
orfs/picorv32_orfs.pyand step intocircuit(picorv32_flow(instance=RUN), a workflow instance answered by runpicorv32-1). Then double-clickflow. The view fails with:picorv32_orfsleaves the instance out. It runs nothing with its parent, so the export has nocircuitand nothing under it.circuittherefore fell back to a plan of its own.flowis made by a factory,streamblocks_flow(design="picorv32")(). Planned on its own it has nodesign, so the module path keeps the placeholder.picorv32_flow.pyas the root, the sameflowopens fine.The fix
hierarchyRootAt(trail)(shared) returns the deepest crumb that carriesrecordedRun(fix(run): the edges inside a workflow instance are drawn from the run it nests #239). A view at or under that crumb is read from the hierarchy rooted there, by the instance names below it.Tests
hierarchy-cache.test.ts, 4 new tests:hierarchyRootAttakes the deepest crumb withrecordedRun, never the root crumb.Typecheck and neutrality pass. The diagram-server (1059) and diagram-client (1000) suites pass.
variant-node-create-wizard.test.tstimes out at 5 s on this machine. It stubs the sidecar and imports nothing touched here, and it passed in main's CI.Live check
VS Code harness, on a copy of the ORFS workspace with run
picorv32-1:picorv32_orfs→circuit: 16 edges, 14 green, as with fix(run): the edges inside a workflow instance are drawn from the run it nests #239.flow: drawn (sw, hw, perf), all 28 edges green from the recorded run. Before the fix: the error above.perf: drawn, 60 of 108 edges green.picorv32_orfs: its own runs, of which this copy has none.https://claude.ai/code/session_011UYzzUKxNqKPdmLsRmJ6Xu