@freqhole/api-client 0.2.8 → 0.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -94,12 +94,19 @@ export class CharnelLocalTransport implements Transport {
|
|
|
94
94
|
}
|
|
95
95
|
}
|
|
96
96
|
|
|
97
|
+
// temporary boot-timing instrumentation (see slow-tauri-boot investigation) —
|
|
98
|
+
// logs elapsed ms per IPC round-trip so a slow "loading..." screen can be
|
|
99
|
+
// narrowed down to a specific api call instead of guessing.
|
|
100
|
+
const requestStart = performance.now();
|
|
97
101
|
try {
|
|
98
102
|
// call dispatch via IPC
|
|
99
103
|
const response = (await inv("api_call", {
|
|
100
104
|
path,
|
|
101
105
|
body: jsonBody,
|
|
102
106
|
})) as ApiResponse;
|
|
107
|
+
console.info(
|
|
108
|
+
`[perf] api_call ${path} took ${(performance.now() - requestStart).toFixed(1)}ms`,
|
|
109
|
+
);
|
|
103
110
|
|
|
104
111
|
// check for route_not_found - this is now a real error
|
|
105
112
|
const errorType = response.errors?.[0]?.error_type;
|
|
@@ -127,6 +134,9 @@ export class CharnelLocalTransport implements Transport {
|
|
|
127
134
|
};
|
|
128
135
|
}
|
|
129
136
|
} catch (err) {
|
|
137
|
+
console.info(
|
|
138
|
+
`[perf] api_call ${path} failed after ${(performance.now() - requestStart).toFixed(1)}ms`,
|
|
139
|
+
);
|
|
130
140
|
// IPC error - treat as network error
|
|
131
141
|
return {
|
|
132
142
|
status: 0,
|
package/src/codegen/schema.ts
CHANGED
|
@@ -2429,6 +2429,7 @@ export const FeedItemSchema = z.object({
|
|
|
2429
2429
|
target_type: z.string().nullish(),
|
|
2430
2430
|
session_id: z.string().nullish(),
|
|
2431
2431
|
session_type: z.string().nullish(),
|
|
2432
|
+
entity_id: z.string().nullish(),
|
|
2432
2433
|
session_status: z.string().nullish(),
|
|
2433
2434
|
progress_percent: z.number().nullish(),
|
|
2434
2435
|
songs_completed: z.number().nullish(),
|
|
@@ -2494,6 +2495,7 @@ export const FeedResponseSchema = z.object({
|
|
|
2494
2495
|
target_type: z.string().nullish(),
|
|
2495
2496
|
session_id: z.string().nullish(),
|
|
2496
2497
|
session_type: z.string().nullish(),
|
|
2498
|
+
entity_id: z.string().nullish(),
|
|
2497
2499
|
session_status: z.string().nullish(),
|
|
2498
2500
|
progress_percent: z.number().nullish(),
|
|
2499
2501
|
songs_completed: z.number().nullish(),
|