mirror of
https://github.com/aljazceru/bitfinex-api-py.git
synced 2025-12-19 14:54:21 +01:00
Install and configure pylint. Add pylint to dev-requirements.txt. Start rewriting code to follow pylint's linting rules.
This commit is contained in:
@@ -7,9 +7,9 @@ from bfxapi.enums import Error, OrderType
|
||||
from bfxapi.websocket.types import Notification, Order
|
||||
|
||||
bfx = Client(
|
||||
WSS_HOST=WSS_HOST,
|
||||
API_KEY=os.getenv("BFX_API_KEY"),
|
||||
API_SECRET=os.getenv("BFX_API_SECRET")
|
||||
wss_host=WSS_HOST,
|
||||
api_key=os.getenv("BFX_API_KEY"),
|
||||
api_secret=os.getenv("BFX_API_SECRET")
|
||||
)
|
||||
|
||||
@bfx.wss.on("wss-error")
|
||||
|
||||
@@ -7,9 +7,9 @@ from bfxapi.enums import Error
|
||||
from bfxapi.websocket.types import List, Wallet
|
||||
|
||||
bfx = Client(
|
||||
API_KEY=os.getenv("BFX_API_KEY"),
|
||||
API_SECRET=os.getenv("BFX_API_SECRET"),
|
||||
filter=["wallet"]
|
||||
api_key=os.getenv("BFX_API_KEY"),
|
||||
api_secret=os.getenv("BFX_API_SECRET"),
|
||||
filters=["wallet"]
|
||||
)
|
||||
|
||||
@bfx.wss.on("wss-error")
|
||||
|
||||
@@ -6,7 +6,7 @@ from bfxapi.websocket.types import DerivativesStatus
|
||||
|
||||
from bfxapi.websocket import subscriptions
|
||||
|
||||
bfx = Client(WSS_HOST=PUB_WSS_HOST)
|
||||
bfx = Client(wss_host=PUB_WSS_HOST)
|
||||
|
||||
@bfx.wss.on("derivatives_status_update")
|
||||
def on_derivatives_status_update(subscription: subscriptions.Status, data: DerivativesStatus):
|
||||
|
||||
@@ -38,7 +38,7 @@ SYMBOLS = [ "tBTCUSD", "tLTCUSD", "tLTCBTC", "tETHUSD", "tETHBTC" ]
|
||||
|
||||
order_book = OrderBook(symbols=SYMBOLS)
|
||||
|
||||
bfx = Client(WSS_HOST=PUB_WSS_HOST)
|
||||
bfx = Client(wss_host=PUB_WSS_HOST)
|
||||
|
||||
@bfx.wss.on("wss-error")
|
||||
def on_wss_error(code: Error, msg: str):
|
||||
|
||||
@@ -38,7 +38,7 @@ SYMBOLS = [ "tBTCUSD", "tLTCUSD", "tLTCBTC", "tETHUSD", "tETHBTC" ]
|
||||
|
||||
raw_order_book = RawOrderBook(symbols=SYMBOLS)
|
||||
|
||||
bfx = Client(WSS_HOST=PUB_WSS_HOST)
|
||||
bfx = Client(wss_host=PUB_WSS_HOST)
|
||||
|
||||
@bfx.wss.on("wss-error")
|
||||
def on_wss_error(code: Error, msg: str):
|
||||
|
||||
@@ -6,7 +6,7 @@ from bfxapi.websocket import subscriptions
|
||||
from bfxapi.websocket.enums import Channel
|
||||
from bfxapi.websocket.types import TradingPairTicker
|
||||
|
||||
bfx = Client(WSS_HOST=PUB_WSS_HOST)
|
||||
bfx = Client(wss_host=PUB_WSS_HOST)
|
||||
|
||||
@bfx.wss.on("t_ticker_update")
|
||||
def on_t_ticker_update(subscription: subscriptions.Ticker, data: TradingPairTicker):
|
||||
|
||||
@@ -6,7 +6,7 @@ from bfxapi.websocket.types import Candle, TradingPairTrade
|
||||
|
||||
from bfxapi.websocket import subscriptions
|
||||
|
||||
bfx = Client(WSS_HOST=PUB_WSS_HOST)
|
||||
bfx = Client(wss_host=PUB_WSS_HOST)
|
||||
|
||||
@bfx.wss.on("candles_update")
|
||||
def on_candles_update(subscription: subscriptions.Candles, candle: Candle):
|
||||
|
||||
Reference in New Issue
Block a user