AI Settings:
- Remove External Agents section, add dedicated Codex/Claude Code sections
with auto-detection and manual path override
- Add OpenRouter model list auto-fetch with searchable dropdown
- Remove standalone Default Model section, integrate into provider cards
- Provider toggle now acts as mutual-exclusive active selector
- Add cross-window state sync via storage events
- Add ErrorBoundary around AI tab for graceful error handling
Catty Agent fixes:
- Fix streaming: use .chat() instead of default Responses API, use
getReader() pattern instead of for-await, handle text-delta/text chunk
types correctly per SDK v6
- Fix API key: decrypt encrypted key before passing to SDK
- Fix terminal_execute: use PTY stream (visible in terminal) with MCP
markers instead of invisible SSH exec channel
- Fix multi-turn: only pass user/assistant text history, skip tool
messages to avoid SDK schema validation errors
- Fix tool result display: create new assistant message after tool
results so follow-up text renders correctly
Other:
- Add netcatty:ai:resolve-cli IPC handler for CLI path validation
- Remove Gemini from agent discovery (only Codex + Claude Code)
- Fix lint errors across ChatInput, TerminalLayer, SettingsAITab
- Strip MCP markers from tool execution stdout
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add image paste/drop support with base64 encoding and chat display
- Add + button popover (Files, Image, Mention Host) with @ auto-complete
- Add model selector with Codex thinking level sub-menus (GPT 5.4, Codex 5.x, o3/o4-mini)
- Switch Claude Code to ACP protocol; remove CLAUDE_CONFIG_DIR isolation
- Filter PTY exec markers in preload data pipe (precise regex, preserves command echo)
- Increase PTY exec timeout to 5min with Ctrl+C cancellation on abort
- Fix tool call loading spinner (only animate during active streaming)
- Reset active session on terminal/workspace switch
- Add AI sparkle button in top bar to toggle AI panel
- Display user-attached images in chat message list
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Create netcatty-remote-hosts MCP server (TCP bridge + stdio child process)
exposing terminal_execute, sftp_*, get_environment tools to ACP agents
- Execute commands via PTY stream with self-erasing markers for terminal
visibility; disable pagers automatically; 60s timeout fallback
- Inject MCP server into both Codex (ACP) and Claude Code (ACP) sessions
- Add model selector popover with hardcoded presets for Claude (Opus/Sonnet/
Haiku) and Codex (GPT 5.4, Codex 5.3/5.2/5.1, o3/o4-mini) with thinking
level sub-menus
- Fix multi-step tool call message flow (mutable flag instead of stale closure)
- Remove CLAUDE_CONFIG_DIR isolation to fix Claude auth; switch Claude to ACP
- Add startup cleanup for orphaned AI sessions
- Guard collectSessionIds against undefined workspace tree
- Remove permission mode chip from chat input
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Switching agent deactivates current session, next message creates a new one
- Filter history sessions by both scopeType and targetId
- Restore agent selector when resuming a historical session
- Auto-cleanup AI sessions when terminal/workspace instances are destroyed
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Integrate Claude Agent SDK for direct streaming chat, add Codex login/logout
flow with OAuth support in settings, improve AI chat panel UI and agent
discovery, and update build config for new dependencies.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add auto-discovery of CLI agents (Claude Code, Codex, Gemini) from system PATH
- Integrate ACP (Agent Client Protocol) for real-time streaming with codex-acp
- Bundle @zed-industries/codex-acp binary for reliable agent spawning
- Add ThinkingBlock component with shimmer animation and auto-collapse
- Refactor chat UI: no avatars, bordered user bubbles, plain assistant text
- Support {prompt} placeholder in agent args for flexible invocation
- Add persistent ACP sessions with proper cleanup on app exit
- Detect auth errors and show actionable messages to users
- Fallback to raw process spawn for agents without ACP support
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace native title attributes with Radix UI Tooltip components for
a consistent, styled tooltip experience across both toolbars.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add a position toggle button next to the close button in the side panel
header. The position preference is persisted in localStorage.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Allow users to bypass TLS certificate verification for WebDAV endpoints
using self-signed certificates, which is common for LAN NAS devices
(Synology, FNAS, Unraid, etc.).
Closes#332
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
## Summary
- Add SFTP side panel with workspace-level connection caching for instant switching between terminal endpoints
- Responsive toolbar with overflow menu that collapses action buttons when panel is narrow, prioritizing breadcrumb path display
- Silent terminal CWD detection via separate SSH exec channel (no visible commands in terminal)
- Extract SftpTransferQueue as reusable component with i18n support
- Remove passphrase from port forwarding credentials (decrypted at load time)
- Add compressed upload support to uploadEntriesDirect
- Fix various eslint warnings and code quality issues
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Resolve conflict in useAutoSync.ts by integrating getEffectiveKnownHosts
into the refactored getSyncSnapshot function, avoiding duplication in
getDataHash which now delegates to getSyncSnapshot.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat(sync): include snippetPackages in cloud sync payload (#315)
Snippet packages (the grouping tree for code snippets) were not included
in the cloud sync payload, causing them to be lost when syncing across
devices. This adds snippetPackages as an optional field following the
same backward-compatible pattern used by knownHosts and
portForwardingRules: old payloads that lack the field leave local
packages untouched.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: make snippetPackages optional in SyncableVaultData for consistency
Aligns with the pattern used by knownHosts — optional in both
SyncableVaultData and SyncPayload so that legacy data without the field
is handled gracefully. Also updates the SyncPayloadImporters docstring.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
- Handle { checking: true } response from bridge.checkForUpdate()
separately instead of treating it as "no update" — an in-flight
check will resolve via IPC events
- Restore dismissUpdate() in "View in Settings" toast onClick so
unsupported-platform users can suppress the notification; on
supported platforms the Settings window picks up download state
via IPC events independently
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Set dismissedAutoDownloadRef when hydration skips a dismissed version
so subsequent IPC events (progress/downloaded) are also suppressed
- When GitHub API fails but electron-updater fallback finds no update,
clear manualCheckStatus from 'error' to 'up-to-date' instead of
leaving Settings stuck in error state
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When checkNow's GitHub API call fails (blocked/rate-limited), still
trigger electron-updater's checkForUpdate as a fallback. This restores
the update path for environments where api.github.com is unreachable
but the updater feed is still accessible.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Remove STORAGE_KEY_UPDATE_LAST_CHECK write from onUpdateNotAvailable
handler — it would prevent the GitHub API fallback from running on app
restart, hiding releases that exist on GitHub but aren't yet in the
electron-updater feed. Let performCheck write the timestamp instead.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Don't cancel startup GitHub API fallback when electron-updater says
not-available — the GitHub release may exist before updater feed
assets are published, and the fallback provides manual download link
- Rescheduled fallback now re-queries getUpdateStatus to avoid duplicate
notifications on very slow networks
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Replace autoDownloadStatus==='idle' guard in progress/downloaded/error
callbacks with a dedicated dismissedAutoDownloadRef to distinguish
"dismissed version" from "not hydrated yet" in late-opening windows
- Don't clear hasUpdate on update-not-available — GitHub release may
exist even when electron-updater feed says no compatible update,
preserving the manual download fallback path
- Reset dismissedAutoDownloadRef on manual retry via checkNow
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- When the startup fallback sees the main process check still in flight,
reschedule after 5s instead of permanently skipping — handles the case
where the auto-check fails silently (check-phase errors not broadcast)
- onUpdateNotAvailable: clear hasUpdate and manualCheckStatus to remove
stale "update available" state from earlier GitHub API checks, since
the updater feed is authoritative on supported platforms
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- checkNow: check dismissed version before marking status as 'available'
to prevent re-downloading a release the user explicitly skipped
- startAutoCheck: verify updater exists before setting _isChecking flag
to avoid permanent stuck state when electron-updater fails to load
- Clear _isChecking in all catch paths to prevent stuck state
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add _isChecking flag in autoUpdateBridge to track whether
checkForUpdates is in flight; return sentinel when manual check
arrives during an active auto-check instead of starting a concurrent
call that electron-updater would reject
- Include isChecking in getUpdateStatus snapshot so the renderer can
query it before starting the GitHub API fallback
- Startup fallback now checks getUpdateStatus().isChecking to skip
when electron-updater is still checking on slow networks
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Store startAutoCheck timer ID so it can be cancelled; cancel it when
the renderer triggers a manual checkForUpdate to avoid concurrent
electron-updater calls that produce false errors
- Record lastCheckedAt and STORAGE_KEY_UPDATE_LAST_CHECK when
update-not-available fires so the throttle works on the common
no-update path and "Last checked" UI shows correctly
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Broadcast 'update-not-available' from electron-updater to renderer so
the startup GitHub API check is cancelled when no update exists
- Cancel pending startup timeout in checkNow() to prevent racing with
electron-updater's startAutoCheck (concurrent calls cause false errors)
- Add onUpdateNotAvailable bridge event (preload + global.d.ts types)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- getUpdateStatus hydration: skip restoring download state for dismissed
versions so late-opening windows don't show dismissed release UI
- performCheck: only advance lastCheck timestamp and cache release data
on successful checks — failed checks no longer suppress re-checks for
an hour while leaving stale cached release visible
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- onUpdateAvailable: skip autoDownloadStatus→'downloading' transition when
version is dismissed, preventing download progress/ready toasts
- onUpdateAvailable: cancel pending startup GitHub API check timeout to
eliminate race where electron-updater is still checking at 8s
- onUpdateDownloadProgress/Downloaded/Error: suppress state transitions
when autoDownloadStatus is 'idle' (dismissed version background download)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Return idle instead of up-to-date for dev/invalid builds in
checkNow to avoid false positive status
- Replace stale cached release in getUpdateStatus hydration when
the snapshot reports a different version
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Use semantic version comparison for cached release hydration to
avoid false positives when running a newer build than latest release
- Restore dismissUpdate() in startup toast so unsupported-platform
users can silence repeated notifications
- Remove dismissed-version check from ready-to-install toast since
dismissing availability should not block the install prompt
- Show manual download link in Settings on check errors too
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Persist latestRelease to localStorage so windows opened after the
initial check can hydrate release info without re-fetching
- Remove dismissUpdate() from "View in Settings" toast click — the
dismissed version key was preventing the later install-ready toast
- Hydrate cached release data when startup check is throttled so
Settings windows show the already-found update
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Don't treat unsupported auto-update platforms as download errors;
keep autoDownloadStatus at idle so manual download link shows
- Remove auto-check on SettingsApplicationTab mount to avoid
implicitly triggering downloads when opening Settings
- Update Application tab badge to reflect download/ready state
instead of always showing "Download Now"
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Replace stale latestRelease when electron-updater reports a different
version than the cached GitHub API result
- Surface checkForUpdate() failures by setting autoDownloadStatus to
error instead of silently dropping them
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove hasUpdate gate from ready-to-install toast so dismissing
availability notification doesn't prevent restart prompt
- Only open releases page on platforms without auto-download
- Increase startup check delay to 8s to let electron-updater fire first
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Skip renderer's GitHub API startup check if electron-updater's
auto-download has already started, preventing duplicate toast
notifications for the same release
- Set hasUpdate in onUpdateAvailable IPC handler, checking dismissed
version so that dismissed releases don't trigger the persistent
"restart now" toast after auto-download completes
- Guard "ready to install" toast with hasUpdate check
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix autoDownloadStatusRef stale read during checkNow retry: eagerly
sync the ref when resetting error->idle so checkForUpdate() fires
- Refactor SettingsApplicationTab to accept update props instead of
creating its own useUpdateCheck instance, preventing duplicate checks
and inconsistent state between Application and System tabs
- Show startup-detected updates (hasUpdate) in System tab, not only
manualCheckStatus=available, so Linux/unsupported platforms see the
update and manual download button
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add getUpdateStatus IPC handler so windows opened after download started
can immediately reflect the current state instead of showing stale 'idle'
- Track _lastStatus in main process across all updater events
- Hydrate autoDownloadStatus on useUpdateCheck mount via getUpdateStatus()
- Fix toast race: use ref to track previous autoDownloadStatus so ready/error
toasts only fire on actual status transitions, not when unrelated callback
references change
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
performCheck returns a non-null UpdateCheckResult with error populated
on GitHub API/network failures. Extend the status derivation to treat
result.error as an error state instead of falling through to up-to-date.
P1: change checkNow return type from Promise<null> to Promise<UpdateCheckResult | null>
and return actual result so callers can read hasUpdate/latestRelease.
P2: reset autoDownloadStatus from 'error' to 'idle' when user triggers manual
check, enabling a retry path; also show Check for Updates button in error state.
- Fix 1: when manual check finds update and electron-updater hasn't started
downloading yet (autoDownloadStatus=idle), fire-and-forget checkForUpdate()
to kick off the auto-download pipeline without blocking the UI
- Fix 2: manualCheckStatus='up-to-date' now auto-resets to 'idle' after 5s
so the badge doesn't stay stale until the next check; any new check cancels
the pending timer first
- Fix 3: SettingsSystemTab shows "last checked: X min ago" below the update
section using lastCheckedAt from updateState; new i18n keys added for both
zh-CN and en locales (lastCheckedJustNow, lastCheckedMinutesAgo,
lastCheckedHoursAgo, lastCheckedPrefix)
Internal: add autoDownloadStatusRef and manualCheckResetTimeoutRef to
useUpdateCheck for reliable cross-closure state access and timer lifecycle.
* fix(sftp): update currentPath immediately on navigation to prevent stale upload target
When navigating directories without a cache hit, currentPath was only
updated after the async file listing completed. If a drag-and-drop upload
occurred during or shortly after this window, getActivePane would return
the old currentPath, causing files to upload to the previous directory.
Now currentPath is updated immediately when loading begins, ensuring
upload operations always target the correct directory.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): revert currentPath to previous value when navigation fails
Address review feedback: if the directory listing throws a non-session
error, restore currentPath to its previous value so later operations
(e.g. uploads) don't target a path that was never successfully loaded.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): clear files when entering loading state to prevent stale interactions
Address P1 review: the loading overlay is pointer-events-none, so users
could still interact with old files during navigation. Since currentPath
is now updated immediately, actions like delete/rename would resolve
against the new path but display old files. Clear files and selection
when loading begins to eliminate this inconsistency.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): restore previous files when reverting path on navigation error
Address P2 review: since files are now cleared when loading begins,
a failed navigation would leave the pane with the old path but an
empty file list. Save and restore the previous files alongside the
previous path in the error handler.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): restore selected files when reverting on navigation error
Address P2 review: save and restore selectedFiles alongside path and
files in the error handler so users don't lose their selection when
a navigation attempt fails.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): restore tab state when navigation is superseded by another request
Address P1 review: navSeqRef is tracked per-side not per-tab, so a
navigation from a different tab on the same side can invalidate this
request. When the sequence check causes an early return, restore this
tab's previous path, files, and selection instead of leaving it with
cleared files and a stale loading state.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): avoid overwriting newer navigation state when superseded
When a navigation request is superseded by a newer one on the same tab
(e.g., fast A→B→C), the completing request should not blindly restore
its previous state, as that would overwrite the latest navigation's
optimistic update. Now we check if the tab's current path still matches
what this request set before restoring.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): use per-tab request ID to guard superseded navigation restores
Replace the ambiguous currentPath equality check with a per-tab
navigation request ID (tabNavSeqRef). The old check failed when
refresh() triggered a navigation to the same path — the stale request
would incorrectly match and restore previous state.
The new approach tracks the latest requestId per tab, so:
- Same-tab superseded navigations (including same-path refreshes)
correctly skip the restore.
- Cross-tab superseded navigations (different tab on the same side)
correctly restore the orphaned tab's state.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): track per-tab nav sequence to prevent cache-hit state overwrite
When a cache-miss request (A) is pending and a cache-hit request (B) runs
on the same tab, A's superseded handler could overwrite B's result because
it only checked path equality. Add tabNavSeqRef to track the latest
requestId per tab, so superseded requests correctly skip restore when
a newer navigation (including cache hits) has already handled the tab.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: remove leftover merge conflict markers
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): restore to last confirmed state instead of optimistic state
When multiple navigations are in flight (A→B→C), the second navigation
would snapshot the optimistic state (path=B, files=[]) as its "previous"
state. If it then failed or was superseded, it would restore to an empty
file list instead of the last successfully loaded directory.
Introduce lastConfirmedRef to track the last known-good state per tab,
updated only on successful navigation (cache hit or listing success).
Restore-on-error and restore-on-supersede now always revert to this
confirmed state.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): guard restores against stale connection after reconnect/disconnect
connect() and disconnect() reuse the same tab ID but bump navSeqRef
without updating tabNavSeqRef, so a pending navigation could restore
stale state from a previous host into a freshly reconnected tab.
Fix by:
- Capturing connectionId at navigation start and checking it in every
updateTab restore callback (prev.connection?.id !== connectionId)
- Storing connectionId in lastConfirmedRef and re-seeding confirmed
state when the connection changes, preventing old host data from
being used as the restore target
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): keep files visible during loading and re-seed confirmed state
Two UI regressions fixed:
1. After a file mutation (delete/create/rename), lastConfirmedRef still
held the pre-mutation snapshot. If the subsequent refresh failed, the
error handler would restore stale files (e.g. resurrecting deleted
items). Fix: re-seed confirmed state from the pane whenever it is
settled (not loading), capturing any optimistic mutation updates.
2. Clearing files to [] on navigation start left a tab blank when
superseded by another tab navigating on the same side. Fix: keep
existing files visible during loading — the loading overlay already
has pointer-events-none to prevent interaction. Files are replaced
on success or restored from lastConfirmedRef on error/supersede.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(sftp): block interaction with stale files during directory loading
The loading overlay used pointer-events-none, allowing clicks to pass
through to stale file rows underneath. Since currentPath is updated
immediately on navigation, interacting with old filenames during a slow
load would resolve paths against the new directory.
Remove pointer-events-none from the loading overlay so it properly
blocks all interaction with the stale file list while loading.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* chore: ignore .claude/ directory in eslint config
The .claude/worktrees/ directory contains full repo copies from agent
worktrees. ESLint was scanning these, causing 621 pre-existing errors
(no-undef for Node.js globals in .cjs files) that blocked npm run dev.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
checkNow was calling bridge.checkForUpdate() which invokes updater.checkForUpdates()
via IPC. startAutoCheck() in the main process already calls checkForUpdates() on a
5s timer, and if that network request is still pending, the concurrent IPC call from
checkNow hangs indefinitely, causing the UI to be stuck in "checking" state forever.
Per the original design spec, checkNow should use performCheck() (GitHub API) directly.
This is completely independent of electron-updater's internal state machine, so it
never conflicts with the background startAutoCheck(). performCheck handles isCheckingRef,
isChecking, hasUpdate, and latestRelease; checkNow only manages manualCheckStatus.
- Critical: In Linux fallback path, temporarily reset isCheckingRef before calling
performCheck so its own guard can run (was silently returning null due to double-set)
- Critical: Replace updateState.currentVersion closure in checkNow with currentVersionRef
to avoid reading stale '' version on early user click; remove from useCallback deps
- Important: Add explicit !result guard when bridge is unavailable, returning 'error'
status instead of silently falling through to 'up-to-date'