YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context
Rust agentsagiaiai-memoryaudio-recordingcomputer-visionhermeshermes-agentllmlocal-ailocal-firstmachine-learningmcpmultimodalopenclawprivacyrewindscreen-recordingspeech-to-textycombinator
fix: check publish response body for error field
Louis Beaumontad53dba08f31
diff --git a/apps/screenpipe-app-tauri/components/pipe-store.tsx b/apps/screenpipe-app-tauri/components/pipe-store.tsxindex 197cabdb2..151c32141 100644--- a/apps/screenpipe-app-tauri/components/pipe-store.tsx+++ b/apps/screenpipe-app-tauri/components/pipe-store.tsx@@ -1208,8 +1208,8 @@ function PublishDialog({category: publishCategory.toLowerCase(),}),});- if (!res.ok) {- const data = await res.json().catch(() => ({}));+ const data = await res.json().catch(() => ({}));+ if (!res.ok || data.error) {throw new Error(data.error || `HTTP ${res.status}`);}posthog.capture("pipe_published_to_store", { pipe: selectedPipe });@@ -1273,6 +1273,8 @@ function PublishDialog({onChange={(e) => setTitle(e.target.value)}placeholder="my awesome pipe"className="h-8 text-sm mt-1"+ spellCheck={false}+ autoCorrect="off"/></div><div>@@ -1282,6 +1284,8 @@ function PublishDialog({onChange={(e) => setDescription(e.target.value)}placeholder="what does this pipe do?"className="text-xs min-h-[60px] mt-1"+ spellCheck={false}+ autoCorrect="off"/></div><div className="flex gap-3">diff --git a/apps/screenpipe-app-tauri/lib/utils/tauri.ts b/apps/screenpipe-app-tauri/lib/utils/tauri.tsindex a6a336fa2..0710a04ae 100644--- a/apps/screenpipe-app-tauri/lib/utils/tauri.ts+++ b/apps/screenpipe-app-tauri/lib/utils/tauri.ts@@ -524,6 +524,19 @@ async removeSyncDevice(deviceId: string) : Promise<Result<null, string>> {else return { status: "error", error: e as any };}},+/**+ * Delete all locally-stored data that was synced from a specific remote device.+ * This calls the local screenpipe server's /data/delete-device endpoint.+ * Refuses to delete data for the current device as a safety guard.+ */+async deleteDeviceLocalData(machineId: string) : Promise<Result<string, string>> {+ try {+ return { status: "ok", data: await TAURI_INVOKE("delete_device_local_data", { machineId }) };+} catch (e) {+ if(e instanceof Error) throw e;+ else return { status: "error", error: e as any };+}+},/*** Initialize sync with password.* This initializes both the local SyncManager (for device queries) anddiff --git a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock b/apps/screenpipe-app-tauri/src-tauri/Cargo.lockindex 60b6e2a86..d2aa8a032 100644--- a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock+++ b/apps/screenpipe-app-tauri/src-tauri/Cargo.lock@@ -9329,7 +9329,7 @@ dependencies = [[[package]]name = "screenpipe-app"-version = "2.2.132"+version = "2.2.133"dependencies = ["anyhow","arboard",