@vm0/cli 1.3.1 → 1.4.0
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/index.js +16 -23
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -12936,31 +12936,23 @@ async function pollEvents(runId) {
|
|
|
12936
12936
|
);
|
|
12937
12937
|
throw new Error("Agent execution timed out");
|
|
12938
12938
|
}
|
|
12939
|
-
|
|
12940
|
-
|
|
12941
|
-
|
|
12942
|
-
|
|
12943
|
-
|
|
12944
|
-
|
|
12945
|
-
|
|
12946
|
-
|
|
12947
|
-
|
|
12948
|
-
|
|
12949
|
-
|
|
12950
|
-
complete = true;
|
|
12951
|
-
}
|
|
12939
|
+
const response = await apiClient.getEvents(runId, {
|
|
12940
|
+
since: nextSequence
|
|
12941
|
+
});
|
|
12942
|
+
for (const event of response.events) {
|
|
12943
|
+
const parsed = ClaudeEventParser.parse(
|
|
12944
|
+
event.eventData
|
|
12945
|
+
);
|
|
12946
|
+
if (parsed) {
|
|
12947
|
+
EventRenderer.render(parsed);
|
|
12948
|
+
if (parsed.type === "vm0_result" || parsed.type === "vm0_error") {
|
|
12949
|
+
complete = true;
|
|
12952
12950
|
}
|
|
12953
12951
|
}
|
|
12954
|
-
|
|
12955
|
-
|
|
12956
|
-
|
|
12957
|
-
|
|
12958
|
-
} catch (error43) {
|
|
12959
|
-
console.error(
|
|
12960
|
-
chalk4.red("\u2717 Failed to poll events:"),
|
|
12961
|
-
error43 instanceof Error ? error43.message : "Unknown error"
|
|
12962
|
-
);
|
|
12963
|
-
throw error43;
|
|
12952
|
+
}
|
|
12953
|
+
nextSequence = response.nextSequence;
|
|
12954
|
+
if (response.events.length === 0 && !complete) {
|
|
12955
|
+
await new Promise((resolve) => setTimeout(resolve, pollIntervalMs));
|
|
12964
12956
|
}
|
|
12965
12957
|
}
|
|
12966
12958
|
}
|
|
@@ -13243,6 +13235,7 @@ var pushCommand = new Command4().name("push").description("Push local files to c
|
|
|
13243
13235
|
}
|
|
13244
13236
|
const result = await response.json();
|
|
13245
13237
|
console.log(chalk6.green("\u2713 Upload complete"));
|
|
13238
|
+
console.log(chalk6.gray(` Version: ${result.versionId}`));
|
|
13246
13239
|
console.log(chalk6.gray(` Files: ${result.fileCount.toLocaleString()}`));
|
|
13247
13240
|
console.log(chalk6.gray(` Size: ${formatBytes(result.size)}`));
|
|
13248
13241
|
} catch (error43) {
|