Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
djeck1432 committed Nov 18, 2024
1 parent 1f66f03 commit 976129a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions apps/dashboard_app/helpers/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
import pandas as pd
import requests
from google.cloud.storage import Client
from shared.blockchain_call import func_call
from shared.types import TokenParameters
from starknet_py.cairo.felt import decode_shortstring

from dashboard_app.helpers.settings import (
PAIRS,
UNDERLYING_SYMBOLS_TO_UNDERLYING_ADDRESSES,
)
from shared.blockchain_call import func_call
from shared.types import TokenParameters

GS_BUCKET_NAME = "derisk-persistent-state/v3"

Expand Down
1 change: 1 addition & 0 deletions apps/data_handler/handlers/loan_states/zklend/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ def _set_loan_state_per_user(self, loan_state: ZkLendCollateralDebt) -> None:
:param loan_state: The loan state data.
"""
# FIXME fetch only result enabled/disabled for the user
user_loan_state = self.zklend_state.loan_entities[loan_state.user_id]
user_loan_state.collateral_enabled.values = loan_state.collateral_enabled
user_loan_state.collateral.values = self._convert_float_to_decimal(loan_state.collateral)
Expand Down
4 changes: 2 additions & 2 deletions apps/legacy_app/update_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def update_data(zklend_state: src.zklend.ZkLendState):
# asyncio.run(hashstack_v0_state.collect_token_parameters())
# asyncio.run(hashstack_v1_state.collect_token_parameters())
logging.info(f"collected token parameters in {time.time() - t2}s")

# TODO move it to separated function
# Get prices of the underlying tokens.
t_prices = time.time()
states = [
Expand Down Expand Up @@ -103,7 +103,7 @@ def update_data(zklend_state: src.zklend.ZkLendState):
)
prices = src.helpers.get_prices(token_decimals=underlying_addresses_to_decimals)
logging.info(f"prices in {time.time() - t_prices}s")

# TODO: move it to separated function END
t_swap = time.time()
swap_amms = src.swap_amm.SwapAmm()
asyncio.run(swap_amms.init())
Expand Down

0 comments on commit 976129a

Please sign in to comment.