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

Timeout errors are not properly detected #68

Open
jablan opened this issue Dec 12, 2022 · 0 comments
Open

Timeout errors are not properly detected #68

jablan opened this issue Dec 12, 2022 · 0 comments

Comments

@jablan
Copy link

jablan commented Dec 12, 2022

At least some timeout errors do not have valid JSON, and although their body contains the reason they end up here https://github.com/chargebee/chargebee-ruby/blob/master/lib/chargebee/rest.rb#L82 resulting with a generic error.
Also, rest.rb has JSON parsing on two places, which should be unified.

A/C: Properly handle timeout errors and eventually use this code for them: https://github.com/chargebee/chargebee-ruby/blob/master/lib/chargebee/rest.rb#L65

Bonus points: create different exception types for different failure reasons.

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

No branches or pull requests

1 participant