fix(coding-agent): correct omp-stats subpath imports for tarball installs

This commit is contained in:
can1357
2026-02-21 16:59:37 +01:00
parent 737fc46d65
commit 643eb12df6
3 changed files with 5 additions and 4 deletions
+3 -3
View File
@@ -85,9 +85,9 @@ function formatPercent(n: number): string {
export async function runStatsCommand(cmd: StatsCommandArgs): Promise<void> {
// Lazy import to avoid loading stats module when not needed
const { getDashboardStats, syncAllSessions, getTotalMessageCount } = await import("@oh-my-pi/omp-stats");
const { startServer } = await import("@oh-my-pi/omp-stats/src/server");
const { closeDb } = await import("@oh-my-pi/omp-stats/src/db");
const { getDashboardStats, syncAllSessions, getTotalMessageCount, startServer, closeDb } = await import(
"@oh-my-pi/omp-stats"
);
// Sync session files first
console.log("Syncing session files...");
+2
View File
@@ -6,6 +6,8 @@ import { closeDb } from "./db";
import { startServer } from "./server";
export { getDashboardStats, getTotalMessageCount, syncAllSessions } from "./aggregator";
export { closeDb } from "./db";
export { startServer } from "./server";
export type {
AggregatedStats,
DashboardStats,
-1
View File
@@ -34,7 +34,6 @@
"@oh-my-pi/pi-natives": ["./packages/natives/src/index.ts"],
"@oh-my-pi/pi-natives/*": ["./packages/natives/src/*"],
"@oh-my-pi/omp-stats": ["./packages/stats/src/index.ts"],
"@oh-my-pi/omp-stats/src/*": ["./packages/stats/src/*"],
"@oh-my-pi/omp-stats/*": ["./packages/stats/src/*"],
"@oh-my-pi/pi-tui": ["./packages/tui/src/index.ts"],
"@oh-my-pi/pi-tui/*": ["./packages/tui/src/*"],