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: broken add your own pipe,
Louis Beaumonta011a1ddbc24
diff --git a/examples/typescript/pipe-obsidian-time-logs/package.json b/examples/typescript/pipe-obsidian-time-logs/package.jsonindex 1635721da..4257ddfd8 100644--- a/examples/typescript/pipe-obsidian-time-logs/package.json+++ b/examples/typescript/pipe-obsidian-time-logs/package.json@@ -5,7 +5,7 @@"dependencies": {"zod": "^3.23.8","ai": "^4.0.9",- "ollama-ai-provider": "^0.1.0",+ "ollama-ai-provider": "^1.0.0","@ai-sdk/openai": "^1.0.5","@screenpipe/js": "^0.1.1"},diff --git a/screenpipe-app-tauri/components/pipe-store.tsx b/screenpipe-app-tauri/components/pipe-store.tsxindex 63ceb9c20..ff2cf09ef 100644--- a/screenpipe-app-tauri/components/pipe-store.tsx+++ b/screenpipe-app-tauri/components/pipe-store.tsx@@ -71,8 +71,7 @@ interface CorePipe {const corePipes: CorePipe[] = [{id: "pipe-for-loom",- description:- "generate looms from your screenpipe data",+ description: "generate looms from your screenpipe data",url: "https://github.com/mediar-ai/screenpipe/tree/main/examples/typescript/pipe-for-loom",},{@@ -218,7 +217,8 @@ const PipeDialog: React.FC = () => {const handleToggleEnabled = async (pipe: Pipe) => {if (pipe.id === "pipe-for-loom" && !pipe.enabled) {- const isSubscribed = localStorage.getItem('loom_pipe_subscribed') === 'true';+ const isSubscribed =+ localStorage.getItem("loom_pipe_subscribed") === "true";if (!isSubscribed) {toast({title: "Subscription required",@@ -288,32 +288,34 @@ const PipeDialog: React.FC = () => {if (newRepoUrl) {try {toast({- title: "Adding custom pipe",- description: "Please wait...",+ title: "adding custom pipe",+ description: "please wait...",+ });++ const response = await fetch(`http://localhost:3030/pipes/download`, {+ method: "POST",+ headers: {+ "Content-Type": "application/json",+ },+ body: JSON.stringify({ url: newRepoUrl }),});- const cmd = Command.sidecar("screenpipe", [- "pipe",- "download",- newRepoUrl,- "-o",- "json",- ]);- await cmd.execute();+ if (!response.ok) {+ throw new Error("failed to download pipe");+ }// refresh the pipe listawait fetchInstalledPipes();toast({- title: "Custom pipe added",- description:- "Your pipe has been successfully added. Screenpipe will restart with the new pipe.",+ title: "custom pipe added",+ description: "your pipe has been successfully added.",});} catch (error) {- console.error("Failed to add custom pipe:", error);+ console.error("failed to add custom pipe:", error);toast({- title: "Error adding custom pipe",- description: "Please check the URL and try again.",+ title: "error adding custom pipe",+ description: "please check the url and try again.",variant: "destructive",});} finally {@@ -404,7 +406,7 @@ const PipeDialog: React.FC = () => {} catch (error) {console.error("failed to delete pipe:", error);toast({- title: "error deleting pipe",+ title: "error deleting pipe",description: "please try again or check the logs for more information.",variant: "destructive",});@@ -434,8 +436,10 @@ const PipeDialog: React.FC = () => {<h2 className="text-2xl font-bold mb-2">{selectedPipe.id}</h2><div className="flex space-x-2 mb-4">- {selectedPipe.id === "pipe-for-loom" && !selectedPipe.enabled && !localStorage.getItem("loom_pipe_subscribed") ? (- <StripeSubscriptionButton+ {selectedPipe.id === "pipe-for-loom" &&+ !selectedPipe.enabled &&+ !localStorage.getItem("loom_pipe_subscribed") ? (+ <StripeSubscriptionButtononSubscriptionComplete={() => handleToggleEnabled(selectedPipe)}/>) : (@@ -825,7 +829,8 @@ const PipeDialog: React.FC = () => {or anything else you can imagine that help you get more out of yourrecordings.<br />- revenue from paid pipes goes directly to community contributors who maintain them.+ revenue from paid pipes goes directly to community contributors who+ maintain them.<br /><ahref="https://docs.screenpi.pe/docs/plugins"