lighter.constants
Documentation for eth_defi.lighter.constants Python module.
Constants for the Lighter integration.
Shared constants used across the Lighter modules
(daily_metrics,
vault_data_export, etc.).
Module Attributes
Synthetic in-house chain ID for Lighter (ZK-rollup, non-standard EVM). |
|
Lighter mainnet API base URL. |
|
Default rate limit for Lighter API requests per second. |
|
Pool denomination currency. |
|
Pool cooldown period for withdrawals. |
|
Set of Lighter system pool addresses (protocol-curated). |
- LIGHTER_CHAIN_ID: int = 9998
Synthetic in-house chain ID for Lighter (ZK-rollup, non-standard EVM).
Added to
eth_defi.chain.CHAIN_NAMESas9998: "Lighter".
- LIGHTER_DAILY_METRICS_DATABASE: pathlib.Path = PosixPath('/home/runner/.tradingstrategy/vaults/lighter-pools.duckdb')
Default path for Lighter daily metrics DuckDB database.
- LIGHTER_DEFAULT_REQUESTS_PER_SECOND: float = 2.0
Default rate limit for Lighter API requests per second.
Conservative estimate based on observed API behaviour.
- LIGHTER_POOL_FEE_MODE: eth_defi.vault.fee.VaultFeeMode = VaultFeeMode.internalised_skimming
Fee mode for Lighter native pools.
Pool operators can set an
operator_fee(0-100%). The share prices from the API already reflect the operator’s fee deduction, so the pipeline sees net-of-fees prices. This matches internalised skimming.
- LIGHTER_DENOMINATION: str = 'USDC'
Pool denomination currency.
Lighter uses USDC as the exchange base currency.
- LIGHTER_POOL_LOCKUP: datetime.timedelta = datetime.timedelta(seconds=300)
Pool cooldown period for withdrawals.
From
systemConfig.liquidity_pool_cooldown_period(300000ms = 5 minutes).
- LIGHTER_SYSTEM_POOL_ADDRESSES: set[str] = {'lighter-pool-281474976680784', 'lighter-pool-281474976710654'}
Set of Lighter system pool addresses (protocol-curated).
The LLP (Lighter Liquidity Pool) is the protocol’s own liquidity pool; the XLP (Experimental Liquidity Provider) is the protocol-run pool for experimental markets. Both are community-owned and protocol-operated. Uses the synthetic address format
lighter-pool-{account_index}.These are protocol-operated pools with special properties (no operator fee, not listed in
publicPoolsMetadata, fetched separately viasystemConfig). Useful for filtering protocol pools from user-created pools.