-
-
Notifications
You must be signed in to change notification settings - Fork 75
Feat: Exception handling #267
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
base: main
Are you sure you want to change the base?
Conversation
2e6187b
to
4bd1829
Compare
4bd1829
to
3b0e537
Compare
There is one problem I'm still solving: throwing the exception when it hasn't been handled. |
@ksassnowski I implemented a feature that throws exceptions when they are not handled by any middleware. To achieve this, we need to track whether an exception has been handled, so I decided to wrap exceptions with a I would appreciate it if you could review this and share your feedback! |
This PR adds exception handling to the downloader and allows middleware to act upon caught exceptions.
Personally, I need this for handling Javascript (Browsershot) exceptions, so I can retry them. In order to act upon thrown exceptions during the request being sent, exception handling is needed at the downloader level.