Fix metrics.json path to persistent data volume (/app/data)
All checks were successful
Build and Deploy MoneyMaker / build-and-deploy (push) Successful in 12m21s

This commit is contained in:
Henrik Jess Nielsen
2026-05-28 13:42:36 +02:00
parent 6a407cf216
commit 026b470b31
2 changed files with 2 additions and 2 deletions

View File

@@ -83,7 +83,7 @@ ALERT_THRESHOLD = 0.35 # signal_score > this → alert
# Claude metrics # Claude metrics
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
METRICS_FILE = Path(__file__).parent / "metrics.json" METRICS_FILE = Path(os.getenv("DATA_DIR", str(Path(__file__).parent / "data"))) / "metrics.json"
# Pricing: Claude 3 Haiku — https://www.anthropic.com/pricing # Pricing: Claude 3 Haiku — https://www.anthropic.com/pricing
_PRICE_INPUT_PER_TOKEN = 0.25 / 1_000_000 # $0.25 per MTok _PRICE_INPUT_PER_TOKEN = 0.25 / 1_000_000 # $0.25 per MTok

View File

@@ -28,7 +28,7 @@ from report import _c25_day_return, _unrealised_pnl, _realised_pnl, _total_fees,
CAPITAL = 10_000 CAPITAL = 10_000
LOG_DIR = Path(os.getenv("LOG_DIR", str(Path(__file__).parent / "logs"))) LOG_DIR = Path(os.getenv("LOG_DIR", str(Path(__file__).parent / "logs")))
METRICS_FILE = Path(__file__).parent / "metrics.json" METRICS_FILE = Path(os.getenv("DATA_DIR", str(Path(__file__).parent / "data"))) / "metrics.json"
REFRESH = 60 # seconds REFRESH = 60 # seconds
app = Flask(__name__) app = Flask(__name__)