StephenGrider / EthereumCasts

Companion repo to an Ethereum/Solidity course on Udemy
2.13k stars 1.31k forks source link

Update for ^0.4.23 #5

Closed entrptaher closed 6 years ago

entrptaher commented 6 years ago

The http://remix.ethereum.org throws warning about contstructor on this line https://github.com/StephenGrider/EthereumCasts/blob/master/inbox/contracts/Inbox.sol#L6.

Also truffle will fail to deploy the contract. Even though it has been only 3-4 months, the code stopped working as this is a fast paced world.

The course and code should be updated for that.

Peace.

PoojaG20 commented 6 years ago

For constructor its just a warning , it can work then too. But for deploying the contract using truffle it is able to create contract but the status is given Fail. Any updates how to fix it. It gives error-"The contract could not be stored, please check your gas limit." Increasing the gas limit also did not help.

entrptaher commented 6 years ago

@PoojaG20 This is related to this issue here. https://github.com/trufflesuite/truffle-hdwallet-provider/issues/33

Try to npm install --save truffle-hdwallet-provider@0.0.3.

PoojaG20 commented 6 years ago

Thanks @entrptaher it was version issue only but it is not 3.0.0 rather 0.0.3. npm install --save truffle-hdwallet-provider@0.0.3 Worked

entrptaher commented 6 years ago

Opps, sorry, it was a typo. :D

But still the problem remains that the code should be updated for ^0.4.23

Kanishka6996 commented 6 years ago

On deploy.js you change .deploy({ data: compiledFactory.bytecode })

To: .deploy({ data: '0x' + compiledFactory.bytecode })

it will work.

entrptaher commented 6 years ago

I feel the original repo should be updated. However this solves problem and I am gonna close the issue until the problem arises again.