Skip to content

Commit

Permalink
Added a new explicit env var for public RPC.
Browse files Browse the repository at this point in the history
  • Loading branch information
mariacarmina committed Jun 15, 2023
1 parent 906bb03 commit 018600f
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion aquarius/events/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def get_address_file():


def get_config_chain_id():
config_rpc = os.getenv("NETWORK_URL")
config_rpc = os.getenv("PUBLIC_RPC")
provider = get_web3_connection_provider(config_rpc)
web3 = Web3(provider)

Expand Down
1 change: 1 addition & 0 deletions exportlocal.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export DB_USERNAME=elastic
export EVENTS_ALLOW=0
export EVENTS_RPC=http://127.0.0.1:8545
export NETWORK_URL=http://127.0.0.1:8545
export PUBLIC_RPC=http://127.0.0.1:8545
export EVENTS_TESTS_PRIVATE_KEY=0x1f990f8b013fc5c7955e0f8746f11ded231721b9cf3f99ff06cdc03492b28090
export EVENTS_TESTS_PRIVATE_KEY2=0x732fbb7c355aa8898f4cff92fa7a6a947339eaf026a08a51f171199e35a18ae0
export EVENTS_TESTS_PRIVATE_KEY3=0x8683d6511213ac949e093ca8e9179514d4c56ce5ea9b83068f723593f913b1ab
Expand Down
1 change: 1 addition & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ env =
D:EVENTS_ALLOW = 0
D:EVENTS_RPC = http://127.0.0.1:8545
D:NETWORK_URL = http://127.0.0.1:8545
D:PUBLIC_RPC = http://127.0.0.1:8545
D:EVENTS_TESTS_PRIVATE_KEY=0x1f990f8b013fc5c7955e0f8746f11ded231721b9cf3f99ff06cdc03492b28090
D:EVENTS_TESTS_PRIVATE_KEY2=0x732fbb7c355aa8898f4cff92fa7a6a947339eaf026a08a51f171199e35a18ae0
D:EVENTS_TESTS_PRIVATE_KEY3=0x8683d6511213ac949e093ca8e9179514d4c56ce5ea9b83068f723593f913b1ab
Expand Down
2 changes: 1 addition & 1 deletion tests/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def test_setup_web3(monkeypatch):


def test_config_rpc(monkeypatch):
monkeypatch.setenv("NETWORK_URL", "https://rpc-mumbai.maticvigil.com/")
monkeypatch.setenv("PUBLIC_RPC", "https://rpc-mumbai.maticvigil.com/")

with pytest.raises(
Exception, match="Mismatch of chain IDs between configuration and events RPC!"
Expand Down

0 comments on commit 018600f

Please sign in to comment.