diff --git a/CHANGELOG.md b/CHANGELOG.md index 45ac4abf74..5eece6cde4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## [5.3.20](https://github.com/forcedotcom/sfdx-core/compare/5.3.19...5.3.20) (2023-11-10) + +### Bug Fixes + +- http 420 errors ([6deabcd](https://github.com/forcedotcom/sfdx-core/commit/6deabcd603055786311994cb25c8c9282ff9971d)) + ## [5.3.19](https://github.com/forcedotcom/sfdx-core/compare/5.3.18...5.3.19) (2023-11-08) ### Bug Fixes diff --git a/messages/org.md b/messages/org.md index d4dddcc81e..97524ef844 100644 --- a/messages/org.md +++ b/messages/org.md @@ -65,3 +65,13 @@ We found more than one SandboxProcess with the SandboxName %s. # sandboxNotResumable The sandbox %s cannot resume with status of %s. + +# UnexpectedResponse + +Unexpected response from the platform + +# UnexpectedResponse.actions + +- Check that the instance URL is correct and the org still exists. + +- See what's at the URL that's causing the problem: %s. diff --git a/package.json b/package.json index 938bc0a9cd..cebaf279cd 100644 --- a/package.json +++ b/package.json @@ -51,8 +51,8 @@ "jsforce": "^2.0.0-beta.28", "jsonwebtoken": "9.0.2", "jszip": "3.10.1", - "pino": "^8.16.0", - "pino-abstract-transport": "^1.0.0", + "pino": "^8.16.1", + "pino-abstract-transport": "^1.1.0", "pino-pretty": "^10.2.3", "proper-lockfile": "^4.1.2", "semver": "^7.5.4", @@ -60,7 +60,7 @@ }, "devDependencies": { "@salesforce/dev-scripts": "^6.0.3", - "@salesforce/ts-sinon": "^1.4.18", + "@salesforce/ts-sinon": "^1.4.19", "@types/benchmark": "^2.1.3", "@types/chai-string": "^1.4.4", "@types/jsonwebtoken": "9.0.3", diff --git a/src/org/org.ts b/src/org/org.ts index 1382094343..7b7d2b199c 100644 --- a/src/org/org.ts +++ b/src/org/org.ts @@ -699,7 +699,16 @@ export class Org extends AsyncOptionalCreatable { method: 'GET', }; const conn = this.getConnection(); - await conn.request(requestInfo); + try { + await conn.request(requestInfo); + } catch (e) { + // an html error page like https://computing-connect-6970-dev-ed.scratch.my.salesforce.com/services/data/v50.0 + // where the message is an entire html page + if (e instanceof Error && (e.name.includes('ERROR_HTTP') || e.message.includes('