Open SKYBITDev3 opened 8 months ago
Agreed, would love to see an actual working example, it seems the forwarder contract has also been upgraded, while the demo is calling another one.
For example, the verify
function needs deadline
and signature
as parameters now.
forwarder.getNonce
is also not a function on the forwarder contract whereas it actually nonces
now.
yarn relay
wouldn't really work and gives Error: Cannot find module '../action/'
if I copy the code in action to relay.js
, it'll say 'too many arguments: passed to contract'
, since forwarder.verify
only accepts only one parameter
After I reconstruct the request parameter according to ERC2771Forwarder.sol
, it'll finally give me an error Error: Invalid request
, which I don't know how to fix it anymore.
Hey @zijianwang90 , i'm with the same problem (After I reconstruct the request parameter according to ERC2771Forwarder.sol, it'll finally give me an error Error: Invalid request, which I don't know how to fix it anymore.)
I could solve the others but still show the Invalid Request.
Did you manage to solve it ?
thanks in advance
I've just tried the meta-transactions demo but found many errors when just following the instructions. It seems that it was published without checking that it works beforehand, which is bad practise.
Please fix all errors so that it actually runs.
e.g.:
Replace
forwarder.verify(request, signature)
withforwarder.verify(forwardRequestData)
whereforwardRequestData
corresponds with ForwardRequestData.Add
deadline
to therequest
.Should
EIP712Domain
havesalt
?Replace
API_KEY
withRELAYER_API_KEY
andAPI_SECRET
withRELAYER_API_SECRET
in various files.Replace
apiKey
withrelayerApiKey
andapiSecret
withrelayerApiSecret
in the call tohandler()
.