-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Description
What was wrong?
There are many different ways to set up a web3 instance. For example:
from web3.auto import w3
from web3 import IPCProvider, Web3
w3 = Web3(IPCProvider('path/to/ipc/file.ipc'))
from web3 import WebsocketProvider, Web3
w3 = Web3(WebsocketProvider('ws://localhost:8546'))
from web3 import HTTPProvider, Web3
w3 = Web3(HTTPProvider('http://localhost:8545'))
from web3.auto.infura import w3
from web3.auto.infura.rinkeby import w3
...
But with each of these options comes certain configuration that needs to happen.
For example, web3.auto
requires either an environment variable set, a local node running on mainnet, or an http provider running on localhost:8545. But you have to go to a different page in the docs to see that.
Similarly, if you are trying to connect to a local geth node over HTTP or Websockets, you need to start geth with the --rpc
or --ws
flag, respectively, in order to connect.
It would be nice if the docs mentioned these nuances.
Metadata
Metadata
Assignees
Labels
No labels