+
+
+ {(_) => {
+ const [reported, setReported] = createSignal(false)
+ return (
+
+ )
+ }}
+
{
+ return integrations.filter(
+ (i) =>
+ i.name !== "Breadcrumbs" && !(import.meta.env.OPENCODE_CHANNEL === "prod" && i.name === "GlobalHandlers"),
+ )
+ },
+ })
+}
+
void initI18n()
const deepLinkEvent = "opencode:deep-link"
diff --git a/packages/desktop/package.json b/packages/desktop/package.json
index ff81acaaf3..61ef5d05c3 100644
--- a/packages/desktop/package.json
+++ b/packages/desktop/package.json
@@ -15,6 +15,7 @@
"dependencies": {
"@opencode-ai/app": "workspace:*",
"@opencode-ai/ui": "workspace:*",
+ "@sentry/solid": "catalog:",
"@solid-primitives/i18n": "2.2.1",
"@solid-primitives/storage": "catalog:",
"@tauri-apps/api": "^2",
@@ -35,6 +36,7 @@
},
"devDependencies": {
"@actions/artifact": "4.0.0",
+ "@sentry/vite-plugin": "catalog:",
"@tauri-apps/cli": "^2",
"@types/bun": "catalog:",
"@typescript/native-preview": "catalog:",
diff --git a/packages/desktop/src/env.d.ts b/packages/desktop/src/env.d.ts
new file mode 100644
index 0000000000..aff0168422
--- /dev/null
+++ b/packages/desktop/src/env.d.ts
@@ -0,0 +1,9 @@
+interface ImportMetaEnv {
+ readonly VITE_SENTRY_DSN?: string
+ readonly VITE_SENTRY_ENVIRONMENT?: string
+ readonly VITE_SENTRY_RELEASE?: string
+}
+
+interface ImportMeta {
+ readonly env: ImportMetaEnv
+}
diff --git a/packages/desktop/src/index.tsx b/packages/desktop/src/index.tsx
index a760cb4091..1a0da014dd 100644
--- a/packages/desktop/src/index.tsx
+++ b/packages/desktop/src/index.tsx
@@ -14,6 +14,7 @@ import {
ServerConnection,
useCommand,
} from "@opencode-ai/app"
+import * as Sentry from "@sentry/solid"
import type { AsyncStorage } from "@solid-primitives/storage"
import { getCurrentWindow } from "@tauri-apps/api/window"
import { readImage } from "@tauri-apps/plugin-clipboard-manager"
diff --git a/packages/desktop/vite.config.ts b/packages/desktop/vite.config.ts
index 62c3a099ad..e8f8f8465d 100644
--- a/packages/desktop/vite.config.ts
+++ b/packages/desktop/vite.config.ts
@@ -15,9 +15,9 @@ export default defineConfig({
// Improves production stack traces
keepNames: true,
},
- // build: {
- // sourcemap: true,
- // },
+ build: {
+ sourcemap: true,
+ },
// 2. tauri expects a fixed port, fail if that port is not available
server: {
port: 1420,