diff --git a/cli.py b/cli.py index 01cf362..0930fe2 100644 --- a/cli.py +++ b/cli.py @@ -369,7 +369,7 @@ def cmd_dashboard(projects_dir=None, host=None, port=None): from dashboard import serve host = host or os.environ.get("HOST", "localhost") - port = int(port or os.environ.get("PORT", "8080")) + port = int(port or os.environ.get("PORT", "57832")) def open_browser(): time.sleep(1.0) diff --git a/dashboard.py b/dashboard.py index ebf8d5f..d1c8381 100644 --- a/dashboard.py +++ b/dashboard.py @@ -742,7 +742,7 @@ def get_dashboard_data(db_path=DB_PATH): // Hourly aggregation (filtered by model + range, then bucketed by UTC hour) const hourlySrc = (rawData.hourly_by_model || []).filter(r => - selectedModels.has(r.model) && (!cutoff || r.day >= cutoff) + selectedModels.has(r.model) && (!start || r.day >= start) && (!end || r.day <= end) ); const hourlyAgg = aggregateHourly(hourlySrc, hourlyTZ); @@ -1289,7 +1289,7 @@ def do_POST(self): def serve(host=None, port=None): host = host or os.environ.get("HOST", "localhost") - port = port or int(os.environ.get("PORT", "8080")) + port = port or int(os.environ.get("PORT", "57832")) server = HTTPServer((host, port), DashboardHandler) print(f"Dashboard running at http://{host}:{port}") print("Press Ctrl+C to stop.")