From a2fd02f1c950e22527f3f3be5a52f99b89163dcd Mon Sep 17 00:00:00 2001 From: Andrew Twyman Date: Mon, 9 Dec 2024 17:22:15 -0800 Subject: [PATCH 1/2] Update @zk-kit/lean-imt --- packages/lib/pod/package.json | 2 +- packages/lib/pod/test/podTypes.spec.ts | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/lib/pod/package.json b/packages/lib/pod/package.json index 7aab7b4f66..0ea6119750 100644 --- a/packages/lib/pod/package.json +++ b/packages/lib/pod/package.json @@ -40,7 +40,7 @@ "dependencies": { "@pcd/util": "0.9.0", "@zk-kit/eddsa-poseidon": "~1.0.4", - "@zk-kit/lean-imt": "^2.2.1", + "@zk-kit/lean-imt": "^2.2.2", "@zk-kit/utils": "^1.2.1", "js-sha256": "^0.10.1", "poseidon-lite": "^0.3.0" diff --git a/packages/lib/pod/test/podTypes.spec.ts b/packages/lib/pod/test/podTypes.spec.ts index dbad8de86b..6669b18d41 100644 --- a/packages/lib/pod/test/podTypes.spec.ts +++ b/packages/lib/pod/test/podTypes.spec.ts @@ -35,8 +35,10 @@ describe("POD type values should be correct", () => { }); it("POD_NULL_HASH should be nonzero", () => { - // We don't care what its value is, but some other libraries (e.g. LeanIMT) - // use 0 for special purposes, so we avoid it. + // We don't care what its value is, but some libraries or uses of Merkle + // trees may use 0 for special purposes (e.g. to indicate removal, or a + // missing value in an internal datastrcuture), so we avoid it to avoid + // ambiguity. expect(POD_NULL_HASH).to.not.eq(0n); }); }); From 5caaae0cf6c69dc207552a00e23ccae9284c3332 Mon Sep 17 00:00:00 2001 From: Andrew Twyman Date: Mon, 9 Dec 2024 17:28:42 -0800 Subject: [PATCH 2/2] yarn.lock --- yarn.lock | 52 +++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 47 insertions(+), 5 deletions(-) diff --git a/yarn.lock b/yarn.lock index 118411447a..fa5f50955c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6011,7 +6011,7 @@ "@ethersproject/keccak256" "^5.7.0" "@zk-kit/incremental-merkle-tree" "1.1.0" -"@semaphore-protocol/identity@4.5.0", "semaphore-identity-v4@npm:@semaphore-protocol/identity@^4.0.3": +"@semaphore-protocol/identity@4.5.0": version "4.5.0" resolved "https://registry.yarnpkg.com/@semaphore-protocol/identity/-/identity-4.5.0.tgz#d5c412eb609df2686b7216825ec88670ef73461b" integrity sha512-TIKxF2Lir1LppDQDJU6Z/aJUkocHT03BLpzv5vFEdCo/IT4g/4BhbFp2UQui7HyDE+JgMfUASXfScbFfo/5ULA== @@ -8448,13 +8448,20 @@ resolved "https://registry.yarnpkg.com/@zk-kit/incremental-merkle-tree/-/incremental-merkle-tree-1.1.0.tgz#6b0ccce56f9e05ccf73f7ea4fa746d5ef7d24b1d" integrity sha512-WnNR/GQse3lX8zOHMU8zwhgX8u3qPoul8w4GjJ0WDHq+VGJimo7EGheRZ/ILeBQabnlzAerdv3vBqYBehBeoKA== -"@zk-kit/lean-imt@2.2.1", "@zk-kit/lean-imt@^2.2.1": +"@zk-kit/lean-imt@2.2.1": version "2.2.1" resolved "https://registry.yarnpkg.com/@zk-kit/lean-imt/-/lean-imt-2.2.1.tgz#aa24ed3d281cff270013c3654fa1eec6f785ccef" integrity sha512-Zq5yunUYu+ztp9RR5nuqiG1GpK1wjUoAjC0+x/MB95sI/Ns7zCxpzxo/Om9E0gme74Y3jO9KM5UUh3f9tqU++w== dependencies: "@zk-kit/utils" "1.2.1" +"@zk-kit/lean-imt@^2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@zk-kit/lean-imt/-/lean-imt-2.2.2.tgz#79c8bd70fc0d444638328cb4781479b14c69a9dd" + integrity sha512-rscIPEgBBcu9vP/DJ3J+3187G/ObKETl343G5enPawNT81oeQSdHx3e2ZapTC+GfrZ/AS2AHHUOpRS1FfdSwjg== + dependencies: + "@zk-kit/utils" "1.2.1" + "@zk-kit/utils@1.2.1", "@zk-kit/utils@^1.2.1": version "1.2.1" resolved "https://registry.yarnpkg.com/@zk-kit/utils/-/utils-1.2.1.tgz#6cb38120535c73ab68cd0f09684882af148f256d" @@ -20064,6 +20071,16 @@ seek-bzip@^1.0.5: dependencies: commander "^2.8.1" +"semaphore-identity-v4@npm:@semaphore-protocol/identity@^4.0.3": + version "4.5.0" + resolved "https://registry.yarnpkg.com/@semaphore-protocol/identity/-/identity-4.5.0.tgz#d5c412eb609df2686b7216825ec88670ef73461b" + integrity sha512-TIKxF2Lir1LppDQDJU6Z/aJUkocHT03BLpzv5vFEdCo/IT4g/4BhbFp2UQui7HyDE+JgMfUASXfScbFfo/5ULA== + dependencies: + "@zk-kit/baby-jubjub" "1.0.3" + "@zk-kit/eddsa-poseidon" "1.0.4" + "@zk-kit/utils" "1.2.1" + poseidon-lite "0.3.0" + semver-match@0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/semver-match/-/semver-match-0.1.1.tgz#e7ccb31f83fd4a0e377d66387afd8ca3a329b5fc" @@ -20809,7 +20826,16 @@ string-template@~0.2.1: resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha512-Yptehjogou2xm4UJbxJ4CxgZx12HBfeystp0y3x7s4Dj32ltVVG1Gg8YhKjHZkHicuKpZX/ffilA8505VbUbpw== -"string-width-cjs@npm:string-width@^4.2.0", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0": + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -20942,7 +20968,14 @@ stringify-entities@^4.0.0: character-entities-html4 "^2.0.0" character-entities-legacy "^3.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: +"strip-ansi-cjs@npm:strip-ansi@^6.0.1": + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -23457,7 +23490,7 @@ workspace-tools@^0.36.4: js-yaml "^4.1.0" micromatch "^4.0.0" -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -23475,6 +23508,15 @@ wrap-ansi@^6.0.1, wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214"