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

Handle KeyError better in the service error handler functions #2729

Closed
lorenzo-cavazzi opened this issue Mar 1, 2022 · 1 comment · Fixed by #2845
Closed

Handle KeyError better in the service error handler functions #2729

lorenzo-cavazzi opened this issue Mar 1, 2022 · 1 comment · Fixed by #2845

Comments

@lorenzo-cavazzi
Copy link
Member

This is a follow-up to #2303 (especially to this conversation)

There are a number of different reasons for a KeyError to happen. We should handle this case better in the decorators in renku/service/views/error_handlers.py (or improve where the errors are originally raised, where possible).

In general, trying to catch all the errors we can identify (especially user-generated) and raise a more descriptive error is a good strategy. Everything un-catched could raise a ProgramSomethingError explaining in the devMessage how the parameters were wrong. If something ends up as a Program error but it shouldn't, we can always handle the case as soon as we identify it.

lorenzo-cavazzi added a commit that referenced this issue Apr 19, 2022
fix #2729

Co-authored-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants