bidir 2
This commit is contained in:
3
bot.py
3
bot.py
@@ -87,7 +87,7 @@ def on_trade(message: dict, orderman: OrderManager, state: StateManager):
|
|||||||
|
|
||||||
state.set_last_price(symbol, price)
|
state.set_last_price(symbol, price)
|
||||||
|
|
||||||
# 거래도
|
# 거래도 진행 // VALBZ와 VALE의 가격이 모두 존재할 때만 거래 시도
|
||||||
if symbol == "VALBZ" or symbol == "VALE":
|
if symbol == "VALBZ" or symbol == "VALE":
|
||||||
print(
|
print(
|
||||||
f"Current prices - VALBZ: {state.get_last_price('VALBZ')}, VALE: {state.get_last_price('VALE')}"
|
f"Current prices - VALBZ: {state.get_last_price('VALBZ')}, VALE: {state.get_last_price('VALE')}"
|
||||||
@@ -99,6 +99,7 @@ def on_trade(message: dict, orderman: OrderManager, state: StateManager):
|
|||||||
print("NONE")
|
print("NONE")
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
FEE = 10
|
FEE = 10
|
||||||
SZ = 10
|
SZ = 10
|
||||||
if p_vale + 1 < p_valbz - 1:
|
if p_vale + 1 < p_valbz - 1:
|
||||||
|
|||||||
Reference in New Issue
Block a user