Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return InvalidArgument for workflow compilation failures in CreateWorkflow #4566

Merged
merged 3 commits into from
Dec 11, 2023

Conversation

katrogan
Copy link
Contributor

@katrogan katrogan commented Dec 8, 2023

Tracking issue

#4565

Why are the changes needed?

Invalid workflow specs passed to CreateWorkflow calls currently return Internal grpc status response codes and are erroneously treated as server rather than user errors.

As far as I could tell, the compiler propagates compiler errors that only surface due to invalid workflow definitions

What changes were proposed in this pull request?

Updates workflow compilation handling to return a more accurate response code.

How was this patch tested?

Added unit tests.

Setup process

Screenshots

Check all the applicable boxes

  • I updated the documentation accordingly.
  • All new and existing tests passed.
  • All commits are signed-off.

Related PRs

Docs link

@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Dec 8, 2023
Signed-off-by: Katrina Rogan <[email protected]>
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Dec 8, 2023
Copy link

codecov bot commented Dec 8, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (91d24a9) 58.98% compared to head (0a6f122) 58.92%.

❗ Current head 0a6f122 differs from pull request most recent head c89b417. Consider uploading reports for the commit c89b417 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4566      +/-   ##
==========================================
- Coverage   58.98%   58.92%   -0.06%     
==========================================
  Files         621      620       -1     
  Lines       52483    52432      -51     
==========================================
- Hits        30957    30896      -61     
- Misses      19059    19071      +12     
+ Partials     2467     2465       -2     
Flag Coverage Δ
unittests 58.92% <100.00%> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@katrogan
Copy link
Contributor Author

katrogan commented Dec 8, 2023

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Dec 9, 2023
@hamersaw hamersaw merged commit a5a9509 into master Dec 11, 2023
39 checks passed
@hamersaw hamersaw deleted the workflow-compilation-failure branch December 11, 2023 17:00
pvditt pushed a commit that referenced this pull request Dec 13, 2023
…kflow (#4566)

* Return InvalidArgument for workflow compilation failures in CreateWorkflow

Signed-off-by: Katrina Rogan <[email protected]>

* lint

Signed-off-by: Katrina Rogan <[email protected]>

---------

Signed-off-by: Katrina Rogan <[email protected]>
Co-authored-by: Dan Rammer <[email protected]>
Signed-off-by: Paul Dittamo <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants