New answers tagged

0

I'm embarrassed to report that I found my problem. It had nothing to do with the Truffle contract abstraction or web3.js contract object. The problem was in the web3.js function estimateGas. This function doesn't just give you a gas estimate, it simulates the transaction and so throws any errors that the function call would throw when used in anger. So, when ...


1

You changed the gas limit to 32000 which is too low for this function to operate.. the $8 cannot be refunded. Simple example (1 gas is 1 lego piece) To build a house you need 150000 lego pieces (just a number I don't really know how much it costs) but you sent in your transaction only 32000 lego pieces, which is not enough. The contract does not know exactly ...


1

Came to know that WSL-2 cannot connect to the localhost directly. See this and this. WSL-2 has its own port to listen to. Ganache gives you the option to select that port instead of localhost. Go to Settings > Server > Hostname > 172.23.160.1 - Ethernet (WSL) Can use the command provided by @Ismael above in the comments to check if the port is ...


1

I had the same issue for that tutorial looks like once the test is ran it adds an import for react-bootstrap/lib/Breadcrumb. I just removed the import and reran the test and it worked.


Top 50 recent answers are included