1

I have written a simple smart contract that allows to store a string, and I'am trying to use go-ethereum(which is similar to web3j). When I execute a transaction, I have this error

    VM returned with error err="invalid opcode 0x1c"

I am testing on a local network that I have developed using geth nodes. When I tested the same smart contract using remix (connecting remix to my local network), everything went right and the smart contracts executes fine.

  • Hi there. "I have written a simple smart contract" - we'll need to see the contract code. We'll also need further information about your environment. How many nodes are you using? Which client version? Have you made any alterations to the client code? You mentioned Geth nodes, but tagged the question with Quorum. Can you clarify if you're using Quorum or not? – Richard Horrocks Jun 25 '19 at 8:57
  • I'am using geth client, qurum uses these client to interact the blcockhain and it adds other features like constellation nodes for security. I'am using a 5 node network. this is my environment: Version: 1.8.18-stable Git Commit: aa74813e330f8f7782df629d5ec8317c81739827 Quorum Version: 2.2.3 Architecture: amd64 Protocol Versions: [63 62] Network Id: 1337 Go Version: go1.10 Operating System: linux – MS B Jun 25 '19 at 9:18
3

That opcode is a recent addition to geth in the Constantinople release. You need to add the following to your genesis to enable Constantinople:

"constantinopleBlock":0,
| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.