Bump ws from 7.5.6 to 8.4.0 in /desktop (#3240)
Summary: Pull Request resolved: https://github.com/facebook/flipper/pull/3240 Bumps [ws](https://github.com/websockets/ws) from 7.5.6 to 8.4.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/websockets/ws/releases">ws's releases</a>.</em></p> <blockquote> <h2>8.4.0</h2> <h1>Features</h1> <ul> <li>Added ability to generate custom masking keys (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1990">https://github.com/facebook/flipper/issues/1990</a>).</li> </ul> <h2>8.3.0</h2> <h1>Features</h1> <ul> <li>Added ability to pause and resume a <code>WebSocket</code> (0a8c7a9c).</li> </ul> <h1>Bug fixes</h1> <ul> <li>Fixed a bug that could prevent the connection from being closed cleanly when using the stream API (ed2b8039).</li> <li>When following redirects, an error is now emitted and not thrown if the redirect URL is invalid (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1980">https://github.com/facebook/flipper/issues/1980</a>).</li> </ul> <h2>8.2.3</h2> <h1>Bug fixes</h1> <ul> <li>When context takeover is enabled, messages are now compressed even if their size is below the value of the <code>perMessageDeflate.threshold</code> option (41ae5631).</li> </ul> <h2>8.2.2</h2> <h1>Bug fixes</h1> <ul> <li>Some closing operations are now run only if needed (ec9377ca).</li> </ul> <h2>8.2.1</h2> <h1>Bug fixes</h1> <ul> <li>Fixed an issue where the socket was not resumed, preventing the connection from being closed cleanly (869c9892).</li> </ul> <h2>8.2.0</h2> <h1>Features</h1> <ul> <li>Added <code>WebSocket.WebSocket</code> as an alias for <code>WebSocket</code> and <code>WebSocket.WebSocketServer</code> as an alias for <code>WebSocket.Server</code> to fix name consistency and improve interoperability with the ES module wrapper (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1935">https://github.com/facebook/flipper/issues/1935</a>).</li> </ul> <h2>8.1.0</h2> <h1>Features</h1> <ul> <li>Added ability to skip UTF-8 validation (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1928">https://github.com/facebook/flipper/issues/1928</a>).</li> </ul> <h1>Bug fixes</h1> <ul> <li>Fixed an issue with a breaking change in Node.js master (6a72da3e).</li> <li>Fixed a misleading error message (c95e695d).</li> </ul> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="00c34d726d"><code>00c34d7</code></a> [dist] 8.4.0</li> <li><a href="35d45c2a4f"><code>35d45c2</code></a> [perf] Skip masking and unmasking if the masking key is zero</li> <li><a href="eb2e3a84a1"><code>eb2e3a8</code></a> [feature] Introduce the <code>generateMask</code> option</li> <li><a href="c82b08737f"><code>c82b087</code></a> [dist] 8.3.0</li> <li><a href="0a8c7a9c4f"><code>0a8c7a9</code></a> [api] Add <code>WebSocket#pause()</code> and <code>WebSocket#resume()</code></li> <li><a href="ed2b803905"><code>ed2b803</code></a> [fix] Resume the socket in the <code>CLOSING</code> state</li> <li><a href="b8186dd115"><code>b8186dd</code></a> [fix] Do not throw if the redirect URL is invalid (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1980">https://github.com/facebook/flipper/issues/1980</a>)</li> <li><a href="5a905e49be"><code>5a905e4</code></a> [minor] Add missing label to the issue form</li> <li><a href="89d81e8670"><code>89d81e8</code></a> [minor] Fix nit</li> <li><a href="4916d03ad8"><code>4916d03</code></a> [minor] Allow to write frames with up to 2^48 - 1 bytes of data (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1973">https://github.com/facebook/flipper/issues/1973</a>)</li> <li>Additional commits viewable in <a href="https://github.com/websockets/ws/compare/7.5.6...8.4.0">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `dependabot rebase` will rebase this PR - `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `dependabot merge` will merge this PR after your CI passes on it - `dependabot squash and merge` will squash and merge this PR after your CI passes on it - `dependabot cancel merge` will cancel a previously requested merge and block automerging - `dependabot reopen` will reopen this PR if it is closed - `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Pull Request resolved: https://github.com/facebook/flipper/pull/3218 Reviewed By: antonk52, timur-valiev Differential Revision: D33348279 Pulled By: nikoant fbshipit-source-id: c245f53556e8f58ba1df619d3d0e106e8e5b1911
This commit is contained in:
committed by
Facebook GitHub Bot
parent
4f467ff147
commit
97f861b2dc
@@ -38,7 +38,7 @@
|
|||||||
"tmp": "^0.2.1",
|
"tmp": "^0.2.1",
|
||||||
"uuid": "^8.3.2",
|
"uuid": "^8.3.2",
|
||||||
"which": "^2.0.2",
|
"which": "^2.0.2",
|
||||||
"ws": "^7.5.6",
|
"ws": "^8.4.0",
|
||||||
"xdg-basedir": "^4.0.0"
|
"xdg-basedir": "^4.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
@@ -51,7 +51,7 @@
|
|||||||
"@types/rsocket-tcp-server": "^0.0.2",
|
"@types/rsocket-tcp-server": "^0.0.2",
|
||||||
"@types/split2": "^3.2.1",
|
"@types/split2": "^3.2.1",
|
||||||
"@types/tmp": "^0.2.2",
|
"@types/tmp": "^0.2.2",
|
||||||
"@types/ws": "^7.4.7",
|
"@types/ws": "^8.2.2",
|
||||||
"@types/which": "^2.0.1",
|
"@types/which": "^2.0.1",
|
||||||
"memorystream": "^0.3.1",
|
"memorystream": "^0.3.1",
|
||||||
"tmp": "^0.2.1"
|
"tmp": "^0.2.1"
|
||||||
|
|||||||
@@ -161,11 +161,12 @@ class ServerWebSocket extends ServerAdapter {
|
|||||||
this.handleClientQuery(ctx);
|
this.handleClientQuery(ctx);
|
||||||
this.handleConnectionAttempt(ctx);
|
this.handleConnectionAttempt(ctx);
|
||||||
|
|
||||||
ws.on('message', async (message: unknown) => {
|
ws.on('message', async (message: WebSocket.RawData) => {
|
||||||
try {
|
try {
|
||||||
const parsedMessage = this.handleMessageDeserialization(message);
|
const messageString = message.toString();
|
||||||
|
const parsedMessage = this.handleMessageDeserialization(messageString);
|
||||||
// Successful deserialization is a proof that the message is a string
|
// Successful deserialization is a proof that the message is a string
|
||||||
this.handleMessage(ctx, parsedMessage, message as string);
|
this.handleMessage(ctx, parsedMessage, messageString);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
// See the reasoning in the error handler for a `connection` event
|
// See the reasoning in the error handler for a `connection` event
|
||||||
ws.emit('error', error);
|
ws.emit('error', error);
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
"mac-ca": "^1.0.6",
|
"mac-ca": "^1.0.6",
|
||||||
"mkdirp": "^1.0.4",
|
"mkdirp": "^1.0.4",
|
||||||
"node-fetch": "^2.6.6",
|
"node-fetch": "^2.6.6",
|
||||||
"ws": "^7.5.6",
|
"ws": "^8.4.0",
|
||||||
"xdg-basedir": "^4.0.0",
|
"xdg-basedir": "^4.0.0",
|
||||||
"yargs": "^16.2.0"
|
"yargs": "^16.2.0"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -2870,10 +2870,10 @@
|
|||||||
resolved "https://registry.yarnpkg.com/@types/which/-/which-2.0.1.tgz#27ecd67f915b7c3d6ba552135bb1eecd66e63501"
|
resolved "https://registry.yarnpkg.com/@types/which/-/which-2.0.1.tgz#27ecd67f915b7c3d6ba552135bb1eecd66e63501"
|
||||||
integrity sha512-Jjakcv8Roqtio6w1gr0D7y6twbhx6gGgFGF5BLwajPpnOIOxFkakFhCq+LmyyeAz7BX6ULrjBOxdKaCDy+4+dQ==
|
integrity sha512-Jjakcv8Roqtio6w1gr0D7y6twbhx6gGgFGF5BLwajPpnOIOxFkakFhCq+LmyyeAz7BX6ULrjBOxdKaCDy+4+dQ==
|
||||||
|
|
||||||
"@types/ws@^7.4.7":
|
"@types/ws@^8.2.2":
|
||||||
version "7.4.7"
|
version "8.2.2"
|
||||||
resolved "https://registry.yarnpkg.com/@types/ws/-/ws-7.4.7.tgz#f7c390a36f7a0679aa69de2d501319f4f8d9b702"
|
resolved "https://registry.yarnpkg.com/@types/ws/-/ws-8.2.2.tgz#7c5be4decb19500ae6b3d563043cd407bf366c21"
|
||||||
integrity sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww==
|
integrity sha512-NOn5eIcgWLOo6qW8AcuLZ7G8PycXu0xTxxkS6Q18VWFxgPUSOwV0pBj2a/4viNZVu25i7RIB7GttdkAIUUXOOg==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@types/node" "*"
|
"@types/node" "*"
|
||||||
|
|
||||||
@@ -12612,11 +12612,16 @@ ws@^1.1.5:
|
|||||||
options ">=0.0.5"
|
options ">=0.0.5"
|
||||||
ultron "1.0.x"
|
ultron "1.0.x"
|
||||||
|
|
||||||
ws@^7.4.5, ws@^7.5.6:
|
ws@^7.4.5:
|
||||||
version "7.5.6"
|
version "7.5.6"
|
||||||
resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.6.tgz#e59fc509fb15ddfb65487ee9765c5a51dec5fe7b"
|
resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.6.tgz#e59fc509fb15ddfb65487ee9765c5a51dec5fe7b"
|
||||||
integrity sha512-6GLgCqo2cy2A2rjCNFlxQS6ZljG/coZfZXclldI8FB/1G3CCI36Zd8xy2HrFVACi8tfk5XrgLQEk+P0Tnz9UcA==
|
integrity sha512-6GLgCqo2cy2A2rjCNFlxQS6ZljG/coZfZXclldI8FB/1G3CCI36Zd8xy2HrFVACi8tfk5XrgLQEk+P0Tnz9UcA==
|
||||||
|
|
||||||
|
ws@^8.4.0:
|
||||||
|
version "8.4.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/ws/-/ws-8.4.0.tgz#f05e982a0a88c604080e8581576e2a063802bed6"
|
||||||
|
integrity sha512-IHVsKe2pjajSUIl4KYMQOdlyliovpEPquKkqbwswulszzI7r0SfQrxnXdWAEqOlDCLrVSJzo+O1hAwdog2sKSQ==
|
||||||
|
|
||||||
ws@~8.2.3:
|
ws@~8.2.3:
|
||||||
version "8.2.3"
|
version "8.2.3"
|
||||||
resolved "https://registry.yarnpkg.com/ws/-/ws-8.2.3.tgz#63a56456db1b04367d0b721a0b80cae6d8becbba"
|
resolved "https://registry.yarnpkg.com/ws/-/ws-8.2.3.tgz#63a56456db1b04367d0b721a0b80cae6d8becbba"
|
||||||
|
|||||||
Reference in New Issue
Block a user