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

Add a new AgentError field in the agent protos #5916

Merged

Conversation

RRap0so
Copy link
Contributor

@RRap0so RRap0so commented Oct 25, 2024

Why are the changes needed?

This aligns Agent Errors with all other Flyte Errors, meaning that similarly to ContainerError we now have AgentError. It was decided to use a new AgentError due to being calls to an Agent Service and not necessarily containers running so it's better to keep it clean.

What changes were proposed in this pull request?

Adding a new AgentError

Implement the usage of AgentError

Little tweaks and error message improvements

How was this patch tested?

Unit tests added.

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

Signed-off-by: Rafael Raposo <[email protected]>
@RRap0so RRap0so force-pushed the rafaelraposo/add-custom-error-handling branch from 73bf769 to 45b2f7c Compare October 25, 2024 12:35
Copy link

codecov bot commented Oct 25, 2024

Codecov Report

Attention: Patch coverage is 12.00000% with 66 lines in your changes missing coverage. Please review.

Project coverage is 37.02%. Comparing base (d1a723e) to head (6a371a0).
Report is 16 commits behind head on master.

Files with missing lines Patch % Lines
flyteidl/gen/pb-go/flyteidl/admin/agent.pb.go 2.98% 65 Missing ⚠️
...yteplugins/go/tasks/plugins/webapi/agent/plugin.go 87.50% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5916      +/-   ##
==========================================
- Coverage   37.03%   37.02%   -0.02%     
==========================================
  Files        1313     1313              
  Lines      131622   131691      +69     
==========================================
+ Hits        48742    48753      +11     
- Misses      78652    78710      +58     
  Partials     4228     4228              
Flag Coverage Δ
unittests-datacatalog 51.58% <ø> (ø)
unittests-flyteadmin 54.10% <ø> (+0.02%) ⬆️
unittests-flytecopilot 22.23% <ø> (ø)
unittests-flytectl 62.46% <ø> (ø)
unittests-flyteidl 7.24% <2.98%> (-0.02%) ⬇️
unittests-flyteplugins 53.69% <87.50%> (+0.01%) ⬆️
unittests-flytepropeller 43.11% <ø> (ø)
unittests-flytestdlib 55.18% <ø> (+0.01%) ⬆️

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.


🚨 Try these New Features:

Signed-off-by: Rafael Raposo <[email protected]>
@RRap0so RRap0so marked this pull request as ready for review November 14, 2024 08:15
Signed-off-by: Rafael Raposo <[email protected]>
Signed-off-by: Rafael Raposo <[email protected]>
@RRap0so RRap0so changed the title Add AgentErrors Add a new AgentError field in the agent protos Nov 14, 2024
Comment on lines +188 to 189
logger.Errorf(ctx, "failed to receive from server %s", err.Error())
return nil, nil, err
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is great, even if this IDL change is not accepted, we should still accept this.

Copy link
Member

@Future-Outlier Future-Outlier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It overall looks super great, just need @EngHabu for approving this.

Signed-off-by: Rafael Raposo <[email protected]>
Signed-off-by: Rafael Raposo <[email protected]>
@pingsutw pingsutw merged commit 789836b into flyteorg:master Nov 22, 2024
50 of 52 checks passed
@RRap0so RRap0so deleted the rafaelraposo/add-custom-error-handling branch November 22, 2024 23:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants