Errors like:
return Flags{}, &FlagsmithAPIError{msg: fmt.Sprintf("flagsmith: error performing request to Flagsmith API: %s", err)}
Are not wrapped with %w e.g.
return Flags{}, &FlagsmithAPIError{msg: fmt.Sprintf("flagsmith: error performing request to Flagsmith API: %w", err)}
This makes handling errors like -
Failed to fetch flags with error:
flagsmith:
error performing request to Flagsmith API:
Post "https://api.flagsmith.com/api/v1/identities/":
context deadline exceeded (Client.Timeout exceeded while awaiting headers)
a challenge. I'm happy to make a PR there's 5 places.
Errors like:
Are not wrapped with
%we.g.This makes handling errors like -
a challenge. I'm happy to make a PR there's 5 places.