@aztec/p2p 0.0.1-commit.08c5969dc → 0.0.1-commit.0c875d939
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -238,5 +238,5 @@ export declare const generateAccount: () => {
|
|
|
238
238
|
* @param header The checkpoint header (defaults to random with given slot)
|
|
239
239
|
* @returns A Checkpoint Attestation
|
|
240
240
|
*/
|
|
241
|
-
export declare const mockCheckpointAttestation: (signer: Secp256k1Signer, slot?: number, archive?: Fr, header?: CheckpointHeader | undefined) => CheckpointAttestation;
|
|
242
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
241
|
+
export declare const mockCheckpointAttestation: (signer: Secp256k1Signer, slot?: number, archive?: Fr, header?: CheckpointHeader | undefined, feeAssetPriceModifier?: bigint) => CheckpointAttestation;
|
|
242
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibW9ja3MuZC50cyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9tZW1fcG9vbHMvYXR0ZXN0YXRpb25fcG9vbC9tb2Nrcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFDQSxPQUFPLEtBQUssRUFBRSxlQUFlLEVBQUUsTUFBTSwyQ0FBMkMsQ0FBQztBQUNqRixPQUFPLEVBQUUsRUFBRSxFQUFFLE1BQU0sZ0NBQWdDLENBQUM7QUFDcEQsT0FBTyxFQUNMLHFCQUFxQixFQUl0QixNQUFNLG1CQUFtQixDQUFDO0FBQzNCLE9BQU8sRUFBRSxnQkFBZ0IsRUFBRSxNQUFNLHNCQUFzQixDQUFDO0FBSXhEOzs7O0dBSUc7QUFDSCxlQUFPLE1BQU0sZUFBZTs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7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e,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,EAAE,EAAE,MAAM,gCAAgC,CAAC;AACpD,OAAO,EACL,qBAAqB,EAItB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAIxD;;;;GAIG;AACH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAG3B,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,yBAAyB,wJAoBrC,CAAC"}
|
|
@@ -18,11 +18,11 @@ import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts';
|
|
|
18
18
|
* @param archive The archive root (defaults to random)
|
|
19
19
|
* @param header The checkpoint header (defaults to random with given slot)
|
|
20
20
|
* @returns A Checkpoint Attestation
|
|
21
|
-
*/ export const mockCheckpointAttestation = (signer, slot = 0, archive = Fr.random(), header)=>{
|
|
21
|
+
*/ export const mockCheckpointAttestation = (signer, slot = 0, archive = Fr.random(), header, feeAssetPriceModifier = 0n)=>{
|
|
22
22
|
header = header ?? CheckpointHeader.random({
|
|
23
23
|
slotNumber: SlotNumber(slot)
|
|
24
24
|
});
|
|
25
|
-
const payload = new ConsensusPayload(header, archive);
|
|
25
|
+
const payload = new ConsensusPayload(header, archive, feeAssetPriceModifier);
|
|
26
26
|
const attestationHash = getHashedSignaturePayloadEthSignedMessage(payload, SignatureDomainSeparator.checkpointAttestation);
|
|
27
27
|
const attestationSignature = signer.sign(attestationHash);
|
|
28
28
|
const proposalHash = getHashedSignaturePayloadEthSignedMessage(payload, SignatureDomainSeparator.checkpointProposal);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aztec/p2p",
|
|
3
|
-
"version": "0.0.1-commit.
|
|
3
|
+
"version": "0.0.1-commit.0c875d939",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": "./dest/index.js",
|
|
@@ -67,17 +67,17 @@
|
|
|
67
67
|
]
|
|
68
68
|
},
|
|
69
69
|
"dependencies": {
|
|
70
|
-
"@aztec/constants": "0.0.1-commit.
|
|
71
|
-
"@aztec/epoch-cache": "0.0.1-commit.
|
|
72
|
-
"@aztec/ethereum": "0.0.1-commit.
|
|
73
|
-
"@aztec/foundation": "0.0.1-commit.
|
|
74
|
-
"@aztec/kv-store": "0.0.1-commit.
|
|
75
|
-
"@aztec/noir-contracts.js": "0.0.1-commit.
|
|
76
|
-
"@aztec/noir-protocol-circuits-types": "0.0.1-commit.
|
|
77
|
-
"@aztec/protocol-contracts": "0.0.1-commit.
|
|
78
|
-
"@aztec/simulator": "0.0.1-commit.
|
|
79
|
-
"@aztec/stdlib": "0.0.1-commit.
|
|
80
|
-
"@aztec/telemetry-client": "0.0.1-commit.
|
|
70
|
+
"@aztec/constants": "0.0.1-commit.0c875d939",
|
|
71
|
+
"@aztec/epoch-cache": "0.0.1-commit.0c875d939",
|
|
72
|
+
"@aztec/ethereum": "0.0.1-commit.0c875d939",
|
|
73
|
+
"@aztec/foundation": "0.0.1-commit.0c875d939",
|
|
74
|
+
"@aztec/kv-store": "0.0.1-commit.0c875d939",
|
|
75
|
+
"@aztec/noir-contracts.js": "0.0.1-commit.0c875d939",
|
|
76
|
+
"@aztec/noir-protocol-circuits-types": "0.0.1-commit.0c875d939",
|
|
77
|
+
"@aztec/protocol-contracts": "0.0.1-commit.0c875d939",
|
|
78
|
+
"@aztec/simulator": "0.0.1-commit.0c875d939",
|
|
79
|
+
"@aztec/stdlib": "0.0.1-commit.0c875d939",
|
|
80
|
+
"@aztec/telemetry-client": "0.0.1-commit.0c875d939",
|
|
81
81
|
"@chainsafe/libp2p-gossipsub": "13.0.0",
|
|
82
82
|
"@chainsafe/libp2p-noise": "^15.0.0",
|
|
83
83
|
"@chainsafe/libp2p-yamux": "^6.0.2",
|
|
@@ -104,8 +104,8 @@
|
|
|
104
104
|
"xxhash-wasm": "^1.1.0"
|
|
105
105
|
},
|
|
106
106
|
"devDependencies": {
|
|
107
|
-
"@aztec/archiver": "0.0.1-commit.
|
|
108
|
-
"@aztec/world-state": "0.0.1-commit.
|
|
107
|
+
"@aztec/archiver": "0.0.1-commit.0c875d939",
|
|
108
|
+
"@aztec/world-state": "0.0.1-commit.0c875d939",
|
|
109
109
|
"@jest/globals": "^30.0.0",
|
|
110
110
|
"@types/jest": "^30.0.0",
|
|
111
111
|
"@types/node": "^22.15.17",
|
|
@@ -34,9 +34,10 @@ export const mockCheckpointAttestation = (
|
|
|
34
34
|
slot: number = 0,
|
|
35
35
|
archive: Fr = Fr.random(),
|
|
36
36
|
header?: CheckpointHeader,
|
|
37
|
+
feeAssetPriceModifier: bigint = 0n,
|
|
37
38
|
): CheckpointAttestation => {
|
|
38
39
|
header = header ?? CheckpointHeader.random({ slotNumber: SlotNumber(slot) });
|
|
39
|
-
const payload = new ConsensusPayload(header, archive);
|
|
40
|
+
const payload = new ConsensusPayload(header, archive, feeAssetPriceModifier);
|
|
40
41
|
|
|
41
42
|
const attestationHash = getHashedSignaturePayloadEthSignedMessage(
|
|
42
43
|
payload,
|