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

[BB-95] fix: handle errors #13

Merged
merged 9 commits into from
Oct 17, 2024
Merged

[BB-95] fix: handle errors #13

merged 9 commits into from
Oct 17, 2024

Conversation

mgaeta
Copy link
Contributor

@mgaeta mgaeta commented Oct 4, 2024

Description

  • update everything in go.mod to latest
  • move configs into pkg
  • pass ratelimitData up from uhttp to the connector
  • try and parse the JSON message if we get a 4xx response
  • if this PR is too large I can split it up by commits

Fixes BB-95.

@mgaeta mgaeta requested a review from a team October 4, 2024 19:50
@mgaeta mgaeta force-pushed the marcos/fix/bb-95-handle-error branch from c80ad7f to 3c63741 Compare October 4, 2024 20:30
resp, err := c.httpClient.Do(
req,
WithJSONResponse(&response),
uhttp.WithRatelimitData(ratelimitData),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Passing a nil pointer to uhttp.WithRatelimitData() causes a panic.

@mgaeta mgaeta requested a review from ggreer October 9, 2024 18:58
@ggreer ggreer merged commit 7c11d44 into main Oct 17, 2024
3 checks passed
@ggreer ggreer deleted the marcos/fix/bb-95-handle-error branch October 17, 2024 20:17
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

Successfully merging this pull request may close these issues.

2 participants