mirror of
https://github.com/luxfi/dex.git
synced 2026-09-24 00:26:31 +00:00
The best_venue_buy() and best_venue_sell() methods used Decimal::from_double(1e18) as a sentinel value, which caused integer overflow (1e18 * 1e8 scale = 1e26 exceeds int64_t max ~9.2e18). This resulted in undefined behavior during price comparisons. Changed to use std::optional<Decimal> for safe sentinel-free comparisons.
16 lines
412 B
Python
16 lines
412 B
Python
"""Venue adapters."""
|
|
|
|
from lx_trading.adapters.base import VenueAdapter, VenueCapabilities
|
|
from lx_trading.adapters.native import LxDexAdapter, LxAmmAdapter
|
|
from lx_trading.adapters.ccxt import CcxtAdapter
|
|
from lx_trading.adapters.hummingbot import HummingbotAdapter
|
|
|
|
__all__ = [
|
|
"VenueAdapter",
|
|
"VenueCapabilities",
|
|
"LxDexAdapter",
|
|
"LxAmmAdapter",
|
|
"CcxtAdapter",
|
|
"HummingbotAdapter",
|
|
]
|