Closed elena-kolevska closed 8 months ago
@berndverst pls let me know if the DaprGrpcError design and naming look ok to you. I would also like to get your opinion on the integration testing approach I took. I think it can be helpful for other cases too.
Attention: 7 lines
in your changes are missing coverage. Please review.
Comparison is base (
ef73209
) 86.21% compared to head (682f645
) 86.37%.
Files | Patch % | Lines |
---|---|---|
dapr/clients/exceptions.py | 92.75% | 5 Missing :warning: |
dapr/clients/grpc/client.py | 95.23% | 2 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
LGTM. Can you resolve the conflict now that I merged the ruff stuff :)
Marking this ready so the code can be reviewed while I'm working on examples and docs.
Ok, examples and docs are ready :)
I addressed the review comments and I simplified the DaprGrpcError structure. 🙏
I now updated the tox configuration to include your error handling test app. I am expected it to fail (it fails for me locally). You'll have to debug that one some more.
If this PR requires Dapr 1.13, please let me know. In that case we will not be able to successfully run the CI tests until we have Dapr 1.13.0rc1 tagged
If this PR requires Dapr 1.13, please let me know. In that case we will not be able to successfully run the CI tests until we have Dapr 1.13.0rc1 tagged
Yes, that's exactly it! I could only test it with my local dapr build and had to make the following modifications to the README to make it pass:
== APP ==
string added by dapr clidapr run -- python3 error_handling.py
to use my custom dapr buildUnfortunately, I had also commented out all the other examples in the tox.ini so it only ran my test while I was working on it, to keep it faster, but when I was committing, I also reverted the line that added my errors test by mistake. Sorry about that! That explains why the CI test succeeded when I was expecting it to fail. I thought you were doing some voodoo by making dapr cli build from a custom commit. If that is possible, btw, please let me know how it's done :)
I will rerun tests and merge this when 1.13.0rc1 has been tagged. At that point this should all pass :) (I tried it locally with a Dapr build from master)
Description
Improves developer experience on error handling for the new Rich gRPC Errors from Dapr
Issue reference
https://github.com/dapr/python-sdk/issues/648
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list: