Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.
TypeScript agentaiai-agentsall-in-onecrmcrm-systememaillinearmcpmessagingnotesnotionofficerustslackslack-alternativestartupstartup-toolstypescriptworkspace
Sean/native cookie storage (#8631)
Sean Aye8908d6175223
diff --git a/apps/web/AGENTS.md b/apps/web/AGENTS.mdindex aa0522884b..5e02068239 100644--- a/apps/web/AGENTS.md+++ b/apps/web/AGENTS.md@@ -194,6 +194,7 @@ ownership. Cancel, logout, and the ten-minute timeout retire pending callbacks.- Passive PR mentions must not retry initial GitHub status failures on remount; preserve confirmed status through refetch errors and keep pending data reads out of their parent Suspense boundary.- Keep native booking exit navigation in the route shell, outside page loading boundaries, and use the router so the native hash route stays intact.- Diagnose native full reloads with `native_webview_started`, `native_diagnostic_recovered`, and the shared `frontend_instance_id`; use `reloadApp(reason)` for frontend reloads and keep breadcrumbs content-free. Treat `previous_document_*` checkpoints as last-observed lifecycle evidence, never a crash verdict; clear them on logout. `previous_document_last_*` comes from the native navigation breadcrumb (route and entity type, never ids). See [frontend checkpoints](docs/native-reload-diagnostics.md) and `tauri/src-tauri/README.md`.+- Pass `$APPLOCALDATA` (Application Support on Apple platforms) as the native HTTP cookie storage directory; the plugin owns the `.cookies` filename. Never use purgeable caches. The location change intentionally requires one new sign-in, without migration. See `tauri/src-tauri/README.md#native-authentication-cookies`.- Inline agent steps reuse the session code-execution query for live SDK operationnames; completed step snapshots come from the shared fold of the tool receipt.Session `ExecuteCode` activity uses the same Calling N tools peek window asdiff --git a/apps/web/tauri/Cargo.lock b/apps/web/tauri/Cargo.lockindex 2a624d67ee..24abab1708 100644--- a/apps/web/tauri/Cargo.lock+++ b/apps/web/tauri/Cargo.lock@@ -6940,7 +6940,7 @@ dependencies = [[[package]]name = "tauri-plugin-fs"version = "2.5.1"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["anyhow","dunce",@@ -6977,7 +6977,7 @@ dependencies = [[[package]]name = "tauri-plugin-http"version = "2.5.9"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["bytes","cookie_store",@@ -7189,7 +7189,7 @@ dependencies = [[[package]]name = "tauri-plugin-websocket"version = "2.4.2"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["futures-util","http",diff --git a/apps/web/tauri/desktop-cef/AGENTS.md b/apps/web/tauri/desktop-cef/AGENTS.mdindex 269e5f7232..1c9c0e3f7c 100644--- a/apps/web/tauri/desktop-cef/AGENTS.md+++ b/apps/web/tauri/desktop-cef/AGENTS.md@@ -51,6 +51,9 @@ thin binary over `../src-tauri` (`app_lib::run_with`) that selectsentitlements under the hardened runtime. Calls and dictation need its cameraand audio-input entitlements, plus the usage descriptions in`../src-tauri/icons/macos/Info.plist`; without either, macOS refuses capture.+- Keep the HTTP/WebSocket fork revision and Nix source hash aligned with the+ shared native workspace; native cookies use Application Support as documented+ in `../src-tauri/README.md#native-authentication-cookies`.- Keep `tauri.conf.json` aligned with `../src-tauri/tauri.conf.json` and`tauri.macos.conf.json`: the CLI bundles from this file, while the app'sruntime config still comes from `../src-tauri`.diff --git a/apps/web/tauri/desktop-cef/Cargo.lock b/apps/web/tauri/desktop-cef/Cargo.lockindex 97e47448f3..266dcf5f45 100644--- a/apps/web/tauri/desktop-cef/Cargo.lock+++ b/apps/web/tauri/desktop-cef/Cargo.lock@@ -7352,7 +7352,7 @@ dependencies = [[[package]]name = "tauri-plugin-fs"version = "2.5.1"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["anyhow","dunce",@@ -7389,7 +7389,7 @@ dependencies = [[[package]]name = "tauri-plugin-http"version = "2.5.9"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["bytes","cookie_store",@@ -7601,7 +7601,7 @@ dependencies = [[[package]]name = "tauri-plugin-websocket"version = "2.4.2"-source = "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca"+source = "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1"dependencies = ["futures-util","http",diff --git a/apps/web/tauri/src-tauri/Cargo.toml b/apps/web/tauri/src-tauri/Cargo.tomlindex b6ab1a8f20..d6bf5d701a 100644--- a/apps/web/tauri/src-tauri/Cargo.toml+++ b/apps/web/tauri/src-tauri/Cargo.toml@@ -48,15 +48,15 @@ serde_qs = "0.15.0"tauri = { workspace = true, features = ["devtools", "protocol-asset"] }tauri-plugin-deep-link = "=2.4.5"tokio-util = { version = "0.7", features = ["io"] }-# seanaye/feat/ws-replay-buffer; keep both plugin revs identical, and keep the-# TauriMessage/ReplayEnvelope types in+# sean/cookie-store-path includes ws-replay-buffer. Keep both plugin revs identical+# and the TauriMessage/ReplayEnvelope types in# packages/collaboration/src/websocket/platform/tauri-websocket.ts in sync when bumping-tauri-plugin-http = { git = "https://github.com/macro-inc/plugins-workspace", rev = "06474e4c446600627cf37a11f0c22c27bcf764ca", features = [+tauri-plugin-http = { git = "https://github.com/macro-inc/plugins-workspace", rev = "bc6ec3b8e80eed80ef4969f4463a357d46adb3b1", features = ["unsafe-headers",] }tauri-plugin-log = { version = "2", features = ["tracing"] }tauri-plugin-opener = "2"-tauri-plugin-websocket = { git = "https://github.com/macro-inc/plugins-workspace", rev = "06474e4c446600627cf37a11f0c22c27bcf764ca" }+tauri-plugin-websocket = { git = "https://github.com/macro-inc/plugins-workspace", rev = "bc6ec3b8e80eed80ef4969f4463a357d46adb3b1" }thiserror = "2.0.14"tokio = { version = "1.47.1", features = ["full"] }tracing = { workspace = true }diff --git a/apps/web/tauri/src-tauri/README.md b/apps/web/tauri/src-tauri/README.mdindex 4c39c9aba1..4b5217e782 100644--- a/apps/web/tauri/src-tauri/README.md+++ b/apps/web/tauri/src-tauri/README.md@@ -5,6 +5,21 @@ single Vite build that runs identically for web, desktop, iOS, and Android — tplatform is detected at runtime via `getPlatform()` rather than baked into thebundle.+## Native authentication cookies++The native HTTP plugin stores its cookie jar at `$APPLOCALDATA/.cookies`, which+resolves to `Library/Application Support/<bundle-identifier>/.cookies` on iOS+and macOS. Keep credentials out of `$APPCACHE`: iOS may purge that directory+under storage pressure. The same native jar supplies HTTP and WebSocket cookies;+this is separate from the WebView's browser storage.++Macro passes `$APPLOCALDATA` to the plugin fork's `init_with_cookie_store_dir`;+the plugin owns the `.cookies` filename within that directory. Its default+`init()` still uses the cache directory. Macro deliberately does not migrate+the old cache file, so the first launch after this native update requires+sign-in again. Cookie expiry, refresh, and write behavior are unchanged. This+requires a native app release; an OTA frontend bundle cannot relocate the jar.+## File saving and sharingThe optional `file_export_plugin` registers iOS save/share commands. The webdiff --git a/apps/web/tauri/src-tauri/src/lib.rs b/apps/web/tauri/src-tauri/src/lib.rsindex e0e897ab98..2dc24919a2 100644--- a/apps/web/tauri/src-tauri/src/lib.rs+++ b/apps/web/tauri/src-tauri/src/lib.rs@@ -286,7 +286,9 @@ pub fn run_with(builder: tauri::Builder<AppRuntime>) {.plugin(tauri_plugin_notification::init()).plugin(tauri_plugin_os::init()).plugin(tauri_plugin_device_info::init())- .plugin(tauri_plugin_http::init())+ .plugin(tauri_plugin_http::init_with_cookie_store_dir(+ "$APPLOCALDATA",+ )).plugin(tauri_plugin_websocket::Builder::new().merge_header_callback(Box::new(merge_header_callback))diff --git a/nix/tauri-desktop.nix b/nix/tauri-desktop.nixindex 486626cf9e..3d838b9b5e 100644--- a/nix/tauri-desktop.nix+++ b/nix/tauri-desktop.nix@@ -303,8 +303,8 @@outputHashes = {"git+https://github.com/macro-inc/tauri-plugins?rev=6ddd6600e20436388f169e936b610fe93944b7b0#6ddd6600e20436388f169e936b610fe93944b7b0" ="sha256-5ErLW2po5ZlTTuJjsCExwC//rHYcQo2tKXiyz3w/0kQ=";- "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca" =- "sha256-ngH5sltERe8DlP/zjsin9jmlGOZFeABk8SxJ5AnZG18=";+ "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1" =+ "sha256-IdhZM/B8EyC/4/3HxQjkzNkrJeA68+43+rKity+iGLY=";"git+https://github.com/tursodatabase/turso?rev=79163249538197d01dec5ea7f65519454ed792e2#79163249538197d01dec5ea7f65519454ed792e2" ="sha256-7Noz7RMN+4nhlU5BBLzxZZ53nNFGewrr8BFMO1adkCo=";"git+https://github.com/seanaye/tauri?rev=95a7521b#95a7521b8c565cfba568319ddd8ba79c9ce244e2" =@@ -862,8 +862,8 @@src = ../apps/web/tauri/desktop-cef;cargoLock = ../apps/web/tauri/desktop-cef/Cargo.lock;outputHashes = {- "git+https://github.com/macro-inc/plugins-workspace?rev=06474e4c446600627cf37a11f0c22c27bcf764ca#06474e4c446600627cf37a11f0c22c27bcf764ca" =- "sha256-ngH5sltERe8DlP/zjsin9jmlGOZFeABk8SxJ5AnZG18=";+ "git+https://github.com/macro-inc/plugins-workspace?rev=bc6ec3b8e80eed80ef4969f4463a357d46adb3b1#bc6ec3b8e80eed80ef4969f4463a357d46adb3b1" =+ "sha256-IdhZM/B8EyC/4/3HxQjkzNkrJeA68+43+rKity+iGLY=";"git+https://github.com/macro-inc/tauri-plugins?rev=6ddd6600e20436388f169e936b610fe93944b7b0#6ddd6600e20436388f169e936b610fe93944b7b0" ="sha256-5ErLW2po5ZlTTuJjsCExwC//rHYcQo2tKXiyz3w/0kQ=";"git+https://github.com/macro-inc/tauri?rev=285fb6b1#285fb6b1cb2fc20666da1688f4c74e240a100035" =