# Mev-inspect-py RPC URL requirements

**URL:** https://collective.flashbots.net/t/mev-inspect-py-rpc-url-requirements/958
**Category:** Data
**Tags:** question
**Created:** [December 22, 2022, 6:49pm UTC](https://collective.flashbots.net/t/mev-inspect-py-rpc-url-requirements/958 "2022-12-22T18:49:34Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Junxi](https://collective.flashbots.net/letter_avatar_proxy/v4/letter/j/eb9ed0/32.png) [@Junxi](https://collective.flashbots.net/u/Junxi)
#### Post date: [December 22, 2022, 6:49pm UTC](https://collective.flashbots.net/t/mev-inspect-py-rpc-url-requirements/958/1 "2022-12-22T18:49:34Z")

</div>

thanks so much for the list! do you know if mev-inspect-py requires running an eth node? I’m a little bit confused about what the RPC\_URL needs to be, thanks!

---

<div class="post-metadata">

### Author: ![panchiz](https://collective.flashbots.net/user_avatar/collective.flashbots.net/panchiz/32/489_2.png) [@panchiz](https://collective.flashbots.net/u/panchiz)
#### Post date: [January 3, 2023, 6:41pm UTC](https://collective.flashbots.net/t/mev-inspect-py-rpc-url-requirements/958/2 "2023-01-03T18:41:43Z")

</div>

“mev-inspect-py currently requires an RPC with support for OpenEthereum / Erigon traces (not geth)”, this can be found at the [Install Guidelines](https://docs.flashbots.net/flashbots-data/mev-inspect-py/install)

If you don’t have access to an archive node, you can use some service like QuickNode.

This is also a good resource to have a better understanding: [Flashbots: mev-inspect-py walkthrough](https://www.youtube.com/watch?v=Fuw891c4vA8)

---

<div class="post-metadata">

### Author: ![alexrmead](https://collective.flashbots.net/user_avatar/collective.flashbots.net/alexrmead/32/482_2.png) [@alexrmead](https://collective.flashbots.net/u/alexrmead)
#### Post date: [February 6, 2023, 6:21pm UTC](https://collective.flashbots.net/t/mev-inspect-py-rpc-url-requirements/958/3 "2023-02-06T18:21:29Z")

</div>

Has anyone tried to use an RPC\_URL through an SSH tunnel? I have an Erigon node running in the cloud and am trying to connect though an SSH Tunnel and getting access errors.

My command line output:

alexmead@Alexs-MacBook-Air-2 mev-inspect-py % ./mev inspect 12914944  
Inspecting block 12914944  
Skipping virtualenv creation, as specified in config file.  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockByNumber, params: (‘0xc51100’, False), retrying: 0/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockReceipts, params: (12914944,), retrying: 0/5  
ERROR:mev\_inspect.retry:Request for method trace\_block, params: (‘0xc51100’,), retrying: 0/5  
ERROR:mev\_inspect.retry:Request for method eth\_feeHistory, params: (1, ‘0xc51100’, None), retrying: 0/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockByNumber, params: (‘0xc51100’, False), retrying: 1/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockReceipts, params: (12914944,), retrying: 1/5  
ERROR:mev\_inspect.retry:Request for method trace\_block, params: (‘0xc51100’,), retrying: 1/5  
ERROR:mev\_inspect.retry:Request for method eth\_feeHistory, params: (1, ‘0xc51100’, None), retrying: 1/5  
ERROR:mev\_inspect.retry:Request for method eth\_feeHistory, params: (1, ‘0xc51100’, None), retrying: 2/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockReceipts, params: (12914944,), retrying: 2/5  
ERROR:mev\_inspect.retry:Request for method trace\_block, params: (‘0xc51100’,), retrying: 2/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockByNumber, params: (‘0xc51100’, False), retrying: 2/5  
ERROR:mev\_inspect.retry:Request for method trace\_block, params: (‘0xc51100’,), retrying: 3/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockByNumber, params: (‘0xc51100’, False), retrying: 3/5  
ERROR:mev\_inspect.retry:Request for method eth\_feeHistory, params: (1, ‘0xc51100’, None), retrying: 3/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockReceipts, params: (12914944,), retrying: 3/5  
ERROR:mev\_inspect.retry:Request for method eth\_getBlockByNumber, params: (‘0xc51100’, False), retrying: 4/5  
Traceback (most recent call last):  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 985, in \_wrap\_create\_connection  
return await self.\_loop.create\_connection(\*args, \*\*kwargs) # type: ignore[return-value] # noqa  
File “/usr/local/lib/python3.9/asyncio/base\_events.py”, line 1065, in create\_connection  
raise exceptions[0]  
File “/usr/local/lib/python3.9/asyncio/base\_events.py”, line 1050, in create\_connection  
sock = await self.\_connect\_sock(  
File “/usr/local/lib/python3.9/asyncio/base\_events.py”, line 961, in \_connect\_sock  
await self.sock\_connect(sock, address)  
File “/usr/local/lib/python3.9/asyncio/selector\_events.py”, line 500, in sock\_connect  
return await fut  
File “/usr/local/lib/python3.9/asyncio/selector\_events.py”, line 535, in \_sock\_connect\_cb  
raise OSError(err, f’Connect call failed {address}')  
ConnectionRefusedError: [Errno 111] Connect call failed (‘127.0.0.1’, 8545)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):  
File “”, line 1, in   
File “/home/flashbot/.local/lib/python3.9/site-packages/click/core.py”, line 1137, in **call**  
return self.main(\*args, \*\*kwargs)  
File “/home/flashbot/.local/lib/python3.9/site-packages/click/core.py”, line 1062, in main  
rv = self.invoke(ctx)  
File “/home/flashbot/.local/lib/python3.9/site-packages/click/core.py”, line 1404, in invoke  
return ctx.invoke(self.callback, \*\*ctx.params)  
File “/home/flashbot/.local/lib/python3.9/site-packages/click/core.py”, line 763, in invoke  
return \_\_callback(\*args, \*\*kwargs)  
File “/app/mev\_inspect/concurrency.py”, line 18, in wrapper  
loop.run\_until\_complete(f(\*args, \*\*kwargs))  
File “/usr/local/lib/python3.9/asyncio/base\_events.py”, line 647, in run\_until\_complete  
return future.result()  
File “/app/cli.py”, line 45, in inspect\_block\_command  
await inspector.inspect\_single\_block(  
File “/app/mev\_inspect/inspector.py”, line 56, in inspect\_single\_block  
return await inspect\_block(  
File “/app/mev\_inspect/inspect\_block.py”, line 68, in inspect\_block  
await inspect\_many\_blocks(  
File “/app/mev\_inspect/inspect\_block.py”, line 105, in inspect\_many\_blocks  
block = await create\_from\_block\_number(  
File “/app/mev\_inspect/block.py”, line 31, in create\_from\_block\_number  
block\_timestamp, receipts, traces, base\_fee\_per\_gas = await asyncio.gather(  
File “/app/mev\_inspect/block.py”, line 60, in \_find\_or\_fetch\_block\_timestamp  
return await \_fetch\_block\_timestamp(w3, block\_number)  
File “/app/mev\_inspect/block.py”, line 105, in \_fetch\_block\_timestamp  
block\_json = await w3.eth.get\_block(block\_number)  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/eth.py”, line 298, in get\_block  
return await self.\_get\_block(block\_identifier, full\_transactions) # type: ignore  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/module.py”, line 72, in caller  
result = await w3.manager.coro\_request(method\_str,  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/manager.py”, line 202, in coro\_request  
response = await self.\_coro\_make\_request(method, params)  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/manager.py”, line 157, in \_coro\_make\_request  
return await request\_func(method, params)  
File “/app/mev\_inspect/retry.py”, line 60, in middleware  
return await make\_request(method, params)  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/providers/async\_rpc.py”, line 73, in make\_request  
raw\_response = await async\_make\_post\_request(  
File “/home/flashbot/.local/lib/python3.9/site-packages/web3/\_utils/request.py”, line 59, in async\_make\_post\_request  
async with session.post(endpoint\_uri,  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/client.py”, line 1140, in **aenter**  
self.\_resp = await self.\_coro  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/client.py”, line 535, in \_request  
conn = await self.\_connector.connect(  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 543, in connect  
proto = await self.\_create\_connection(req, traces, timeout)  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 906, in \_create\_connection  
\_, proto = await self.\_create\_direct\_connection(req, traces, timeout)  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 1205, in \_create\_direct\_connection  
raise last\_exc  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 1174, in \_create\_direct\_connection  
transp, proto = await self.\_wrap\_create\_connection(  
File “/home/flashbot/.local/lib/python3.9/site-packages/aiohttp/connector.py”, line 991, in \_wrap\_create\_connection  
raise client\_error(req.connection\_key, exc) from exc  
aiohttp.client\_exceptions.ClientConnectorError: Cannot connect to host localhost:8545 ssl:default [Connect call failed (‘127.0.0.1’, 8545)]  
command terminated with exit code 1
