From 8f867404e3e950b6e491c8831068962c6968ed4e Mon Sep 17 00:00:00 2001 From: Sasha <118575614+weboko@users.noreply.github.com> Date: Tue, 12 Mar 2024 02:18:40 +0100 Subject: [PATCH] feat: add cross peer dependency for @waku packages (#1889) * move core package * move dns-discovery * move enr * move local discovery * move message encryption * move message encryption[2] * move message-hash * move peer exchange * move relay * move sdk * move utils --- package-lock.json | 116 +++++++++++++++++- packages/core/package.json | 10 +- packages/dns-discovery/package.json | 10 ++ packages/enr/package.json | 13 ++ .../local-peer-cache-discovery/package.json | 13 ++ packages/message-encryption/package.json | 11 ++ packages/message-hash/package.json | 9 ++ packages/peer-exchange/package.json | 12 ++ packages/relay/package.json | 15 +++ packages/sdk/package.json | 17 ++- packages/utils/package.json | 8 ++ 11 files changed, 231 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index b584c38bfe..6ff994f8b4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -27796,11 +27796,19 @@ }, "peerDependencies": { "@multiformats/multiaddr": "^12.0.0", + "@waku/enr": "^0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/message-hash": "^0.1.11", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15", "libp2p": "^1.1.2" }, "peerDependenciesMeta": { "@multiformats/multiaddr": { "optional": true + }, + "@waku/interfaces": { + "optional": true } } }, @@ -27834,6 +27842,16 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@waku/enr": "0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } } }, "packages/enr": { @@ -27870,6 +27888,19 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@multiformats/multiaddr": "^12.0.0", + "@waku/interfaces": "0.0.22", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@multiformats/multiaddr": { + "optional": true + }, + "@waku/interfaces": { + "optional": true + } } }, "packages/interfaces": { @@ -27944,6 +27975,19 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@libp2p/interface": "^1.1.2", + "@waku/interfaces": "0.0.22", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@libp2p/interface": { + "optional": true + }, + "@waku/interfaces": { + "optional": true + } } }, "packages/local-peer-cache-discovery/node_modules/@cspell/cspell-bundled-dicts": { @@ -28418,6 +28462,17 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@waku/core": "0.0.27", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } } }, "packages/message-hash": { @@ -28449,6 +28504,15 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@waku/interfaces": "0.0.22", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } } }, "packages/peer-exchange": { @@ -28480,6 +28544,18 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@waku/core": "0.0.27", + "@waku/enr": "0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } } }, "packages/proto": { @@ -28528,6 +28604,21 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@chainsafe/libp2p-gossipsub": "^12.0.0", + "@waku/core": "0.0.27", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@chainsafe/libp2p-gossipsub": { + "optional": true + }, + "@waku/interfaces": { + "optional": true + } } }, "packages/sdk": { @@ -28565,7 +28656,22 @@ "node": ">=18" }, "peerDependencies": { - "@libp2p/bootstrap": "^10" + "@libp2p/bootstrap": "^10", + "@waku/core": "0.0.27", + "@waku/dns-discovery": "0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/local-peer-cache-discovery": "^1.0.0", + "@waku/peer-exchange": "^0.0.20", + "@waku/relay": "0.0.10", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@libp2p/bootstrap": { + "optional": true + }, + "@waku/interfaces": { + "optional": true + } } }, "packages/tests": { @@ -28640,6 +28746,14 @@ }, "engines": { "node": ">=18" + }, + "peerDependencies": { + "@waku/interfaces": "0.0.22" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } } } }, diff --git a/packages/core/package.json b/packages/core/package.json index 0f52b039de..a00fbd1103 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -109,11 +109,19 @@ }, "peerDependencies": { "@multiformats/multiaddr": "^12.0.0", - "libp2p": "^1.1.2" + "libp2p": "^1.1.2", + "@waku/enr": "^0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/message-hash": "^0.1.11", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" }, "peerDependenciesMeta": { "@multiformats/multiaddr": { "optional": true + }, + "@waku/interfaces": { + "optional": true } }, "files": [ diff --git a/packages/dns-discovery/package.json b/packages/dns-discovery/package.json index e0f7aee34f..c37b51d099 100644 --- a/packages/dns-discovery/package.json +++ b/packages/dns-discovery/package.json @@ -74,6 +74,16 @@ "npm-run-all": "^4.1.5", "rollup": "^4.12.0" }, + "peerDependencies": { + "@waku/enr": "0.0.21", + "@waku/utils": "0.0.15", + "@waku/interfaces": "0.0.22" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/enr/package.json b/packages/enr/package.json index 77fcf5ff8f..27607c9010 100644 --- a/packages/enr/package.json +++ b/packages/enr/package.json @@ -78,6 +78,19 @@ "rollup": "^4.12.0", "uint8arrays": "^5.0.1" }, + "peerDependencies": { + "@waku/utils": "0.0.15", + "@waku/interfaces": "0.0.22", + "@multiformats/multiaddr": "^12.0.0" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + }, + "@multiformats/multiaddr": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/local-peer-cache-discovery/package.json b/packages/local-peer-cache-discovery/package.json index 04d24052d5..cf0ceb0579 100644 --- a/packages/local-peer-cache-discovery/package.json +++ b/packages/local-peer-cache-discovery/package.json @@ -70,6 +70,19 @@ "rollup": "^4.12.0", "sinon": "^17.0.1" }, + "peerDependencies": { + "@libp2p/interface": "^1.1.2", + "@waku/utils": "0.0.15", + "@waku/interfaces": "0.0.22" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + }, + "@libp2p/interface": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/message-encryption/package.json b/packages/message-encryption/package.json index 6cc43e9b10..19763a83de 100644 --- a/packages/message-encryption/package.json +++ b/packages/message-encryption/package.json @@ -99,6 +99,17 @@ "process": "^0.11.10", "rollup": "^4.12.0" }, + "peerDependencies": { + "@waku/core": "0.0.27", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/message-hash/package.json b/packages/message-hash/package.json index fd420f6156..e70999dda1 100644 --- a/packages/message-hash/package.json +++ b/packages/message-hash/package.json @@ -72,6 +72,15 @@ "process": "^0.11.10", "rollup": "^4.12.0" }, + "peerDependencies": { + "@waku/interfaces": "0.0.22", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/peer-exchange/package.json b/packages/peer-exchange/package.json index 624cd23d14..3da4836bd2 100644 --- a/packages/peer-exchange/package.json +++ b/packages/peer-exchange/package.json @@ -70,6 +70,18 @@ "rollup": "^4.12.0", "uint8arraylist": "^2.4.3" }, + "peerDependencies": { + "@waku/core": "0.0.27", + "@waku/enr": "0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/relay/package.json b/packages/relay/package.json index 9576b053c6..a515a42e48 100644 --- a/packages/relay/package.json +++ b/packages/relay/package.json @@ -66,6 +66,21 @@ "@rollup/plugin-node-resolve": "^15.2.3", "rollup": "^4.12.0" }, + "peerDependencies": { + "@waku/core": "0.0.27", + "@waku/interfaces": "0.0.22", + "@waku/proto": "0.0.6", + "@waku/utils": "0.0.15", + "@chainsafe/libp2p-gossipsub": "^12.0.0" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + }, + "@chainsafe/libp2p-gossipsub": { + "optional": true + } + }, "files": [ "dist", "bundle", diff --git a/packages/sdk/package.json b/packages/sdk/package.json index 0387c2bc12..f32cf6e2a7 100644 --- a/packages/sdk/package.json +++ b/packages/sdk/package.json @@ -88,7 +88,22 @@ "rollup": "^4.12.0" }, "peerDependencies": { - "@libp2p/bootstrap": "^10" + "@libp2p/bootstrap": "^10", + "@waku/core": "0.0.27", + "@waku/dns-discovery": "0.0.21", + "@waku/interfaces": "0.0.22", + "@waku/local-peer-cache-discovery": "^1.0.0", + "@waku/peer-exchange": "^0.0.20", + "@waku/relay": "0.0.10", + "@waku/utils": "0.0.15" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + }, + "@libp2p/bootstrap": { + "optional": true + } }, "files": [ "dist", diff --git a/packages/utils/package.json b/packages/utils/package.json index 77341da5aa..f78eac92bd 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -83,6 +83,14 @@ "fast-check": "^3.15.1", "rollup": "^4.12.0" }, + "peerDependencies": { + "@waku/interfaces": "0.0.22" + }, + "peerDependenciesMeta": { + "@waku/interfaces": { + "optional": true + } + }, "files": [ "dist", "bundle",