2025.09.08
This commit is contained in:
parent
bc8d621152
commit
f5740c735c
|
|
@ -1,3 +1,6 @@
|
||||||
|
2025.09.08:
|
||||||
|
. Re-enabled long to short autoswitch.
|
||||||
|
|
||||||
2025.09.07:
|
2025.09.07:
|
||||||
. Increased wait time after sending market orders.
|
. Increased wait time after sending market orders.
|
||||||
|
|
||||||
|
|
|
||||||
2
main.py
2
main.py
|
|
@ -18,7 +18,7 @@ import exchange_wrapper
|
||||||
import trader
|
import trader
|
||||||
|
|
||||||
|
|
||||||
version = "2025.09.07"
|
version = "2025.09.09"
|
||||||
|
|
||||||
'''
|
'''
|
||||||
Color definitions. If you want to change them, check the reference at https://en.wikipedia.org/wiki/ANSI_escape_code#Colors
|
Color definitions. If you want to change them, check the reference at https://en.wikipedia.org/wiki/ANSI_escape_code#Colors
|
||||||
|
|
|
||||||
16
trader.py
16
trader.py
|
|
@ -1135,7 +1135,13 @@ class trader:
|
||||||
self.switch_to_long(already_received_quote=self.status.get_quote_spent())
|
self.switch_to_long(already_received_quote=self.status.get_quote_spent())
|
||||||
if not self.config.get_liquidate_after_switch():
|
if not self.config.get_liquidate_after_switch():
|
||||||
self.restart = True
|
self.restart = True
|
||||||
return 1
|
return 1
|
||||||
|
#Check for autoswitch (long->short)
|
||||||
|
if not self.config.get_is_short() and self.status.get_so_amount()==self.status.get_no_of_safety_orders() and self.config.get_autoswitch():
|
||||||
|
self.switch_to_short()
|
||||||
|
self.status.save_to_file(is_backup=True)
|
||||||
|
self.restart = True
|
||||||
|
return 0
|
||||||
|
|
||||||
#Extract ids from order list
|
#Extract ids from order list
|
||||||
self.status.set_pause_reason("filtering open orders")
|
self.status.set_pause_reason("filtering open orders")
|
||||||
|
|
@ -1262,14 +1268,6 @@ class trader:
|
||||||
self.pause = False
|
self.pause = False
|
||||||
self.update_status(True)
|
self.update_status(True)
|
||||||
|
|
||||||
#Check for autoswitch (long->short)
|
|
||||||
#Commented out because i'm not sure where this should go
|
|
||||||
#if not self.config.get_is_short() and self.status.get_so_amount()==self.status.get_no_of_safety_orders() and self.config.get_autoswitch():
|
|
||||||
# self.switch_to_short()
|
|
||||||
# self.status.save_to_file(is_backup=True)
|
|
||||||
# self.restart = True
|
|
||||||
# return 0
|
|
||||||
|
|
||||||
#Render status line(s)
|
#Render status line(s)
|
||||||
self.status.set_status_string(self.generate_status_strings())
|
self.status.set_status_string(self.generate_status_strings())
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue