@dan-i
Hi, I’m struggling with “How to Build Serverless Dapps Part 1 - Web3.js & Moralis Programming Tutorial” I can’t use migrate.
I’ve cloned the files from GitHub, entered my Moralis App id, and server into main.js.
and when trying to migrate, it can’t find ganache server, so i edit truffle config and run “truffle migrate --reset --network development”
then it starts compiling and i get this:
2_contract_migration.js
=======================
Deploying 'FlipContract'
------------------------
> transaction hash: 0x1c7780ef6814fbb69a9be13217e064c9c270de3033e3c643319d46acbbe648ab
> Blocks: 0 Seconds: 0
> contract address: 0x56B68B51a46ED785f7fc0353d104114E04CB9B76
> block number: 27
> block timestamp: 1617036598
> account: 0xE0190cAf00005a9Eeb4556B0D59e3FbDd171060f
> balance: 99.32721786
> gas used: 853046 (0xd0436)
> gas price: 20 gwei
> value sent: 0 ETH
> total cost: 0.01706092 ETH
⠋ Saving migration to chain.Error: Returned error: VM Exception while processing transaction: invalid opcode
Error: Returned error: VM Exception while processing transaction: invalid opcode
----------- then a lot of stuff, tried to save it as a file, but its 47mb of text --------------------
RuntimeError: abort(Error: Returned error: VM Exception while processing transaction: invalid opcode). Build with -s ASSERTIONS=1 for more info.
at process.abort (/Users/alex/.config/truffle/compilers/node_modules/soljson-v0.7.5+commit.eb77ed08.js:1:13877)
at process.emit (events.js:198:13)
at process.emit (/usr/local/lib/node_modules/truffle/build/webpack:/node_modules/source-map-support/source-map-support.js:495:1)
at processEmit [as emit] (/usr/local/lib/node_modules/truffle/build/webpack:/node_modules/signal-exit/index.js:155:1)
at emitPromiseRejectionWarnings (internal/process/promises.js:140:18)
at process._tickCallback (internal/process/next_tick.js:69:34)