Skip to content

Commit

Permalink
address comments latest
Browse files Browse the repository at this point in the history
  • Loading branch information
shubhagarwal03 committed Aug 19, 2024
1 parent 2e60a00 commit c518972
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .env.sample
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ ETHEREUM_NODE_URL=
# Include these for fetching token prices
COINGECKO_API_KEY=
DUNE_API_KEY=
MORALIS_KEY=
MORALIS_API_KEY=
2 changes: 1 addition & 1 deletion src/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@
# Dune query for fetching prices is set to LIMIT 1, i.e. it will return a single price
DUNE_PRICE_QUERY_ID = 3935228

# Dune Query 3935228 uses an end_timestamp to limit results
# Dune Query 3935228 uses an end_timestamp to limit results
# (Buffer time to return results between start_timstamp and end_timestamp only)
DUNE_QUERY_BUFFER_TIME = 100
3 changes: 2 additions & 1 deletion src/helpers/blockchain_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@


class BlockchainData:
""" Class provides functions for fetching blockchain data. """
"""Class provides functions for fetching blockchain data."""

def __init__(self, web3: Web3):
self.web3 = web3

Expand Down
3 changes: 2 additions & 1 deletion src/helpers/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@


class Database:
"""
"""
Class is used to write data to appropriate tables for the slippage project
using a database connection.
"""

def __init__(self, engine: Engine, chain_name: str):
self.engine = engine
self.chain_name = chain_name
Expand Down
2 changes: 1 addition & 1 deletion src/price_providers/moralis_pricing.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def get_price(self, price_params: dict) -> float | None:
"to_block": block_number,
}
result = evm_api.token.get_token_price(
api_key=os.getenv("MORALIS_KEY"),
api_key=os.getenv("MORALIS_API_KEY"),
params=params,
)
if "nativePrice" in result and "value" in result["nativePrice"]:
Expand Down

0 comments on commit c518972

Please sign in to comment.