fix(workflows): honor explicit canonical modes - #6677
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryMedium Risk Overview Core resolution: Surface projection: Mixed action/trigger blocks use Nested Agent tools: Dependency context carries per-tool scoped Reviewed by Cursor Bugbot for commit 0ab738e. Bugbot is set up for automated code reviews on this repo. Configure here. |
|
@BillLeoutsakosvl346 one question -- is this even possible for the runtime state to end up like this? Like is there a repro case where runtime state and UI can actually go out of sync. I assume we update canonical modes everywhere you'd expect to update it? |
Greptile SummaryThe PR makes explicit canonical-mode selections authoritative throughout workflow editing, previews, serialization, validation, Agent tools, triggers, search, and workspace-fork operations while preserving legacy inference paths.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| apps/sim/lib/workflows/subblocks/visibility.ts | Centralizes active-surface projection and explicit canonical-mode resolution used throughout the workflow stack. |
| apps/sim/serializer/index.ts | Serializes only the selected canonical member on the active action or trigger surface while retaining legacy fallback behavior. |
| apps/sim/tools/params-resolver.ts | Resolves Agent tool parameters using scoped canonical modes and preserves supported legacy parameter representations. |
| apps/sim/ee/workspace-forking/lib/remap/remap-references.ts | Restricts resource remapping and dependent clearing to active action-surface tool parameters. |
| apps/sim/lib/workflows/comparison/format-description.test.ts | The previously untyped workflow fixture now satisfies WorkflowState directly and contains the required structural fields. |
Reviews (2): Last reviewed commit: "fix(workflows): honor explicit canonical..." | Re-trigger Greptile
0da857d to
d7f59e0
Compare
|
@icecrasher321 Yes — this can happen with normal saved state. On staging, set an Advanced manual selector/credential, switch back to Basic (the dormant Advanced value is intentionally retained), then clear the Basic value. |
|
@BillLeoutsakosvl346 "but the dependency/preview path used active ?? inactive" --> do you mean the dependsOn and workflow preview in the snapshot? |
|
Yes on |
d7f59e0 to
efb0937
Compare
|
@greptileai review |
efb0937 to
e584265
Compare
e584265 to
73bdab0
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 73bdab0. Configure here.
73bdab0 to
ee2af27
Compare
ee2af27 to
0ab738e
Compare

Summary
canonicalModesentries as authoritative across selector dependencies, previews, serialization, Agent tools, triggers, search, validation, and workspace-fork flows.canonicalModesis absent, including historical value inference,advancedMode, trigger aliases, and direct canonical Agent params.Compatibility matrix
advancedMode: trueNo API, database-schema, persisted-field, generated-metadata, or documentation changes are included.
Validation
git diff --checkpassed