req passed to _verifySigPersonalSign will be of type ERC

import smartpy as sp

ERC = sp.TRecord(sender=sp.TAddress,to=sp.TAddress,deadline=sp.TTimestamp)

class StoreValue(sp.Contract):
    def _verifySigPersonalSign(self,params):

But I am getting this error in the last line of code

Error: Error in Scenario
Literal format error: (timestamp(attr(attr(params 39)req 40)deadline 41))

How to resolve this?

1 Answer 1


To compare timestamps, you can use < or <=.

The problem in your code is that sp.timestamp(params.req.deadline) is wrongly built. sp.timestamp(...) is for constants.

Simply replace that by sp.now<=params.req.deadline.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.