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

Expand error catching for request to graph #303

Open
alyssadai opened this issue Apr 12, 2024 · 1 comment
Open

Expand error catching for request to graph #303

alyssadai opened this issue Apr 12, 2024 · 1 comment
Labels
_flag:stale [BOT ONLY] Flag issue that hasn't been updated in a while and needs to be triaged again maint:usability General improvements to product usability that are unrelated to feature prioritization. type:maintenance Upkeeping efforts & catch-up corrective improvements that are not Features nor Bugs

Comments

@alyssadai
Copy link
Contributor

alyssadai commented Apr 12, 2024

(See related neurobagel/federation-api#74 for reference)

The type of request error we're currently trying to catch is too narrow:

api/app/api/crud.py

Lines 52 to 57 in 1f89c22

except httpx.ConnectTimeout as exc:
raise HTTPException(
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR,
detail="Timed out while connecting to the server. You may not be on an authorized network to perform this request.",
) from exc

any other type of timeout or error from the graph is not caught and results in an Internal server error. We may want to add a catch for a generic Exception and return any error message we get so API users get a more useful error. Basically, we want to minimize the dreaded Internal server error!!!!

We may also want to double check the error catching for requests related to other API endpoints, such as /attributes.

@alyssadai alyssadai added the flag:schedule Flag issue that should go on the roadmap or backlog. label Apr 12, 2024
@rmanaem rmanaem added type:maintenance Upkeeping efforts & catch-up corrective improvements that are not Features nor Bugs maint:usability General improvements to product usability that are unrelated to feature prioritization. and removed flag:schedule Flag issue that should go on the roadmap or backlog. labels Apr 17, 2024
Copy link

github-actions bot commented Jul 2, 2024

We want to keep our issues up to date and active. This issue hasn't seen any activity in the last 75 days.
We have applied the _flag:stale label to indicate that this issue should be reviewed again.
When you review, please reread the spec and then apply one of these three options:

  • prioritize: apply the flag:schedule label to suggest moving this issue into the backlog now
  • close: if the issue is no longer relevant, explain why (give others a chance to reply) and then close.
  • archive: sometimes an issue has important information or ideas but we won't work on it soon. In this case
    apply the someday label to show that this won't be prioritized. The stalebot will ignore issues with this
    label in the future. Use sparingly!

@github-actions github-actions bot added the _flag:stale [BOT ONLY] Flag issue that hasn't been updated in a while and needs to be triaged again label Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
_flag:stale [BOT ONLY] Flag issue that hasn't been updated in a while and needs to be triaged again maint:usability General improvements to product usability that are unrelated to feature prioritization. type:maintenance Upkeeping efforts & catch-up corrective improvements that are not Features nor Bugs
Projects
Status: No status
Development

No branches or pull requests

2 participants