4

I am trying to deploy thousands of contracts on Ganache GUI. At first, it process all transactions very fast (deploy contracts and transactions for calling setters functions) . After some transactions, may 500/1000 or more, it become so slow and process a single transaction in 5-8 seconds or sometime even more . Is it normal ? It is because of calculating difficulty level , automatically ?....

2 Answers 2

2

Try to work with ganache-cli instead of ganache-gui.

We faced similar issues with our integration tests - lots of transactions are very slow with the Ganache GUI (especially under Windows the UI has update problems).

The command line interface ganache-cli is much more stable and runs in terminal as well as in docker container. From the functional point of view, you have everything that you need in ganache-cli.

Ganache GUI is nice for demonstrations to management & customers or training sessions. During development and for test purposes, it's better to use the ganache-cli.

2
  • thanks for your answer, i will try and update you...
    – Amir Ali
    Commented Jan 6, 2020 at 3:31
  • yes, now i have also tried Ganache CLI v6.7.0 (ganache-core: 2.8.0), and the same problem.. you can see my same kind of question there ... ethereum.stackexchange.com/questions/78728/…
    – Amir Ali
    Commented Jan 8, 2020 at 3:10
0

Ganache is not well suited for complex deployments or resource intensive contracts. Although 1000 txs doesn't seems to much, perhaps it is constrained by your VM resources like memory or CPU.

As alternative I'll suggest to try geth or parity in development chain mode. They should work quite similar to ganache in automine mode.

3
  • 1
    thanks for your answer. I will try your suggestion, HOWEVER, if i still want to use Ganache.. then I am facing unresponsiveness of Ganache, if i left my laptop unattended. NOTED that i have already disable power option to never for sleeping
    – Amir Ali
    Commented Jan 5, 2020 at 8:45
  • @ismael does geth or parity in development chain mode support methods like hardhat_setSorageAt? Commented Oct 23, 2023 at 17:11
  • 1
    @HristoTodorov It will be better if you create a new question for that issue. I haven't used geth recently, so I can't help you there.
    – Ismael
    Commented Oct 23, 2023 at 20:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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