Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions hyperliquid/exchange.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,8 @@ def _slippage_price(
px = float(self.info.all_mids(dex)[coin])

asset = self.info.coin_to_asset[coin]
# spot assets start at 10000
is_spot = asset >= 10_000
# spot assets start at 10,000, Hip3 perps start at 110,000
is_spot = 10_000 <= asset < 110_000

# Calculate Slippage
px *= (1 + slippage) if is_buy else (1 - slippage)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "hyperliquid-python-sdk"
version = "0.24.0"
version = "0.24.1"
description = "SDK for Hyperliquid API trading with Python."
readme = "README.md"
authors = ["Hyperliquid <hello@hyperliquid.xyz>"]
Expand Down
Loading