@aztec/txe 3.0.0-devnet.5 → 3.0.0-devnet.6-patch.1

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.
Files changed (67) hide show
  1. package/dest/bin/index.d.ts +1 -1
  2. package/dest/index.d.ts +1 -1
  3. package/dest/oracle/interfaces.d.ts +6 -5
  4. package/dest/oracle/interfaces.d.ts.map +1 -1
  5. package/dest/oracle/txe_oracle_public_context.d.ts +4 -4
  6. package/dest/oracle/txe_oracle_public_context.d.ts.map +1 -1
  7. package/dest/oracle/txe_oracle_public_context.js +1 -1
  8. package/dest/oracle/txe_oracle_top_level_context.d.ts +4 -3
  9. package/dest/oracle/txe_oracle_top_level_context.d.ts.map +1 -1
  10. package/dest/oracle/txe_oracle_top_level_context.js +31 -22
  11. package/dest/rpc_translator.d.ts +10 -7
  12. package/dest/rpc_translator.d.ts.map +1 -1
  13. package/dest/rpc_translator.js +36 -17
  14. package/dest/state_machine/archiver.d.ts +14 -9
  15. package/dest/state_machine/archiver.d.ts.map +1 -1
  16. package/dest/state_machine/archiver.js +14 -4
  17. package/dest/state_machine/dummy_p2p_client.d.ts +4 -2
  18. package/dest/state_machine/dummy_p2p_client.d.ts.map +1 -1
  19. package/dest/state_machine/dummy_p2p_client.js +3 -0
  20. package/dest/state_machine/global_variable_builder.d.ts +3 -2
  21. package/dest/state_machine/global_variable_builder.d.ts.map +1 -1
  22. package/dest/state_machine/index.d.ts +1 -1
  23. package/dest/state_machine/index.d.ts.map +1 -1
  24. package/dest/state_machine/index.js +1 -1
  25. package/dest/state_machine/mock_epoch_cache.d.ts +6 -5
  26. package/dest/state_machine/mock_epoch_cache.d.ts.map +1 -1
  27. package/dest/state_machine/mock_epoch_cache.js +8 -7
  28. package/dest/state_machine/synchronizer.d.ts +5 -4
  29. package/dest/state_machine/synchronizer.d.ts.map +1 -1
  30. package/dest/state_machine/synchronizer.js +5 -4
  31. package/dest/txe_session.d.ts +5 -5
  32. package/dest/txe_session.d.ts.map +1 -1
  33. package/dest/txe_session.js +9 -6
  34. package/dest/util/encoding.d.ts +24 -24
  35. package/dest/util/encoding.d.ts.map +1 -1
  36. package/dest/util/encoding.js +1 -1
  37. package/dest/util/expected_failure_error.d.ts +1 -1
  38. package/dest/util/expected_failure_error.d.ts.map +1 -1
  39. package/dest/util/txe_account_data_provider.d.ts +1 -1
  40. package/dest/util/txe_account_data_provider.d.ts.map +1 -1
  41. package/dest/util/txe_contract_data_provider.d.ts +1 -1
  42. package/dest/util/txe_contract_data_provider.d.ts.map +1 -1
  43. package/dest/util/txe_public_contract_data_source.d.ts +5 -4
  44. package/dest/util/txe_public_contract_data_source.d.ts.map +1 -1
  45. package/dest/util/txe_public_contract_data_source.js +1 -1
  46. package/dest/utils/block_creation.d.ts +4 -3
  47. package/dest/utils/block_creation.d.ts.map +1 -1
  48. package/dest/utils/block_creation.js +2 -2
  49. package/dest/utils/tx_effect_creation.d.ts +4 -3
  50. package/dest/utils/tx_effect_creation.d.ts.map +1 -1
  51. package/dest/utils/tx_effect_creation.js +6 -6
  52. package/package.json +18 -17
  53. package/src/oracle/interfaces.ts +5 -4
  54. package/src/oracle/txe_oracle_public_context.ts +3 -3
  55. package/src/oracle/txe_oracle_top_level_context.ts +32 -23
  56. package/src/rpc_translator.ts +46 -18
  57. package/src/state_machine/archiver.ts +25 -11
  58. package/src/state_machine/dummy_p2p_client.ts +6 -1
  59. package/src/state_machine/global_variable_builder.ts +3 -2
  60. package/src/state_machine/index.ts +1 -1
  61. package/src/state_machine/mock_epoch_cache.ts +12 -11
  62. package/src/state_machine/synchronizer.ts +8 -7
  63. package/src/txe_session.ts +12 -10
  64. package/src/util/encoding.ts +1 -1
  65. package/src/util/txe_public_contract_data_source.ts +4 -3
  66. package/src/utils/block_creation.ts +4 -2
  67. package/src/utils/tx_effect_creation.ts +8 -7
@@ -1 +1 @@
1
- {"version":3,"file":"encoding.d.ts","sourceRoot":"","sources":["../../src/util/encoding.ts"],"names":[],"m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,EAAE,EAC/B,MAAM,EAAE,MAAM,EACd,iBAAiB,EAAE,MAAM,GACxB,CAAC,gBAAgB,EAAE,iBAAiB,CAAC,CAqBvC;AAED,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,CAAC,iBAAiB,GAAG,gBAAgB,CAAC,EAAE;;EAEhF;AAED,eAAO,MAAM,uBAAuB,aAAa,CAAC;AAElD,eAAO,MAAM,sBAAsB,iCAAsB,CAAC;AAE1D,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAEjC,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;;;;EAElC,CAAC"}
@@ -1,4 +1,4 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
2
  import { hexToBuffer } from '@aztec/foundation/string';
