fix: pass workflow inputs to success and failure actions#2796
fix: pass workflow inputs to success and failure actions#2796harshit078 wants to merge 26 commits into
Conversation
🦋 Changeset detectedLatest commit: b12d4c7 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 |
|
Thanks @harshit078 for contribution! Please, fix the issue reported by bugbot. I left comment as well. Additionally, please add docs for a new rule. |
|
Hey @AlbinaBlazhko17 , I have pushed a fix addressing both cursor and your comment along with addition of docs for |
|
|
||
| export const SpecParametersInByContext: Arazzo1Rule = () => { | ||
| return { | ||
| Step: { |
There was a problem hiding this comment.
Please, add to this rule Workflowvisitor, because you miss, that Workflow also accepts parameters per arazzo.ts:179.
|
@harshit078 Could you please implement the new functionality with parameters in |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 8b47027. Configure here.
|
Hey @AlbinaBlazhko17 , I have addressed the comments you left and created a seperate parameter interface and used that. I am not sure on how to resolve the 2 failing test though. Thanks ! |
| type: 'array', | ||
| items: parameter, | ||
| } as const; | ||
| export const actionParameter = { |
There was a problem hiding this comment.
Add please spacing between Parameters, actionParameter and actionParameters.
|
Hi @harshit078! Almost done, left minor comments, otherwise looks good.
|
|
Hi @AlbinaBlazhko17 , I have tried doing both the commands and pushed the commit for it but the tests still fails. Is there something I might be doing wrong ? |

What/Why/How?
spec-parameters-in-by-contextArazzo ruleparametersproperty in interface of workflow for success and failure action objects.Reference
#2735
Testing
Screenshots (optional)
Check yourself
Security
Note
Medium Risk
New default-on lint rule can fail CI on existing Arazzo specs; Respect behavior changes when using action
parameterson workflow goto actions.Overview
Adds the
spec-parameters-in-by-contextArazzo lint rule and wires it into built-in rulesets (errorin spec / recommended-strict / all, warn in recommended). The rule enforces when parameterinmust be present vs omitted (operation/workflow-level vsworkflowIdsteps) and rejectsparameterson success/failure actions unless the action references aworkflowId.Schema & lint: Introduces
ActionParameter/ActionParameters(noin) on success/failure actions in core types and Respect’s Arazzo schema; extendsparameters-uniqueto dedupe action parameters.Respect runtime:
onSuccess/onFailureactions withworkflowIdcan passparametersthat are resolved into the target workflow’sinputs(sharedmapParametersToWorkflowInputsinrun-step), with tests coveringonSuccessmapping.Docs and changeset note that stricter presets may report new lint errors on existing Arazzo files.
Reviewed by Cursor Bugbot for commit b12d4c7. Bugbot is set up for automated code reviews on this repo. Configure here.