Closed beeb closed 4 months ago
Hi @beeb , That would definitely be very useful! I feel like most of the time it makes more sense to make several calls on the same block rather than just one, so I prefer the second option, although both could also coexist. I'll add this very soon!
@beeb This is now possible, using both the call options syntax and the repl.block
function
Very cool, thanks a lot for the quick reaction!
I would love to be able to specify a block number to retrieve historical data from a contract.
Not sure how the syntax would look, maybe something like
myContract.myFunction{ block: 1234 }(arg1)
.Alternatively a
repl.setBlockNumber(1234)
which would then set a context for all future calls, with maybe an overloadrepl.setBlockNumber("latest")
orrepl.unsetBlockNumber()
which would then reset to using the latest block.