New answers tagged


latest version truffle has an inbuilt debugger that can be used to debug state of a failed transaction. $ truffle debug <transaction-id> where <transaction-id> is id of the errored transaction, once debugger is launched follow the instruction to walkthrough and print variable state etc find out more here :


Your theory is correct. MetaMask sends a static (local) call to the contract. The call is the same as a real transaction, except 1) its state changes are not persisted 2) it doesn't cost any gas, since it doesn't send a transaction to the blockchain 3) is executed against your local node's data only. That way is not 100% accurate, but it's basically the best ...


b.x = new uint[](0); // will that be a dynamic array in storage? As for now it's not. It's an array of length 0. It could be dynamic but you will still need to know the length of the array on creation. The (0) represent the length of this array. Therefor you should probably use something like; b.x = new uint[](incomingArray.length); so this array will be ...


As per the error message and logs it looks like you're passing invalid arguments --- (argument="address", value="1000000", code=INVALID_ARGUMENT, version=address/5.4.0) The address argument expects an address type argument, but you're passing a number (1000000) instead. (argument=null, value="1000000", code=INVALID_ARGUMENT, ...


Someone explained the solution elsewhere. The issue was not with the code, rather in the way you use remote contracts in Remix: even though you are adding an established contract, you have to select the compiled contract that is at that address.

Top 50 recent answers are included