ChristobelDiana / truffle

0 stars 0 forks source link

truffle migrate got stuck after generating transaction hash #1

Open ChristobelDiana opened 5 years ago

ChristobelDiana commented 5 years ago

I tried to deploy metacoin project. After unlocking my account and start mining,I called truffle migrate, it got stuck after displaying transaction hash. I used geth rpc. Kindly help solving this issue. image

rob-Hitchens commented 5 years ago

Can you please expand the view. We need more information about the underlying processes here. Let's see the miner?

To give an example of what we might be looking for, net42 uses a very low initial difficulty. Given Ethereum's target block time of 14 seconds, eventually difficulty with self-adjust and the blocks will stop coming (over compensation). A work around to that is to init, mine, truffle migrate --reset. I'm not sure that is the problem or the solution. We just can't tell from looking at this.

If you are using terminator, you can get multiple windows open - miner, truffle, more ... alternatively, please arrange things so we can see what you see. Every indication is mining is not happening so let's see why we think it is.

ChristobelDiana commented 5 years ago

Can you please expand the view. We need more information about the underlying processes here. Let's see the miner?

To give an example of what we might be looking for, net42 uses a very low initial difficulty. Given Ethereum's target block time of 14 seconds, eventually difficulty with self-adjust and the blocks will stop coming (over compensation). A work around to that is to init, mine, truffle migrate --reset. I'm not sure that is the problem or the solution. We just can't tell from looking at this.

If you are using terminator, you can get multiple windows open - miner, truffle, more ... alternatively, please arrange things so we can see what you see. Every indication is mining is not happening so let's see why we think it is.

ChristobelDiana commented 5 years ago

Ok. hereby I have attached the screenshots. I unlocked my account, started mining and tried truffle migrate --reset too. but again I get the same problem.

On Sun, Apr 21, 2019 at 4:50 AM Rob Hitchens notifications@github.com wrote:

Can you please expand the view. We need more information about the underlying processes here. Let's see the miner?

To give an example of what we might be looking for, net42 uses a very low initial difficulty. Given Ethereum's target block time of 14 seconds, eventually difficulty with self-adjust and the blocks will stop coming (over compensation). A work around to that is to init, mine, truffle migrate --reset. I'm not sure that is the problem or the solution. We just can't tell from looking at this.

If you are using terminator, you can get multiple windows open - miner, truffle, more ... alternatively, please arrange things so we can see what you see. Every indication is mining is not happening so let's see why we think it is.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ChristobelDiana/truffle/issues/1#issuecomment-485194859, or mute the thread https://github.com/notifications/unsubscribe-auth/ALFEYHPF4OKLXKHWIOPS7V3PROQK3ANCNFSM4HHJNVKA .

rob-Hitchens commented 5 years ago

Please reinitialized the net42 with --init and test again. I have a suspicion and this is the fastest method to resolve it.

CallMeGwei commented 5 years ago

Can we see a copy of your net42 config? I remember that I had an error in mine that caused some non-obvious issues...

ChristobelDiana commented 5 years ago

geth --datadir ~/.ethereum/net42 init ~/DAPPS/genesis42.json geth --datadir ~/.ethereum/net42 --networkid 42 --rpc --rpcport 8545 --rpcaddr 0.0.0.0 --rpccorsdomain "*" --rpcapi "eth,net,web3" --gcmode archive console

On Sat, Apr 27, 2019 at 2:32 AM CallMeGwei notifications@github.com wrote:

Can we see a copy of your net42 config? I remember that I had an error in mine that caused some non-obvious issues...

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ChristobelDiana/truffle/issues/1#issuecomment-487200115, or mute the thread https://github.com/notifications/unsubscribe-auth/ALFEYHNBABDWIT6SECITGVDPSNUW7ANCNFSM4HHJNVKA .

CallMeGwei commented 5 years ago

Yeah, that looks like exactly what I have in my launcher script... so nothing wrong there.

From your screenshots, it seems that at least one contract is being sent to geth and is, in fact, being deployed despite the truffle message. Are you able to jump in to the truffle console and pull up that transaction hash manually?

Upon closer inspection... in your whole desktop screenshot, window top left... what is all of that above 1_initial_migrations.js ?

For comparison... when I truffle migrate --reset I see this:

image

The "Summary" line comes after the migrate command has finished. What's weird about your screenshot, to me, is that it's showing "summary" and then continues to process another migrate run without accepting any user input in between.

It might be nothing, but it is one of the only "out of the ordinary" things I can see from what you have provided so far.

ChristobelDiana commented 5 years ago

Actually, that summary line came for migrations dry -run(simulation). Did you get this simulation when migrating? Thanks anyway. I have tried configuring with different network id in windows and it works now.

CallMeGwei commented 5 years ago

Never got any simulation while running migrations.

Glad you got it sorted!

xavierlepretre commented 5 years ago

Is the issue still open?

ChristobelDiana commented 5 years ago

Is the issue still open?

The issue is not sorted out. Could not find the reason why this error occurred.Found alternative solution in windows

xavierlepretre commented 5 years ago

I don't see any mining being done. No block is being formed. I suspect that the net42 genesis block was not put there. You need to geth --datadir /where/ever removedb then launch again. Look carefully at the log, it will tell you if it put the proper genesis file or if it defaulted to the main net one.

stackchain commented 3 years ago

Facing the same issue here.