Describe the bug
Unable to set custom ContractCache when using a custom arweave gateway. Appears that the default ContractDefinitionLoader and ArweaveGatewayBundledContractDefinitionLoader do not support nor implement the cache methods as seen here and here
Error: No cache implemented for this loader
at ContractDefinitionLoader.setSrcCache (/example-warp-evaluator/node_modules/warp-contracts/src/core/modules/impl/ContractDefinitionLoader.ts:156:11)
at Warp.useContractCache (/example-warp-evaluator/node_modules/warp-contracts/src/core/Warp.ts:150:27)
at Object.<anonymous> (/example-warp-evaluator/src/middleware/warp.ts:53:4)
at Module._compile (node:internal/modules/cjs/loader:1256:14)
at Module.m._compile (/example-warp-evaluator/node_modules/ts-node/src/index.ts:1618:23)
at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
at Object.require.extensions.<computed> [as .ts] (/example-warp-evaluator/node_modules/ts-node/src/index.ts:1621:12)
at Module.load (node:internal/modules/cjs/loader:1119:32)
at Function.Module._load (node:internal/modules/cjs/loader:960:12)
at Module.require (node:internal/modules/cjs/loader:1143:19)
Expected behavior
You can provide useContractCache() with lmdb (and other SortKey caches) in the same manner you can when useArweaveGw is set to false in the WarpFactory.
Desktop (please complete the following information):
OS: Mac OS
Node.js version: Node 18.17.1
warp-contracts SDK version: 1.4.22
warp-contracts plugins being used (+ versions): N/A
Describe the bug Unable to set custom
ContractCache
when using a custom arweave gateway. Appears that the defaultContractDefinitionLoader
andArweaveGatewayBundledContractDefinitionLoader
do not support nor implement the cache methods as seen here and hereTo Reproduce Branch to reproduce in service here
Relevant code:
Error:
Expected behavior You can provide
useContractCache()
withlmdb
(and otherSortKey
caches) in the same manner you can whenuseArweaveGw
is set tofalse
in theWarpFactory
.Desktop (please complete the following information):