3
3
  import { ContractArtifactSchema } from '@aztec/stdlib/abi';
4
4
  import { AztecAddress } from '@aztec/stdlib/aztec-address';
@@ -1,4 +1,4 @@
1
1
  export declare class ExpectedFailureError extends Error {
2
2
  constructor(message: string);
3
3
  }
4
- //# sourceMappingURL=expected_failure_error.d.ts.map
4
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXhwZWN0ZWRfZmFpbHVyZV9lcnJvci5kLnRzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL3V0aWwvZXhwZWN0ZWRfZmFpbHVyZV9lcnJvci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxxQkFBYSxvQkFBcUIsU0FBUSxLQUFLO0lBQzdDLFlBQVksT0FBTyxFQUFFLE1BQU0sRUFFMUI7Q0FDRiJ9
@@ -1 +1 @@
1
- {"version":3,"file":"expected_failure_error.d.ts","sourceRoot":"","sources":["../../src/util/expected_failure_error.ts"],"names":[],"mappings":"AAAA,qBAAa,oBAAqB,SAAQ,KAAK;gBACjC,OAAO,EAAE,MAAM;CAG5B"}
1
+ {"version":3,"file":"expected_failure_error.d.ts","sourceRoot":"","sources":["../../src/util/expected_failure_error.ts"],"names":[],"mappings":"AAAA,qBAAa,oBAAqB,SAAQ,KAAK;IAC7C,YAAY,OAAO,EAAE,MAAM,EAE1B;CACF"}
@@ -7,4 +7,4 @@ export declare class TXEAccountDataProvider {
7
7
  getAccount(key: AztecAddress): Promise<CompleteAddress>;
8
8
  setAccount(key: AztecAddress, value: CompleteAddress): Promise<void>;
9
9
  }
10
- //# sourceMappingURL=txe_account_data_provider.d.ts.map
10
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHhlX2FjY291bnRfZGF0YV9wcm92aWRlci5kLnRzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL3V0aWwvdHhlX2FjY291bnRfZGF0YV9wcm92aWRlci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEtBQUssRUFBRSxpQkFBaUIsRUFBaUIsTUFBTSxpQkFBaUIsQ0FBQztBQUN4RSxPQUFPLEtBQUssRUFBRSxZQUFZLEVBQUUsTUFBTSw2QkFBNkIsQ0FBQztBQUNoRSxPQUFPLEVBQUUsZUFBZSxFQUFFLE1BQU0sd0JBQXdCLENBQUM7QUFFekQscUJBQWEsc0JBQXNCOztJQUdqQyxZQUFZLEtBQUssRUFBRSxpQkFBaUIsRUFFbkM7SUFFSyxVQUFVLENBQUMsR0FBRyxFQUFFLFlBQVksNEJBTWpDO0lBRUssVUFBVSxDQUFDLEdBQUcsRUFBRSxZQUFZLEVBQUUsS0FBSyxFQUFFLGVBQWUsaUJBRXpEO0NBQ0YifQ==
@@ -1 +1 @@
1
- {"version":3,"file":"txe_account_data_provider.d.ts","sourceRoot":"","sources":["../../src/util/txe_account_data_provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAiB,MAAM,iBAAiB,CAAC;AACxE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,qBAAa,sBAAsB;;gBAGrB,KAAK,EAAE,iBAAiB;IAI9B,UAAU,CAAC,GAAG,EAAE,YAAY;IAQ5B,UAAU,CAAC,GAAG,EAAE,YAAY,EAAE,KAAK,EAAE,eAAe;CAG3D"}
1
+ {"version":3,"file":"txe_account_data_provider.d.ts","sourceRoot":"","sources":["../../src/util/txe_account_data_provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAiB,MAAM,iBAAiB,CAAC;AACxE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAEzD,qBAAa,sBAAsB;;IAGjC,YAAY,KAAK,EAAE,iBAAiB,EAEnC;IAEK,UAAU,CAAC,GAAG,EAAE,YAAY,4BAMjC;IAEK,UAAU,CAAC,GAAG,EAAE,YAAY,EAAE,KAAK,EAAE,eAAe,iBAEzD;CACF"}
@@ -9,4 +9,4 @@ export declare class TXEContractDataProvider extends ContractDataProvider {
9
9
  addContractArtifact(id: Fr, artifact: ContractArtifact | ContractArtifactWithHash): Promise<void>;
10
10
  getContractArtifact(contractClassId: Fr): Promise<ContractArtifact | ContractArtifactWithHash | undefined>;
11
11
  }
12
- //# sourceMappingURL=txe_contract_data_provider.d.ts.map
12
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHhlX2NvbnRyYWN0X2RhdGFfcHJvdmlkZXIuZC50cyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy91dGlsL3R4ZV9jb250cmFjdF9kYXRhX3Byb3ZpZGVyLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sS0FB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OAAO,CAAC,gBAAgB,GAAG,wBAAwB,GAAG,SAAS,CAAC;CASpE"}
1
+ {"version":3,"file":"txe_contract_data_provider.d.ts","sourceRoot":"","sources":["../../src/util/txe_contract_data_provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,EAAE,EAAE,MAAM,wBAAwB,CAAC;AAC5C,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAEzD,MAAM,MAAM,wBAAwB,GAAG,gBAAgB,GAAG;IAAE,YAAY,EAAE,EAAE,CAAA;CAAE,CAAC;AAO/E,qBAAa,uBAAwB,SAAQ,oBAAoB;;IAGzC,mBAAmB,CACvC,EAAE,EAAE,EAAE,EACN,QAAQ,EAAE,gBAAgB,GAAG,wBAAwB,GACpD,OAAO,CAAC,IAAI,CAAC,CAKf;IAEqB,mBAAmB,CACvC,eAAe,EAAE,EAAE,GAClB,OAAO,CAAC,gBAAgB,GAAG,wBAAwB,GAAG,SAAS,CAAC,CAQlE;CACF"}
@@ -1,4 +1,5 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { BlockNumber } from '@aztec/foundation/branded-types';
2
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
3
  import type { ContractDataProvider } from '@aztec/pxe/server';
3
4
  import { type ContractArtifact, FunctionSelector } from '@aztec/stdlib/abi';
4
5
  import type { AztecAddress } from '@aztec/stdlib/aztec-address';
@@ -7,8 +8,8 @@ export declare class TXEPublicContractDataSource implements ContractDataSource {
7
8
  #private;
8
9
  private blockNumber;
9
10
  private contractDataProvider;
10
- constructor(blockNumber: number, contractDataProvider: ContractDataProvider);
11
- getBlockNumber(): Promise<number>;
11
+ constructor(blockNumber: BlockNumber, contractDataProvider: ContractDataProvider);
12
+ getBlockNumber(): Promise<BlockNumber>;
12
13
  getContractClass(id: Fr): Promise<ContractClassPublic | undefined>;
13
14
  getBytecodeCommitment(id: Fr): Promise<Fr | undefined>;
14
15
  getContract(address: AztecAddress): Promise<ContractInstanceWithAddress | undefined>;
@@ -17,4 +18,4 @@ export declare class TXEPublicContractDataSource implements ContractDataSource {
17
18
  getDebugFunctionName(address: AztecAddress, selector: FunctionSelector): Promise<string | undefined>;
18
19
  registerContractFunctionSignatures(_signatures: []): Promise<void>;
19
20
  }
20
- //# sourceMappingURL=txe_public_contract_data_source.d.ts.map
21
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHhlX3B1YmxpY19jb250cmFjdF9kYXRhX3NvdXJjZS5kLnRzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL3V0aWwvdHhlX3B1YmxpY19jb250cmFjdF9kYXRhX3NvdXJjZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsV0FBVyxFQUFFLE1BQU0saUNBQWlDLENBQUM7QUFDOUQsT0FBTyxFQUFFLEVBQUUsRUFBRSxNQUFNLGdDQUFnQyxDQUFDO0FBQ3BELE9BQU8sS0FBSyxFQUFFLG9CQUFvQixFQUFFLE1BQU0sbUJBQW1CLENBQUM7QUFDOUQsT0FBTyxFQUFFLEtBQUssZ0JBQWdCLEVBQUUsZ0JBQWdCLEVBQWdCLE1BQU0sbUJBQW1CLENBQUM7QUFDMUYsT0FBTyxLQUFLLEVBQUUsWUFBWSxFQUFFLE1BQU0sNkJBQTZCLENBQUM7QUFDaEUsT0FBTyxFQUNMLEtBQUssbUJBQW1CLEVBQ3hCLEtBQUssa0JBQWtCLEVBQ3ZCLEtBQUssMkJBQTJCLEVBSWpDLE1BQU0sd0JBQXdCLENBQUM7QUFFaEMscUJBQWEsMkJBQTRCLFlBQVcsa0JBQWtCOztJQUdsRSxPQUFPLENBQUMsV0FBVztJQUNuQixPQUFPLENBQUMsb0JBQW9CO0lBRjlCLFlBQ1UsV0FBVyxFQUFFLFdBQVcsRUFDeEIsb0J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;AAC1F,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,2BAA2B,EAIjC,MAAM,wBAAwB,CAAC;AAEhC,qBAAa,2BAA4B,YAAW,kBAAkB;;IAGlE,OAAO,CAAC,WAAW;IACnB,OAAO,CAAC,oBAAoB;IAF9B,YACU,WAAW,EAAE,WAAW,EACxB,oBAAoB,EAAE,oBAAoB,EAChD;IAEJ,cAAc,IAAI,OAAO,CAAC,WAAW,CAAC,CAErC;IAEK,gBAAgB,CAAC,EAAE,EAAE,EAAE,GAAG,OAAO,CAAC,mBAAmB,GAAG,SAAS,CAAC,CAgCvE;IAEK,qBAAqB,CAAC,EAAE,EAAE,EAAE,GAAG,OAAO,CAAC,EAAE,GAAG,SAAS,CAAC,CAG3D;IAEK,WAAW,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,2BAA2B,GAAG,SAAS,CAAC,CAGzF;IAED,mBAAmB,IAAI,OAAO,CAAC,EAAE,EAAE,CAAC,CAEnC;IAEK,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,gBAAgB,GAAG,SAAS,CAAC,CAGtF;IAEK,oBAAoB,CAAC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAEzG;IAED,kCAAkC,CAAC,WAAW,EAAE,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAEjE;CACF"}
@@ -1,4 +1,4 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
2
  import { FunctionType } from '@aztec/stdlib/abi';
3
3
  import { computePrivateFunctionsRoot, computePublicBytecodeCommitment, getContractClassPrivateFunctionFromArtifact } from '@aztec/stdlib/contract';
4
4
  export class TXEPublicContractDataSource {
@@ -1,4 +1,5 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { BlockNumber } from '@aztec/foundation/branded-types';
2
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
3
  import { L2BlockHeader } from '@aztec/stdlib/block';
3
4
  import { type MerkleTreeWriteOperations } from '@aztec/stdlib/trees';
4
5
  import { GlobalVariables, TxEffect } from '@aztec/stdlib/tx';
@@ -7,7 +8,7 @@ import { GlobalVariables, TxEffect } from '@aztec/stdlib/tx';
7
8
  * @param blockNumber The number for the block in which there is a single transaction.
8
9
  * @returns The transaction request hash.
9
10
  */
10
- export declare function getSingleTxBlockRequestHash(blockNumber: number): Fr;
11
+ export declare function getSingleTxBlockRequestHash(blockNumber: BlockNumber): Fr;
11
12
  export declare function insertTxEffectIntoWorldTrees(txEffect: TxEffect, worldTrees: MerkleTreeWriteOperations): Promise<void>;
12
13
  export declare function makeTXEBlockHeader(worldTrees: MerkleTreeWriteOperations, globalVariables: GlobalVariables): Promise<L2BlockHeader>;
13
- //# sourceMappingURL=block_creation.d.ts.map
14
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmxvY2tfY3JlYXRpb24uZC50cyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy91dGlscy9ibG9ja19jcmVhdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFNQSxPQUFPLEVBQUUsV0FBVyxFQUFFLE1BQU0saUNBQWlDLENBQUM7QUFFOUQsT0FBTyxFQUFFLEVBQUUsRUFBRSxNQUFNLGdDQUFnQyxDQUFDO0FBQ3BELE9BQU8sRUFBRSxhQUFhLEVBQUUsTUFBTSxxQkFBcUIsQ0FBQztBQUVwRCxPQUFPLEVBQXdDLEtBQUsseUJBQXlCLEVBQUUsTUFBTSxxQkFBcUIsQ0FBQztBQUMzRyxPQUFPLEVBQUUsZUFBZSxFQUFFLFFBQVEsRUFBRSxNQUFNLGtCQUFrQixDQUFDO0FBRTdEOzs7O0dBSUc7QUFDSCx3QkFBZ0IsMkJBQTJCLENBQUMsV0FBVyxFQUFFLFdBQVcsR0FBRyxFQUFFLENBRXhFO0FBRUQsd0JBQXNCLDRCQUE0QixDQUNoRCxRQUFRLEVBQUUsUUFBUSxFQUNsQixVQUFVLEVBQUUseUJBQXlCLEdBQ3BDLE9BQU8sQ0FBQyxJQUFJLENBQUMsQ0FrQmY7QUFFRCx3QkFBc0Isa0JBQWtCLENBQ3RDLFVBQVUsRUFBRSx5QkFBeUIsRUFDckMsZUFBZSxFQUFFLGVBQWUsR0FDL0IsT0FBTyxDQUFDLGFBQWEsQ0FBQyxDQWN4QiJ9
@@ -1 +1 @@
1
- {"version":3,"file":"block_creation.d.ts","sourceRoot":"","sources":["../../src/utils/block_creation.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,EAAE,EAAE,MAAM,0BAA0B,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,OAAO,EAAwC,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAC3G,OAAO,EAAE,eAAe,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE7D;;;;GAIG;AACH,wBAAgB,2BAA2B,CAAC,WAAW,EAAE,MAAM,GAAG,EAAE,CAEnE;AAED,wBAAsB,4BAA4B,CAChD,QAAQ,EAAE,QAAQ,EAClB,UAAU,EAAE,yBAAyB,GACpC,OAAO,CAAC,IAAI,CAAC,CAkBf;AAED,wBAAsB,kBAAkB,CACtC,UAAU,EAAE,yBAAyB,EACrC,eAAe,EAAE,eAAe,GAC/B,OAAO,CAAC,aAAa,CAAC,CAaxB"}
1
+ {"version":3,"file":"block_creation.d.ts","sourceRoot":"","sources":["../../src/utils/block_creation.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAE9D,OAAO,EAAE,EAAE,EAAE,MAAM,gCAAgC,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,OAAO,EAAwC,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAC3G,OAAO,EAAE,eAAe,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE7D;;;;GAIG;AACH,wBAAgB,2BAA2B,CAAC,WAAW,EAAE,WAAW,GAAG,EAAE,CAExE;AAED,wBAAsB,4BAA4B,CAChD,QAAQ,EAAE,QAAQ,EAClB,UAAU,EAAE,yBAAyB,GACpC,OAAO,CAAC,IAAI,CAAC,CAkBf;AAED,wBAAsB,kBAAkB,CACtC,UAAU,EAAE,yBAAyB,EACrC,eAAe,EAAE,eAAe,GAC/B,OAAO,CAAC,aAAa,CAAC,CAcxB"}
@@ -1,6 +1,6 @@
1
1
  import { MAX_NOTE_HASHES_PER_TX, MAX_NULLIFIERS_PER_TX, NULLIFIER_SUBTREE_HEIGHT, NUMBER_OF_L1_L2_MESSAGES_PER_ROLLUP } from '@aztec/constants';
2
2
  import { padArrayEnd } from '@aztec/foundation/collection';
3
- import { Fr } from '@aztec/foundation/fields';
3
+ import { Fr } from '@aztec/foundation/curves/bn254';
4
4
  import { L2BlockHeader } from '@aztec/stdlib/block';
5
5
  import { makeContentCommitment } from '@aztec/stdlib/testing';
6
6
  import { AppendOnlyTreeSnapshot, MerkleTreeId } from '@aztec/stdlib/trees';
@@ -20,5 +20,5 @@ export async function insertTxEffectIntoWorldTrees(txEffect, worldTrees) {
20
20
  export async function makeTXEBlockHeader(worldTrees, globalVariables) {
21
21
  const stateReference = await worldTrees.getStateReference();
22
22
  const archiveInfo = await worldTrees.getTreeInfo(MerkleTreeId.ARCHIVE);
23
- return new L2BlockHeader(new AppendOnlyTreeSnapshot(new Fr(archiveInfo.root), Number(archiveInfo.size)), makeContentCommitment(), stateReference, globalVariables, Fr.ZERO, Fr.ZERO, Fr.ZERO);
23
+ return new L2BlockHeader(new AppendOnlyTreeSnapshot(new Fr(archiveInfo.root), Number(archiveInfo.size)), makeContentCommitment(), stateReference, globalVariables, Fr.ZERO, Fr.ZERO, Fr.ZERO, Fr.ZERO);
24
24
  }
@@ -1,5 +1,6 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { BlockNumber } from '@aztec/foundation/branded-types';
2
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
3
  import type { ExecutionNoteCache } from '@aztec/pxe/simulator';
3
4
  import { TxEffect } from '@aztec/stdlib/tx';
4
- export declare function makeTxEffect(noteCache: ExecutionNoteCache, txRequestHash: Fr, txBlockNumber: number): Promise<TxEffect>;
5
- //# sourceMappingURL=tx_effect_creation.d.ts.map
5
+ export declare function makeTxEffect(noteCache: ExecutionNoteCache, protocolNullifier: Fr, txBlockNumber: BlockNumber): Promise<TxEffect>;
6
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHhfZWZmZWN0X2NyZWF0aW9uLmQudHMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXRpbHMvdHhfZWZmZWN0X2NyZWF0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxXQUFXLEVBQUUsTUFBTSxpQ0FBaUMsQ0FBQztBQUM5RCxPQUFPLEVBQUUsRUFBRSxFQUFFLE1BQU0sZ0NBQWdDLENBQUM7QUFDcEQsT0FBTyxLQUFLLEVBQUUsa0JBQWtCLEVBQUUsTUFBTSxzQkFBc0IsQ0FBQztBQUUvRCxPQUFPLEVBQUUsUUFBUSxFQUFVLE1BQU0sa0JBQWtCLENBQUM7QUFFcEQsd0JBQXNCLFlBQVksQ0FDaEMsU0FBUyxFQUFFLGtCQUFrQixFQUM3QixpQkFBaUIsRUFBRSxFQUFFLEVBQ3JCLGFBQWEsRUFBRSxXQUFXLEdBQ3pCLE9BQU8sQ0FBQyxRQUFRLENBQUMsQ0EyQm5CIn0=
@@ -1 +1 @@
1
- {"version":3,"file":"tx_effect_creation.d.ts","sourceRoot":"","sources":["../../src/utils/tx_effect_creation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,0BAA0B,CAAC;AAC9C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,OAAO,EAAE,QAAQ,EAAU,MAAM,kBAAkB,CAAC;AAEpD,wBAAsB,YAAY,CAChC,SAAS,EAAE,kBAAkB,EAC7B,aAAa,EAAE,EAAE,EACjB,aAAa,EAAE,MAAM,GACpB,OAAO,CAAC,QAAQ,CAAC,CA2BnB"}
1
+ {"version":3,"file":"tx_effect_creation.d.ts","sourceRoot":"","sources":["../../src/utils/tx_effect_creation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAC9D,OAAO,EAAE,EAAE,EAAE,MAAM,gCAAgC,CAAC;AACpD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,OAAO,EAAE,QAAQ,EAAU,MAAM,kBAAkB,CAAC;AAEpD,wBAAsB,YAAY,CAChC,SAAS,EAAE,kBAAkB,EAC7B,iBAAiB,EAAE,EAAE,EACrB,aAAa,EAAE,WAAW,GACzB,OAAO,CAAC,QAAQ,CAAC,CA2BnB"}
@@ -1,15 +1,15 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
2
  import { computeNoteHashNonce, computeUniqueNoteHash, siloNoteHash } from '@aztec/stdlib/hash';
3
3
  import { TxEffect, TxHash } from '@aztec/stdlib/tx';
4
- export async function makeTxEffect(noteCache, txRequestHash, txBlockNumber) {
4
+ export async function makeTxEffect(noteCache, protocolNullifier, txBlockNumber) {
5
5
  const txEffect = TxEffect.empty();
6
- const { usedTxRequestHashForNonces } = noteCache.finish();
7
- const nonceGenerator = usedTxRequestHashForNonces ? txRequestHash : noteCache.getAllNullifiers()[0];
6
+ const { usedProtocolNullifierForNonces } = noteCache.finish();
7
+ const nonceGenerator = usedProtocolNullifierForNonces ? protocolNullifier : noteCache.getAllNullifiers()[0];
8
8
  txEffect.noteHashes = await Promise.all(noteCache.getAllNotes().map(async (pendingNote, i)=>computeUniqueNoteHash(await computeNoteHashNonce(nonceGenerator, i), await siloNoteHash(pendingNote.note.contractAddress, pendingNote.noteHashForConsumption))));
9
9
  // Nullifiers are already siloed
10
10
  txEffect.nullifiers = noteCache.getAllNullifiers();
11
- if (usedTxRequestHashForNonces) {
12
- txEffect.nullifiers.unshift(txRequestHash);
11
+ if (usedProtocolNullifierForNonces) {
12
+ txEffect.nullifiers.unshift(protocolNullifier);
13
13
  }
14
14
  txEffect.txHash = new TxHash(new Fr(txBlockNumber));
15
15
  return txEffect;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aztec/txe",
3
- "version": "3.0.0-devnet.5",
3
+ "version": "3.0.0-devnet.6-patch.1",
4
4
  "type": "module",
5
5
  "exports": "./dest/index.js",
6
6
  "bin": "./dest/bin/index.js",
@@ -12,8 +12,8 @@
12
12
  "tsconfig": "./tsconfig.json"
13
13
  },
14
14
  "scripts": {
15
- "build": "yarn clean && tsc -b",
16
- "build:dev": "tsc -b --watch",
15
+ "build": "yarn clean && ../scripts/tsc.sh",
16
+ "build:dev": "../scripts/tsc.sh --watch",
17
17
  "clean": "rm -rf ./dest .tsbuildinfo",
18
18
  "test": "NODE_NO_WARNINGS=1 node --experimental-vm-modules ../node_modules/.bin/jest --passWithNoTests --maxWorkers=${JEST_MAX_WORKERS:-8}",
19
19
  "dev": "LOG_LEVEL=\"debug; trace: simulator:state_manager; info: json-rpc:proxy\" node ./dest/bin/index.js",
@@ -61,26 +61,27 @@
61
61
  ]
62
62
  },
63
63
  "dependencies": {
64
- "@aztec/accounts": "3.0.0-devnet.5",
65
- "@aztec/archiver": "3.0.0-devnet.5",
66
- "@aztec/aztec-node": "3.0.0-devnet.5",
67
- "@aztec/aztec.js": "3.0.0-devnet.5",
68
- "@aztec/bb-prover": "3.0.0-devnet.5",
69
- "@aztec/constants": "3.0.0-devnet.5",
70
- "@aztec/foundation": "3.0.0-devnet.5",
71
- "@aztec/key-store": "3.0.0-devnet.5",
72
- "@aztec/kv-store": "3.0.0-devnet.5",
73
- "@aztec/protocol-contracts": "3.0.0-devnet.5",
74
- "@aztec/pxe": "3.0.0-devnet.5",
75
- "@aztec/simulator": "3.0.0-devnet.5",
76
- "@aztec/stdlib": "3.0.0-devnet.5",
77
- "@aztec/world-state": "3.0.0-devnet.5",
64
+ "@aztec/accounts": "3.0.0-devnet.6-patch.1",
65
+ "@aztec/archiver": "3.0.0-devnet.6-patch.1",
66
+ "@aztec/aztec-node": "3.0.0-devnet.6-patch.1",
67
+ "@aztec/aztec.js": "3.0.0-devnet.6-patch.1",
68
+ "@aztec/bb-prover": "3.0.0-devnet.6-patch.1",
69
+ "@aztec/constants": "3.0.0-devnet.6-patch.1",
70
+ "@aztec/foundation": "3.0.0-devnet.6-patch.1",
71
+ "@aztec/key-store": "3.0.0-devnet.6-patch.1",
72
+ "@aztec/kv-store": "3.0.0-devnet.6-patch.1",
73
+ "@aztec/protocol-contracts": "3.0.0-devnet.6-patch.1",
74
+ "@aztec/pxe": "3.0.0-devnet.6-patch.1",
75
+ "@aztec/simulator": "3.0.0-devnet.6-patch.1",
76
+ "@aztec/stdlib": "3.0.0-devnet.6-patch.1",
77
+ "@aztec/world-state": "3.0.0-devnet.6-patch.1",
78
78
  "zod": "^3.23.8"
79
79
  },
80
80
  "devDependencies": {
81
81
  "@jest/globals": "^30.0.0",
82
82
  "@types/jest": "^30.0.0",
83
83
  "@types/node": "^22.15.17",
84
+ "@typescript/native-preview": "7.0.0-dev.20251126.1",
84
85
  "jest": "^30.0.0",
85
86
  "jest-mock-extended": "^4.0.0",
86
87
  "ts-node": "^10.9.1",
@@ -2,10 +2,11 @@ import type { ContractArtifact } from '@aztec/aztec.js/abi';
2
2
  import { CompleteAddress } from '@aztec/aztec.js/addresses';
3
3
  import type { ContractInstanceWithAddress } from '@aztec/aztec.js/contracts';
4
4
  import { TxHash } from '@aztec/aztec.js/tx';
5
- import type { Fr } from '@aztec/foundation/fields';
5
+ import { BlockNumber } from '@aztec/foundation/branded-types';
6
+ import type { Fr } from '@aztec/foundation/curves/bn254';
6
7
  import type { FunctionSelector } from '@aztec/stdlib/abi';
7
8
  import type { AztecAddress } from '@aztec/stdlib/aztec-address';
8
- import type { UInt32, UInt64 } from '@aztec/stdlib/types';
9
+ import type { UInt64 } from '@aztec/stdlib/types';
9
10
 
10
11
  // These interfaces complement the ones defined in PXE, and combined with those contain the full list of oracles used by
11
12
  // aztec-nr. In particular, these include the ones needed to run Brillig code associated to #[external("public")] functions that has
@@ -25,7 +26,7 @@ export interface IAvmExecutionOracle {
25
26
 
26
27
  avmOpcodeAddress(): Promise<AztecAddress>;
27
28
  avmOpcodeSender(): Promise<AztecAddress>;
28
- avmOpcodeBlockNumber(): Promise<UInt32>;
29
+ avmOpcodeBlockNumber(): Promise<BlockNumber>;
29
30
  avmOpcodeTimestamp(): Promise<bigint>;
30
31
  avmOpcodeIsStaticCall(): Promise<boolean>;
31
32
  avmOpcodeChainId(): Promise<Fr>;
@@ -43,7 +44,7 @@ export interface IAvmExecutionOracle {
43
44
  export interface ITxeExecutionOracle {
44
45
  isTxe: true;
45
46
 
46
- txeGetNextBlockNumber(): Promise<number>;
47
+ txeGetNextBlockNumber(): Promise<BlockNumber>;
47
48
  txeGetNextBlockTimestamp(): Promise<UInt64>;
48
49
  txeAdvanceBlocksBy(blocks: number): Promise<void>;
49
50
  txeAdvanceTimestampBy(duration: UInt64): void;
@@ -1,4 +1,5 @@
1
- import { Fr } from '@aztec/foundation/fields';
1
+ import { BlockNumber } from '@aztec/foundation/branded-types';
2
+ import { Fr } from '@aztec/foundation/curves/bn254';
2
3
  import { type Logger, createLogger } from '@aztec/foundation/log';
3
4
  import { PublicDataWrite } from '@aztec/stdlib/avm';
4
5
  import { AztecAddress } from '@aztec/stdlib/aztec-address';
@@ -12,7 +13,6 @@ import {
12
13
  PublicDataTreeLeafPreimage,
13
14
  } from '@aztec/stdlib/trees';
14
15
  import { GlobalVariables, TxEffect, TxHash } from '@aztec/stdlib/tx';
15
- import type { UInt32 } from '@aztec/stdlib/types';
16
16
 
17
17
  import { insertTxEffectIntoWorldTrees, makeTXEBlockHeader } from '../utils/block_creation.js';
18
18
  import type { IAvmExecutionOracle } from './interfaces.js';
@@ -48,7 +48,7 @@ export class TXEOraclePublicContext implements IAvmExecutionOracle {
48
48
  return Promise.resolve(AztecAddress.ZERO); // todo: change?
49
49
  }
50
50
 
51
- avmOpcodeBlockNumber(): Promise<UInt32> {
51
+ avmOpcodeBlockNumber(): Promise<BlockNumber> {
52
52
  return Promise.resolve(this.globalVariables.blockNumber);
53
53
  }
54
54
 
@@ -6,8 +6,9 @@ import {
6
6
  DEFAULT_TEARDOWN_L2_GAS_LIMIT,
7
7
  NUMBER_OF_L1_L2_MESSAGES_PER_ROLLUP,
8
8
  } from '@aztec/constants';
9
- import { Schnorr } from '@aztec/foundation/crypto';
10
- import { Fr } from '@aztec/foundation/fields';
9
+ import { BlockNumber } from '@aztec/foundation/branded-types';
10
+ import { Schnorr } from '@aztec/foundation/crypto/schnorr';
11
+ import { Fr } from '@aztec/foundation/curves/bn254';
11
12
  import { LogLevels, type Logger, applyStringFormatting, createLogger } from '@aztec/foundation/log';
12
13
  import { TestDateProvider } from '@aztec/foundation/timer';
13
14
  import type { KeyStore } from '@aztec/key-store';
@@ -38,25 +39,26 @@ import {
38
39
  witnessMapToFields,
39
40
  } from '@aztec/simulator/client';
40
41
  import {
42
+ CppPublicTxSimulator,
41
43
  GuardedMerkleTreeOperations,
42
44
  PublicContractsDB,
43
45
  PublicProcessor,
44
- PublicTxSimulator,
45
46
  } from '@aztec/simulator/server';
46
47
  import { type ContractArtifact, FunctionSelector, FunctionType } from '@aztec/stdlib/abi';
47
48
  import { AuthWitness } from '@aztec/stdlib/auth-witness';
49
+ import { PublicSimulatorConfig } from '@aztec/stdlib/avm';
48
50
  import { AztecAddress } from '@aztec/stdlib/aztec-address';
49
51
  import { Body, L2Block } from '@aztec/stdlib/block';
50
52
  import { type ContractInstanceWithAddress, computePartialAddress } from '@aztec/stdlib/contract';
51
53
  import { Gas, GasFees, GasSettings } from '@aztec/stdlib/gas';
52
- import { computeCalldataHash, siloNullifier } from '@aztec/stdlib/hash';
54
+ import { computeCalldataHash, computeProtocolNullifier, siloNullifier } from '@aztec/stdlib/hash';
53
55
  import {
54
56
  PartialPrivateTailPublicInputsForPublic,
55
57
  PrivateKernelTailCircuitPublicInputs,
56
58
  PrivateToPublicAccumulatedData,
57
59
  PublicCallRequest,
58
60
  } from '@aztec/stdlib/kernel';
59
- import { ClientIvcProof } from '@aztec/stdlib/proofs';
61
+ import { ChonkProof } from '@aztec/stdlib/proofs';
60
62
  import { makeAppendOnlyTreeSnapshot, makeGlobalVariables } from '@aztec/stdlib/testing';
61
63
  import { MerkleTreeId } from '@aztec/stdlib/trees';
62
64
  import {
@@ -131,8 +133,8 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
131
133
  this.logger[levelName](`${applyStringFormatting(message, fields)}`, { module: `${this.logger.module}:debug_log` });
132
134
  }
133
135
 
134
- async txeGetNextBlockNumber(): Promise<number> {
135
- return (await this.getLastBlockNumber()) + 1;
136
+ async txeGetNextBlockNumber(): Promise<BlockNumber> {
137
+ return BlockNumber((await this.getLastBlockNumber()) + 1);
136
138
  }
137
139
 
138
140
  txeGetNextBlockTimestamp(): Promise<bigint> {
@@ -291,8 +293,8 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
291
293
 
292
294
  const blockHeader = await this.pxeOracleInterface.getAnchorBlockHeader();
293
295
 
294
- const txRequestHash = getSingleTxBlockRequestHash(blockNumber);
295
- const noteCache = new ExecutionNoteCache(txRequestHash);
296
+ const protocolNullifier = await computeProtocolNullifier(getSingleTxBlockRequestHash(blockNumber));
297
+ const noteCache = new ExecutionNoteCache(protocolNullifier);
296
298
  const taggingIndexCache = new ExecutionTaggingIndexCache();
297
299
 
298
300
  const simulator = new WASMSimulator();
@@ -359,7 +361,7 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
359
361
  // According to the protocol rules, the nonce generator for the note hashes
360
362
  // can either be the first nullifier in the tx or the hash of the initial tx request
361
363
  // if there are none.
362
- const nonceGenerator = result.firstNullifier.equals(Fr.ZERO) ? txRequestHash : result.firstNullifier;
364
+ const nonceGenerator = result.firstNullifier.equals(Fr.ZERO) ? protocolNullifier : result.firstNullifier;
363
365
  const { publicInputs } = await generateSimulatedProvingResult(result, nonceGenerator, this.contractDataProvider);
364
366
 
365
367
  const globals = makeGlobalVariables();
@@ -373,20 +375,24 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
373
375
 
374
376
  const contractsDB = new PublicContractsDB(new TXEPublicContractDataSource(blockNumber, this.contractDataProvider));
375
377
  const guardedMerkleTrees = new GuardedMerkleTreeOperations(forkedWorldTrees);
378
+ const config = PublicSimulatorConfig.from({
379
+ skipFeeEnforcement: true,
380
+ collectDebugLogs: true,
381
+ collectHints: false,
382
+ collectStatistics: false,
383
+ collectCallMetadata: true,
384
+ });
376
385
  const processor = new PublicProcessor(
377
386
  globals,
378
387
  guardedMerkleTrees,
379
388
  contractsDB,
380
- new PublicTxSimulator(guardedMerkleTrees, contractsDB, globals, {
381
- doMerkleOperations: true,
382
- skipFeeEnforcement: true,
383
- }),
389
+ new CppPublicTxSimulator(guardedMerkleTrees, contractsDB, globals, config),
384
390
  new TestDateProvider(),
385
391
  );
386
392
 
387
393
  const tx = await Tx.create({
388
394
  data: publicInputs,
389
- clientIvcProof: ClientIvcProof.empty(),
395
+ chonkProof: ChonkProof.empty(),
390
396
  contractClassLogFields: [],
391
397
  publicFunctionCalldata: result.publicFunctionCalldata,
392
398
  });
@@ -486,10 +492,14 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
486
492
 
487
493
  const contractsDB = new PublicContractsDB(new TXEPublicContractDataSource(blockNumber, this.contractDataProvider));
488
494
  const guardedMerkleTrees = new GuardedMerkleTreeOperations(forkedWorldTrees);
489
- const simulator = new PublicTxSimulator(guardedMerkleTrees, contractsDB, globals, {
490
- doMerkleOperations: true,
495
+ const config = PublicSimulatorConfig.from({
491
496
  skipFeeEnforcement: true,
497
+ collectDebugLogs: true,
498
+ collectHints: false,
499
+ collectStatistics: false,
500
+ collectCallMetadata: true,
492
501
  });
502
+ const simulator = new CppPublicTxSimulator(guardedMerkleTrees, contractsDB, globals, config);
493
503
  const processor = new PublicProcessor(globals, guardedMerkleTrees, contractsDB, simulator, new TestDateProvider());
494
504
 
495
505
  // We're simulating a scenario in which private execution immediately enqueues a public call and halts. The private
@@ -497,9 +507,7 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
497
507
  // side-effect, which the AVM then expects to exist in order to use it as the nonce generator when siloing notes as
498
508
  // unique.
499
509
  const nonRevertibleAccumulatedData = PrivateToPublicAccumulatedData.empty();
500
- if (!isStaticCall) {
501
- nonRevertibleAccumulatedData.nullifiers[0] = getSingleTxBlockRequestHash(blockNumber);
502
- }
510
+ nonRevertibleAccumulatedData.nullifiers[0] = getSingleTxBlockRequestHash(blockNumber);
503
511
 
504
512
  // The enqueued public call itself we make be revertible so that the public execution is itself revertible, as tests
505
513
  // may require producing reverts.
@@ -530,7 +538,7 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
530
538
 
531
539
  const tx = await Tx.create({
532
540
  data: txData,
533
- clientIvcProof: ClientIvcProof.empty(),
541
+ chonkProof: ChonkProof.empty(),
534
542
  contractClassLogFields: [],
535
543
  publicFunctionCalldata: [calldataHashedValues],
536
544
  });
@@ -652,7 +660,8 @@ export class TXEOracleTopLevelContext implements IMiscOracle, ITxeExecutionOracl
652
660
  return [this.nextBlockTimestamp, this.authwits];
653
661
  }
654
662
 
655
- private async getLastBlockNumber(): Promise<number> {
656
- return (await this.stateMachine.node.getBlockHeader('latest'))?.globalVariables.blockNumber ?? 0;
663
+ private async getLastBlockNumber(): Promise<BlockNumber> {
664
+ const header = await this.stateMachine.node.getBlockHeader('latest');
665
+ return header ? header.globalVariables.blockNumber : BlockNumber.ZERO;
657
666
  }
658
667
  }