Skip to content

Commit

Permalink
(fix) Solved a couple of warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
aarmoa committed Nov 14, 2024
1 parent 111373d commit 407067a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyinjective/composer.py
Original file line number Diff line number Diff line change
Expand Up @@ -2395,7 +2395,7 @@ def MsgRelayProviderPrices(self, sender: str, provider: str, symbols: list, pric
oracle_prices = []

for price in prices:
scale_price = Decimal((price) * pow(10, 18))
scale_price = Decimal(price * pow(10, 18))
price_to_bytes = bytes(str(scale_price), "utf-8")
oracle_prices.append(price_to_bytes)

Expand Down
3 changes: 2 additions & 1 deletion tests/test_composer_deprecation_warnings.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

from pyinjective.composer import Composer
from pyinjective.core.network import Network
from pyinjective.proto.injective.oracle.v1beta1 import oracle_pb2 as oracle_pb
from tests.model_fixtures.markets_fixtures import ( # noqa: F401
btc_usdt_perp_market,
first_match_bet_market,
Expand Down Expand Up @@ -481,7 +482,7 @@ def test_msg_create_insurance_fund_deprecation_warning(self, basic_composer):
quote_denom="INJ",
oracle_base="oracle_base",
oracle_quote="oracle_quote",
oracle_type="Band",
oracle_type=oracle_pb.OracleType.Band,
expiry=-1,
initial_deposit=1,
)
Expand Down

0 comments on commit 407067a

Please sign in to comment.