Merged
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3450 +/- ##
==========================================
+ Coverage 98.18% 98.21% +0.02%
==========================================
Files 399 404 +5
Lines 11136 11314 +178
Branches 1746 1763 +17
==========================================
+ Hits 10934 11112 +178
Misses 202 202 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Mrtenz
reviewed
Jun 12, 2025
Mrtenz
requested changes
Jun 13, 2025
| url: string; | ||
| openPromise: Promise<void>; | ||
| // eslint-disable-next-line no-restricted-globals | ||
| socket: WebSocket; |
Member
There was a problem hiding this comment.
Note that this doesn't work on Node.js. Probably fine though.
Mrtenz
reviewed
Jun 13, 2025
Mrtenz
reviewed
Jun 13, 2025
Mrtenz
approved these changes
Jun 13, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements the rewritten SIP-20 to enable WebSocket support in Snaps.
WebSockets are supported via the
WebSocketServicewhich runs in the client and handles open WebSocket connections for the Snap. The Snap is notified of WebSocket events viaonWebSocketEventand is notified ofopen,closeandmessage. Messages can also be sent from the Snap usingsnap_sendWebSocketMessage. Both string and binary payloads are allowed.All of the new RPC methods are gated on
endowment:network-access, which is also the permission required to exposeonWebSocketEvent.