Add separate kline.db and pre-seed small-account four-product K-lines on startup.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -13,9 +13,10 @@ import threading
|
||||
import time
|
||||
from typing import Any, Iterable, Optional, Sequence
|
||||
|
||||
from modules.core.paths import DB_PATH as _ROOT_DB_PATH
|
||||
from modules.core.paths import DB_PATH as _ROOT_DB_PATH, KLINE_DB_PATH as _KLINE_DB_PATH
|
||||
|
||||
DB_PATH = _ROOT_DB_PATH
|
||||
KLINE_DB_PATH = _KLINE_DB_PATH
|
||||
|
||||
_backend_lock = threading.Lock()
|
||||
_backend: Optional[str] = None
|
||||
|
||||
@@ -29,6 +29,7 @@ class AppDeps:
|
||||
start_background_threads: Callable
|
||||
tz: Any
|
||||
db_path: str
|
||||
kline_db_path: str
|
||||
upload_dir: str
|
||||
open_types: list
|
||||
exit_triggers: list
|
||||
|
||||
@@ -19,6 +19,7 @@ UPLOADS_DIR = ROOT / "uploads"
|
||||
LOGS_DIR = ROOT / "logs"
|
||||
|
||||
DB_PATH = str(ROOT / "futures.db")
|
||||
KLINE_DB_PATH = str(DATA_DIR / "kline.db")
|
||||
|
||||
|
||||
def ensure_runtime_dirs() -> None:
|
||||
|
||||
Reference in New Issue
Block a user