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

Better error classification in clients/feeder #1888

Open
ashu26jha opened this issue Jun 3, 2024 · 2 comments
Open

Better error classification in clients/feeder #1888

ashu26jha opened this issue Jun 3, 2024 · 2 comments
Labels

Comments

@ashu26jha
Copy link
Contributor

Problem

Currently, if we try to fetch the block (lets say 1,000,000) from the feeder we get 400 Bad Request which is a generic error. Meanwhile the feeder gateway shows:

{"code": "StarknetErrorCode.BLOCK_NOT_FOUND", "message": "Block number 1000000 was not found."}

We want the error message to reflect the response.

Advantages

  1. This will help in debugging.
  2. This will be needed to improve reorg handling
@ashu26jha
Copy link
Contributor Author

#1820

@anubhavitis
Copy link

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I have over 2 years of experience in building Go-based applications, having worked with companies like CoinSwitch and currently Fileverse. I have designed, built, and deployed services from scratch that cater to hundreds of thousands of users daily. My expertise spans supporting both Web2 applications and Web3 dApps, making me well-equipped to contribute effectively to your project

How I plan on tackling this issue

Things that are on top of my mind:

  • Review the code where the block fetch request is made and where the error is being handled.
  • Locate the part of the code that translates errors from the feeder gateway into HTTP responses.
  • Update the error handling logic to capture specific error responses from the feeder gateway.
  • Modify the HTTP response to include the specific error message from the feeder gateway.
  • tests: unit tests and over staging/dev environments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants