warp-contracts/warp

[BUG] - maxInteractionEvaluationTimeSeconds larger than Number.MAX_SAFE_INTEGER

dtfiedler opened this issue · 0 comments

Describe the bug
If a contract-manifest tag includes maxInteractionEvaluationTimeSeconds larger than 32 bit signed integer (2,147,483,647) - setTimeout here defaults to 1 and errors.

Evaluation logs:

(node:1) TimeoutOverflowWarning: 9007199254740991000 does not fit into a 32-bit signed integer
Timeout duration was set to 1.

To Reproduce
Create a contract with maxInteractionEvaluationTimeSeconds (9007199254740991), or use an existing contract and set the evaluationOptions to number larger than 2_147_483_647

Expected behavior
Any contract-manifest tags that are numbers should protect against numbers larger than 2_147_483_647 (9007199254740991)

Desktop (please complete the following information):

  • OS: [e.g. Linux]
  • Node.js version: 18.17.1
  • warp-contracts SDK version: 1.4.33
  • warp-contracts plugins being used (+ versions): None