fix(workflow): use $sourceDescriptions for workflow references#2867
fix(workflow): use $sourceDescriptions for workflow references#2867harshit078 wants to merge 13 commits into
Conversation
🦋 Changeset detectedLatest commit: 34791a3 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Hi @DmitryAnansky , Can you review the PR and check it ? Thanks ! |
Performance Benchmark (Lower is Faster)
|
| if (workflow) { | ||
| return workflow; | ||
| } | ||
| } |
There was a problem hiding this comment.
Probably we need to handle case with
if (isLegacyForm) {
return undefined;
}
|
Could you please update existing tests to use correct and not legacy format? |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want higher recall? High effort reviews run extra passes and find more bugs. A team admin can switch effort levels in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 2658393. Configure here.
|
Hi @DmitryAnansky, I have addressed the comments left by you and resolved cursor bot comments. Can you review the changes again ? thanks ! |

What/Why/How?
$sourceDescriptions.<name>.<workflowId>.$sourceDescriptions.<name>.workflows.<workflowId>form is still maintained.Reference
#2826
Testing
Screenshots (optional)
Check yourself
Security
Note
Low Risk
Localized change to context expression parsing in respect-core; backward compatible and covered by expanded tests.
Overview
Respect now resolves external workflow references using the Arazzo-compliant path
$sourceDescriptions.<name>.<workflowId>(without aworkflowssegment). The older$sourceDescriptions.<name>.workflows.<workflowId>form still works.In
get-value-from-context.ts,resolveValuedistinguishes the spec form (3 path segments) from the legacy form (4 segments withworkflows). For the spec form it looks up a matchingworkflowIdin the source description’sworkflowsarray; if none match, it falls back to a property on the source description (e.g.$sourceDescriptions.test.url). Legacy references only resolve via the workflows list and otherwise returnundefined.Tests and flow-runner examples were updated to the spec form, with added cases for legacy compatibility, field fallback, and missing workflows.
Reviewed by Cursor Bugbot for commit 34791a3. Bugbot is set up for automated code reviews on this repo. Configure here.