New release!
Today we’re releasing new IC WebSocket versions that affect all the SDKs.
New versions
SDKs:
What’s changed
SDKs
We suggest you to update all your SDKs to the latest version.
- we’ve removed the deprecated
ws_send
method from both the Rust and Motoko CDKs. The method was already deprecated in v0.3.2 and now has been removed completely. Usesend
instead.
Motoko
- Due to the newly introduced Motoko v0.11.0 safety feature, calls to sensitive functions now require the
system
pseudo-type. For this reason, now it’s required to initialize the IC WebSocket library using the newly introducedinit
function:let ws = IcWebSocketCdk.IcWebSocket(ws_state, params, handlers); + ws.init<system>(); // <- add this
Please refer to the Motoko v0.11.0 migration guide to understand when you can call functions that use the
system
pseudo-type.
JS
- we’ve updated the
@dfinity/...
dependencies to the new v2.0.0 release. Make sure you upgrade them in your dependencies too. - we’ve additionally fixed an issue that was causing the IC WebSocket JS client to fail to verify the incoming messages certificates.
You can also follow the updated tutorial for reference.