-
Notifications
You must be signed in to change notification settings - Fork 27
feat!: change connection encryption interface to uint8arraylist #278
Conversation
What's the change to |
Its not yet updated in noise and secio, will do next week |
secio is long deprecated & is unsupported so there's no need to spend time on that. The other implementation that'll need updating is PlainText but noise should be done first as it doesn't depend on libp2p. Looking at noise, there's some concatenation being done during the handshake that's now unnecessary since you can write a This pipeline is the hot code path but from what I can see because What am I missing? |
## [@libp2p/interface-connection-encrypter-v2.0.0](https://github.com/libp2p/js-libp2p-interfaces/compare/@libp2p/interface-connection-encrypter-v1.0.3...@libp2p/interface-connection-encrypter-v2.0.0) (2022-08-07) ### ⚠ BREAKING CHANGES * change connection encryption interface to uint8arraylist (#278) ### Features * change connection encryption interface to uint8arraylist ([#278](#278)) ([1fa580c](1fa580c)) ### Trivial Changes * update project config ([#271](#271)) ([59c0bf5](59c0bf5))
🎉 This PR is included in version @libp2p/interface-connection-encrypter-v2.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
## [@libp2p/interface-connection-v3.0.0](https://github.com/libp2p/js-libp2p-interfaces/compare/@libp2p/interface-connection-v2.1.1...@libp2p/interface-connection-v3.0.0) (2022-08-07) ### ⚠ BREAKING CHANGES * change stream muxer interface (#279) * change connection encryption interface to uint8arraylist (#278) ### Features * change connection encryption interface to uint8arraylist ([#278](#278)) ([1fa580c](1fa580c)) * change stream muxer interface ([#279](#279)) ([1ebe269](1ebe269)) ### Trivial Changes * update project config ([#271](#271)) ([59c0bf5](59c0bf5))
🎉 This PR is included in version @libp2p/interface-connection-v3.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
## [@libp2p/interface-connection-encrypter-compliance-tests-v2.0.0](https://github.com/libp2p/js-libp2p-interfaces/compare/@libp2p/interface-connection-encrypter-compliance-tests-v1.0.2...@libp2p/interface-connection-encrypter-compliance-tests-v2.0.0) (2022-08-07) ### ⚠ BREAKING CHANGES * change connection encryption interface to uint8arraylist (#278) ### Features * change connection encryption interface to uint8arraylist ([#278](#278)) ([1fa580c](1fa580c)) ### Trivial Changes * update project config ([#271](#271)) ([59c0bf5](59c0bf5)) ### Dependencies * update sibling dependencies ([f859920](f859920)) * update sibling dependencies ([93a89b1](93a89b1))
🎉 This PR is included in version @libp2p/interface-connection-encrypter-compliance-tests-v2.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
## [@libp2p/interface-mocks-v4.0.0](https://github.com/libp2p/js-libp2p-interfaces/compare/@libp2p/interface-mocks-v3.0.3...@libp2p/interface-mocks-v4.0.0) (2022-08-07) ### ⚠ BREAKING CHANGES * change stream muxer interface (#279) * change connection encryption interface to uint8arraylist (#278) ### Features * change connection encryption interface to uint8arraylist ([#278](#278)) ([1fa580c](1fa580c)) * change stream muxer interface ([#279](#279)) ([1ebe269](1ebe269)) ### Dependencies * update sibling dependencies ([f75e927](f75e927)) * update sibling dependencies ([d98a5ea](d98a5ea)) * update sibling dependencies ([f859920](f859920)) * update sibling dependencies ([93a89b1](93a89b1))
🎉 This PR is included in version @libp2p/interface-mocks-v4.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
I think you are right. I don't think noise cares if it yields or returns Uint8Array or Uint8ArrayList. But ain't we gonna have type issues if mplex or yamux is trying to pipe Uint8ArrayList into Secured connection that accepts Uint8Arrays only? |
No, because everything goes through |
ugh, should we revert this change and release then? |
Yes & I think the generics can be removed from export interface MultiaddrConnection<T extends Uint8Array | Uint8ArrayList = Uint8Array> extends Duplex<T> { can go back to export interface MultiaddrConnection extends Duplex<Uint8Array> { |
replacing #275
BREAKING CHANGE: connection encryption interface now accepts and yields uint8arraylist instead of uint8array