Skip to main content
fix grammar
Source Link

My Vyper contract caused a Ganache error, because the vyper compiler formats its bytecode output with a 0x prefix and a \n suffix.

web3j-cli takes that string as is and puts it into a contract Java wrapper class. When ganache-cli receives that binary string, it throws a "stack underflow" error.

After stripping off the 0x and \nunwanted chars, the contract deploydeploys successfully.

As of Feb. 2022, Web3j does not explicitlydoesn't officially support contracts compiled from Vyper. But you can make it work, as I explained.

When solcjs outputs a contract's binary, it does not add 0x or \n.

My Vyper contract caused a Ganache error, because the vyper compiler formats its bytecode output with a 0x prefix and a \n suffix.

web3j-cli takes that string as is and puts it into a contract Java wrapper class. When ganache-cli receives that binary string, it throws a "stack underflow" error.

After stripping off the 0x and \n chars, the contract deploy successfully.

As of Feb. 2022, Web3j does not explicitly support contracts compiled from Vyper.

When solcjs outputs a contract's binary, it does not add 0x or \n.

My Vyper contract caused a Ganache error, because the vyper compiler formats its bytecode output with a 0x prefix and a \n suffix.

web3j-cli takes that string as is and puts it into a contract Java wrapper class. When ganache-cli receives that binary string, it throws a "stack underflow" error.

After stripping off the unwanted chars, the contract deploys successfully.

As of Feb. 2022, Web3j doesn't officially support contracts compiled from Vyper. But you can make it work, as I explained.

When solcjs outputs a contract's binary, it does not add 0x or \n.

fixed grammar
Source Link

The reason my VyperMy Vyper contract caused a GanacheGanache error, is because the vyper compiler putsformats its bytecode output with a \n0x character at the end of theprefix and a bytecode\n line in the bin output filesuffix. Web3j used

web3j-cli takes that linestring as is and puts it into a contract Java wrapper class. When ganache-cli receives that binary string, it throws a "stack underflow" error.

When I removeAfter stripping off the \n0x fromand bytecode\n output and create achars, the contract wrapper classdeploy successfully.

As of Feb. 2022, Web3j successfully deploysdoes not explicitly support contracts compiled from Vyper.

When solcjs outputs a contract's binary, it :-)does not add 0x or \n.

The reason my Vyper contract caused a Ganache error, is because the vyper compiler puts a \n character at the end of the bytecode line in the bin output file. Web3j used that line as is.

When I remove the \n from bytecode output and create a contract wrapper class, Web3j successfully deploys it :-)

My Vyper contract caused a Ganache error, because the vyper compiler formats its bytecode output with a 0x prefix and a \n suffix.

web3j-cli takes that string as is and puts it into a contract Java wrapper class. When ganache-cli receives that binary string, it throws a "stack underflow" error.

After stripping off the 0x and \n chars, the contract deploy successfully.

As of Feb. 2022, Web3j does not explicitly support contracts compiled from Vyper.

When solcjs outputs a contract's binary, it does not add 0x or \n.

Source Link

The reason my Vyper contract caused a Ganache error, is because the vyper compiler puts a \n character at the end of the bytecode line in the bin output file. Web3j used that line as is.

When I remove the \n from bytecode output and create a contract wrapper class, Web3j successfully deploys it :-)