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

show crates.io search errors to the user without logging them #2480

Open
syphar opened this issue Apr 4, 2024 · 2 comments
Open

show crates.io search errors to the user without logging them #2480

syphar opened this issue Apr 4, 2024 · 2 comments
Assignees
Labels
A-backend Area: Webserver backend E-easy Effort: Should be easy to implement and would make a good first PR mentor This has instructions for getting started P-low Low priority issues

Comments

@syphar
Copy link
Member

syphar commented Apr 4, 2024

We are using the crates.io search API to power our own crate-search.

Sometimes the crates.io API returns 4xx or 5xx errors because of wrong queries or timeouts.

These errors can be shown to the user, but there is no need to report them to sentry or log them as errors.

We could add a new metric to track the amount of errors.

@syphar syphar added mentor This has instructions for getting started E-easy Effort: Should be easy to implement and would make a good first PR A-backend Area: Webserver backend labels Apr 4, 2024
@syphar
Copy link
Member Author

syphar commented Apr 4, 2024

instructions:

  • web::releases::get_search_results fetches the search results, it's used in web::releases::search_handler
  • our logging config would send everything that is logged with tracing::error! to sentry, and also every server error
  • so either the handler or the method have to be changed so we don't generate a server error any more, but just a warning.

@syphar syphar added the P-low Low priority issues label Apr 4, 2024
@byfnoel
Copy link

byfnoel commented Sep 4, 2024

@rustbot claim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-backend Area: Webserver backend E-easy Effort: Should be easy to implement and would make a good first PR mentor This has instructions for getting started P-low Low priority issues
Projects
None yet
Development

No branches or pull requests

2 participants