feat: allow skipping of the wallet migration
fallback method in case of problems
This commit is contained in:
@@ -283,6 +283,10 @@
|
|||||||
"month"
|
"month"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
"skip_wallet_history_migration": {
|
||||||
|
"description": "Disable wallet history migration.",
|
||||||
|
"type": "boolean"
|
||||||
|
},
|
||||||
"hyperopt_path": {
|
"hyperopt_path": {
|
||||||
"description": "Specify additional lookup path for Hyperopt Loss functions.",
|
"description": "Specify additional lookup path for Hyperopt Loss functions.",
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
|||||||
@@ -236,6 +236,10 @@ CONF_SCHEMA = {
|
|||||||
"type": "string",
|
"type": "string",
|
||||||
"enum": BACKTEST_CACHE_AGE,
|
"enum": BACKTEST_CACHE_AGE,
|
||||||
},
|
},
|
||||||
|
"skip_wallet_history_migration": {
|
||||||
|
"description": "Disable wallet history migration.",
|
||||||
|
"type": "boolean",
|
||||||
|
},
|
||||||
# Hyperopt
|
# Hyperopt
|
||||||
"hyperopt_path": {
|
"hyperopt_path": {
|
||||||
"description": "Specify additional lookup path for Hyperopt Loss functions.",
|
"description": "Specify additional lookup path for Hyperopt Loss functions.",
|
||||||
|
|||||||
@@ -16,7 +16,9 @@ logger = logging.getLogger(__name__)
|
|||||||
|
|
||||||
|
|
||||||
def migrate_wallet_history(config: Config, exchange: Exchange, starting_balance: float):
|
def migrate_wallet_history(config: Config, exchange: Exchange, starting_balance: float):
|
||||||
if not exchange.get_option("ohlcv_has_history", True):
|
if config.get("skip_wallet_history_migration") or not exchange.get_option(
|
||||||
|
"ohlcv_has_history", True
|
||||||
|
):
|
||||||
# we can't fill up wallet history without ohlcv history
|
# we can't fill up wallet history without ohlcv history
|
||||||
return
|
return
|
||||||
if KeyValueStore.get_int_value("wallet_history_migration"):
|
if KeyValueStore.get_int_value("wallet_history_migration"):
|
||||||
|
|||||||
Reference in New Issue
Block a user