-
Notifications
You must be signed in to change notification settings - Fork 18
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
Throw error if cloud apl GET fails #296
Conversation
🦋 Changeset detectedLatest commit: 68221eb The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Released snapshot build with Install it with pnpm add @saleor/[email protected] |
@saleor/delivery-engineering-js bump - maybe @peelar or @krzysztofwolski you can try to install this from PR to one of ongoing apps to just check if it doesn't break anything, before we merge? |
return undefined; | ||
} | ||
|
||
const parsedResponse = (await response.json().catch((e) => { | ||
debug("Failed to parse response: %s", extractErrorMessage(e)); | ||
debug("%O", e); | ||
|
||
throw new SaleorCloudAplError( | ||
"RESPONSE_BODY_INVALID", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe these error codes should be an enum that we export from the library, so that it's easier for an app to handle these errors?
a3b8593
to
c9e35ca
Compare
Released snapshot build with Install it with pnpm add @saleor/[email protected] |
Released snapshot build with Install it with pnpm add @saleor/[email protected] |
|
Test with existing app first