metaspartan / explorer

Ethereum Block Explorer (ETHExplorer V2) - Realtime Price Ticker, Shapeshift.io Integration, etc. (Project is currently not under active development, if you have a bug fix, please open a PR) My current project can be found at https://github.com/metaspartan/denarius (D a better cryptocurrency than ETH)
Other
486 stars 330 forks source link

Unable to connect to Ganache TestRPC #40

Open zulhfreelancer opened 6 years ago

zulhfreelancer commented 6 years ago

Hi,

I'm trying to use this explorer with Ganache TestRPC but I got the error below:

Error: Transaction at index 0x00 does not exist in block.
    at Object.InvalidResponse (web3.min.js:1)
    at s.send (web3.min.js:2)
    at a.send (web3.min.js:2)
    at updateTXList (mainController.js:202)
    at Object.<anonymous> (mainController.js:9)
    at Object.e [as invoke] (angular.js:4473)
    at Q.instance (angular.js:9093)
    at L (angular.js:8205)
    at g (angular.js:7637)
    at g (angular.js:7641)

screen shot 2018-02-21 at 6 29 09 am

When I switched and changed the GETH_HOSTNAME and GETH_RPCPORT to real Geth node (my private blockchain node in the cloud), the explorer is working fine.

Any idea what I missed here? Please advice.

Thank you.

jacktang commented 6 years ago

Well, I want to use eth explorer on Ganache also.

Alaradia commented 6 years ago

That is a issue with Ganache not with the explorer

jacktang commented 6 years ago

Now I can open the explorer on testrpc.

zulhfreelancer commented 6 years ago

@jacktang please share the workarounds.

jacktang commented 6 years ago

I just modified the geth_command (https://github.com/carsenk/explorer/blob/master/app/app.js#L14) to start testrpc

zulhfreelancer commented 6 years ago

@jacktang are you using Ganache GUI or Ganache CLI?

jacktang commented 6 years ago

testrpc

On Wed, Feb 28, 2018 at 1:06 AM, Zulhilmi Zainudin <notifications@github.com

wrote:

@jacktang https://github.com/jacktang are you using Ganache GUI or Ganache CLI?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/carsenk/explorer/issues/40#issuecomment-368951359, or mute the thread https://github.com/notifications/unsubscribe-auth/AACtNcE3xww4Z6PdF8SMrbrNaseRx90xks5tZDYAgaJpZM4SNJE7 .

-- Jack Tang

http://www.linkedin.com/in/jacktang

masato25 commented 6 years ago

I solved this problem, just add a try & catch block, then it works fine for me.

https://github.com/masato25/explorer/commit/169f405ed0b9edf00de41ec8341d891d440533ab

mandarvaze commented 5 years ago

@masato25 Have you sent a PR with your changes ? Might be useful for others as well.