Commit Graph

4211 Commits

Author SHA1 Message Date
can1357 dfeb9af61a feat(coding-agent/lsp): deferred slow LSP diagnostics during writethrough
- Added a configurable diagnostics timeout to `getDiagnosticsForFile` and wired callers to pass custom budgets.
- Refactored writethrough diagnostics retrieval to `fetchDiagnosticsWithDeferral`, waiting inline briefly and handing off slow results to the deferred callback.
- Extended deferred fetches to use a longer timeout so late diagnostics are still delivered for slow servers.
2026-06-08 05:17:37 +02:00
can1357 4442b3bfcc fix(coding-agent): marked agent reminder prompt as synthetic
- Flagged the injected reminder turn with `synthetic: true` to keep it hidden from the transcript.
2026-06-08 05:16:03 +02:00
can1357 e1e75526d9 fix(coding-agent): removed system-reminder wrapper from file context
- Sent file contents as plain text instead of wrapping in `` tags.
- Joined file entries with single newlines instead of double.
2026-06-08 05:15:18 +02:00
can1357 0e78cac716 fix(coding-agent): removed abort marker and updated continue shortcut prompts
- Removed `<turn-aborted>` guidance injection from `transformMessages`, deleted `turn-aborted-guidance.md`, and dropped the synthetic abort note path for aborted/error turns.
- Updated `c`/`.` continue shortcuts to submit `manual-continue.md` as a hidden synthetic `developer` message via `session.prompt(..., { synthetic: true })` instead of sending an empty user turn.
- Updated tests and changelog notes in AI and coding-agent to reflect the revised abort-context and continue behavior.
2026-06-08 05:02:49 +02:00
can1357 cdafa6f371 fix(coding-agent): fixed live scrollback commit behavior for streaming transcript tool rows
- Computed live commit state from render diffs and drove native scrollback via safeLength.
- Fixed volatile live tool rows committing only after stream finalization in native scrollback.
- Stored append-only and volatile flags in FrozenRender snapshots for live-row tracking.
- Removed append-only streaming predicates from assistant and tool rendering paths.
2026-06-08 04:57:36 +02:00
can1357 97ae0fd34d fix(coding-agent): fixed grouped read output by splitting and merging selector rows
- Split top-level and delimited read selectors into separate rows before grouping.
- Merged duplicate same-file read selectors into one summarized row with ellipsis truncation.
- Computed grouped-read status and totals from aggregated rows for accurate summaries.
- Updated changelog entries and fixtures to document/read expectations.
2026-06-08 04:51:25 +02:00
can1357 54404878bf feat(coding-agent/cli): added custom gallery renderer for grouped read fixtures
- Gallery fixtures gained a `renderState` hook to render non-standard component states.
- Added a `read_group` filesystem fixture that uses `ReadToolGroupComponent` to render delimited, full-file, and range read states.
- Added gallery CLI coverage to verify grouped read fixture output and expected ranges.
2026-06-08 04:47:57 +02:00
can1357 da0502008e docs(coding-agent): rewrote plan-mode prompt as execution spec
- Reframed the plan artifact as a self-contained execution spec a fresh agent runs after context is cleared.
- Folded high-consensus requirements (sequencing, contracts, cutover, verification) into existing sections as inline rules.
- Banned decision-free sections and conversation back-references; kept the decision-complete self-check and completeness-wins tiebreak.
2026-06-08 04:44:19 +02:00
can1357 fe5d27c4a3 feat(coding-agent): removed animated shimmer border on exec blocks
- Removed sweeping bottom-edge segment from pending bash, eval, and ssh blocks; pending now shows a static accent border.
- Dropped border shimmer geometry, animate options, and related tests.
- Repurposed pending-tool 30fps redraws solely for the running task row shimmer.
2026-06-08 04:31:58 +02:00
can1357 f741431b76 fix(coding-agent/modes): fixed resume ranking to prefer literal recency and history matches
- Fixed blank-query behavior so rankSessionSearchMatches returns all sessions unchanged.
- Deduplicated prompt-history results by session path in mergeSessionRanking to avoid duplicate suggestions.
- Adjusted resume ranking to favor literal-token matches by recency, then fallback to fuzzy score.
2026-06-08 04:30:56 +02:00
can1357 65bddab719 feat(coding-agent/eval): enforced JS eval helper options as trailing object literals
- Added strict option parsing for JavaScript helpers so read/sort/uniq/counter/tree/llm/agent now reject positional options and non-object option values.
- Introduced `optionsArg` and `isPlainObject` to enforce a single trailing options object and throw clear TypeError messages on invalid calls.
- Updated the eval tool prompt to document that JavaScript helpers require one trailing options object and no extra positional arguments.
2026-06-08 03:33:45 +02:00
can1357 622f0ddc8a tests(coding-agent): updated keyword comments to workflowz
- Aligned doc comments and tests with the workflowz trigger rename.
2026-06-08 03:12:28 +02:00
can1357 bc936cde43 feat(coding-agent/modes): changed workflow fan-out trigger keyword from workflow to workflowz
- Updated workflow detection in `workflow.ts` to recognize only the lowercase `workflowz` token for detection and highlighting.
- Changed workflow instructions and tips to reference the new `workflowz` trigger for eval fan-out behavior.
- Updated workflow tests to assert `workflowz` matches correctly and previous `workflow`/`workflows` forms no longer trigger.
2026-06-08 02:56:36 +02:00
can1357 d574968da4 fix(coding-agent/config): hardened settings hooks against callback exceptions
- Replaced manual settings callback sets with a shared `SettingSignal` that snapshots listeners and skips over individual callback failures.
- Updated `provider.appendOnlyContext`, `statusLine.sessionAccent`, and `hindsight` hook dispatch to use the new signal and added a Settings test confirming a throwing append-only listener does not stop other listeners.
- Adjusted the duplicate-tool-results regression test to handle `tool_calls` being absent before mapping IDs.
2026-06-08 02:38:18 +02:00
can1357 00e6e14cb4 feat: added reconstructed raw SSE capture for stream provider SDKs
- Added reconstructed SSE event emission for OpenAI, Azure, and Anthropic streams.
- Added raw SSE text to debug report bundles, including raw-sse.txt output.
- Included dropped-record metadata in raw SSE text when events were trimmed.
- Updated raw SSE and sse-debug tests for observer-based capture and safety checks.
2026-06-08 02:35:14 +02:00
can1357 71624ee47b fix(coding-agent): fixed stale settings and session-accent cache handling
- Cached setting path segments and memoized `Settings.get()` results, clearing caches on updates.
- Triggered session-name and session-accent callbacks only when effective values changed, with error-safe dispatch.
- Memoized status-line and interactive accent resolution with cache invalidation on settings/theme/session changes.
- Added regression tests for keybinding precedence, status-line, settings, and accent cache behavior.
2026-06-08 02:30:44 +02:00
can1357 a3efb62998 feat(coding-agent/modes): added canonical key matching behavior and exported alias utilities
- Built canonical and alias key maps for action/custom handlers and rebuilt them on changes.
- Preserved the first handler when custom key alias collisions occurred during rebuilds.
- Exported canonicalKeyId and addKeyAliases from keybindings for external use.
2026-06-08 02:29:30 +02:00
can1357 5e34d446e7 fix(coding-agent/modes): fixed shimmer sweep timing to use fixed-cell velocity
- Updated classic shimmer to compute band position from elapsed time at 30 cells per second instead of a fixed sweep duration.
- Updated KITT shimmer to use fixed-speed ping-pong motion over the same 2xrange cycle so round-trip timing scales with message length.
2026-06-08 02:27:24 +02:00
can1357 243a806415 fix(coding-agent): fixed reference retries and raw/placeholder handling
- Adjusted `LspTool` to retry only zero/decl-only references with two 250ms waits for project-aware servers.
- Removed raw-mode GitHub repo README API fallback in `read`, so `:raw` now renders the page directly.
- Replaced regex heuristics in `isImagePlaceholderAnswer` with a fixed normalized placeholder set.
2026-06-08 02:07:18 +02:00
can1357 68c454c0fc feat(edit/read): enabled canonical snapshot keys across read/write paths
- Canonicalized snapshot key resolution with realpath, parent fallback, and raw fallback.
- Updated snapshot, hashline, read, and write flows to use canonical snapshot keys consistently.
- Fixed converted-content line-range reads to apply selectors via in-memory range/text builders.
- Updated read tool docs to clarify one-line and multi-range selector context bounds.
2026-06-08 02:04:59 +02:00
can1357 088fb7fb75 fix(eval): resolved JS/Python resets by awaiting in-flight operations
- Coalesced concurrent JS and Python reset requests by awaiting in-flight promises instead of throwing.
- Aligned non-reset execution calls to wait for in-progress resets before running on a recreated session.
2026-06-08 02:04:59 +02:00
can1357 49aa6e5839 fix(eval): corrected eval LLM calls and spawn-aware tool descriptions
- Ensured eval LLM calls always include a non-empty system prompt to avoid 400s.
- Aligned eval tool docs with session spawn policy by omitting agent() when spawns are disallowed.
- Added regression coverage for default system prompts and spawn-aware agent() description behavior.
2026-06-08 02:04:59 +02:00
can1357 f73942eb28 fix(eval/py): corrected read() positional offset/limit support and tests
- Updated `packages/coding-agent/src/eval/py/prelude.py` to accept positional `offset` and `limit` in `read()`.
- Added regression coverage in `packages/coding-agent/src/eval/py/__tests__/prelude.test.ts` for positional read signatures.
2026-06-08 02:04:59 +02:00
can1357 8173b7ea8c feat(tools/browser): enabled shared browser tab reuse and extract safety
- Applied `opts.viewport` on reusable tabs in `tab-supervisor.acquireTab` before conditional `tab.goto`.
- Skipped `runInTabWithSnapshot` on tab reuse when no viewport or URL change was requested.
- Changed `tab.extract` to return `Promise<string>` and throw on missing or empty Readability content.
- Redacted `user:pass@` from tab URLs returned in observations to avoid leaking credentials.
- Documented `tab.extract(format)` to return markdown/text and throw when no readable content exists.
2026-06-08 02:04:59 +02:00
can1357 81a7af448e fix(lsp): addressed lsp flakiness via timeout handling and retry behavior
- Updated sendRequest timeout handling to use explicit timeoutMs, then AbortSignal deadlines, else 30s fallback.
- Normalized getServersForFile matching to accept both `.ts` and `ts` for extension routing.
- Expanded references retry logic to handle thin results with progressive backoff before giving up.
- Filtered rename_file fanout to servers matching source/destination extensions only.
- Updated status output to separate configured servers from started clients with readiness labels.
- Added regression tests for timeout ownership, extension filtering, and status readiness reporting.
2026-06-08 02:04:59 +02:00
can1357 ccf49e6c37 feat(tools/fetch): added :raw repo-root README decode with fallback
- Added `:raw` repo-root resolution via GitHub API `/readme` for decoded markdown.
- Preserved fallback to default raw HTML rendering when the README payload was unusable.
- Added regression coverage for successful README decoding and fallback behavior.
2026-06-08 02:04:59 +02:00
can1357 b3af7c29b4 feat(tools/github): added cache purges for mutating gh bash commands
- Added pre-run cache invalidation for mutating gh issue/pr bash commands.
- Implemented bash command token parsing for mutating issue/pr calls and extraction.
- Added cache purging by issue/PR number with optional cross-repo scope.
- Added tests covering mutating, chained, and no-op bash command cache scenarios.
2026-06-08 02:04:59 +02:00
can1357 ee4df538f0 fix(tools): resolved search-path parsing and local sandbox checks
- Set `FindTool` to disable recursive glob traversal so `dir/*` stays shallow.
- Added `parseSearchPathPreferringLiteral` to prefer literal paths like `apps/[id]/page.tsx` when they exist.
- Updated `resolveToolSearchScope` to reject external URLs with a clear `read` usage error.
- Expanded plan-mode sandbox checks to allow absolute paths inside the local artifact root.
2026-06-08 02:04:59 +02:00
can1357 de8851b0c8 fix(tools/search): patched search for skip and oversized archive warnings
- Accepted nullable `skip` in `searchSchema` and treated it as 0 in `SearchTool` pagination logic.
- Added oversized-file detection for explicit search targets to warn when native grep's 4MB cap may hide matches.
- Clarified archive-member error guidance to read `<archive>:<member>` content directly before re-grepping.
2026-06-08 02:04:59 +02:00
can1357 c9b3c23600 feat(task): enabled schema override flow to keep task payloads with warnings
- Propagated `schemaOverridden` from `YieldTool` into executor `YieldItem` metadata.
- Bypassed schema validation on override or schema-builder errors and kept payload output with success exit.
- Emitted `SUBAGENT_WARNING_SCHEMA_OVERRIDDEN` so accepted override results no longer surface as `schema_violation`.
2026-06-08 02:04:59 +02:00
can1357 e44bf8261b fix(web): resolved placeholder-only codex responses by returning citations
- Expanded Codex placeholder detection to match common image-reference phrases and punctuation.
- Raised `codex` provider failure when final and streamed text are placeholders and no sources exist.
- Dropped placeholder prose from returned answers while preserving citation sources.
2026-06-08 02:04:59 +02:00
can1357 16f9c199da ux(coding-agent/task): adjusted running task progress output to animate descriptions
- Reworked running-task rendering so shimmer animation is applied to descriptions instead of IDs.
- Added accent coloring for the separator and description text to keep the status line formatting consistent.
2026-06-08 01:46:03 +02:00
can1357 caa9c69309 feat(coding-agent): added provider-priority model selection and refined fallback ordering
- Added first-party-first provider priority defaults for model ranking.
- Consolidated model resolution to use getModelMatchPreferences from session settings.
- Prioritized providerPriorityRank ahead of usage rank when picking preferred models.
- Added second-pass fallback to default-model or API-key-valid matching order.
2026-06-08 01:32:39 +02:00
can1357 e1840cde00 feat(coding-agent/modes): displayed auto-selected role defaults as [ROLE auto] badges
- Tracked each role assignment with an `autoSelected` flag to distinguish inferred defaults from configured models.
- Resolved unconfigured known roles from `pi/{role}` candidates in `#loadRoleModels` and marked them as auto-selected defaults.
- Added a selector test verifying unconfigured models render `[SMOL auto]` and `[SLOW auto]` badges.
2026-06-08 01:22:36 +02:00
can1357 d930f4c82d feat(packages/ai): added credential origin to provider auth
- Added `getCredentialOrigin` and `getEnvApiKeyName` to classify auth source.
- Surfaced provenance tags in the `/login` and `/logout` provider picker.
- Made the picker search filter match credential origin and env var name.
- Added coverage for credential-origin precedence and env naming.
2026-06-08 01:16:37 +02:00
can1357 403ce587df fix(packages/coding-agent): resolved missing source cwd for local resumes
- Handled local resumes with missing source CWD by prompting to move and reopening sessions.
- Shared missing-CWD relocation logic between local and global resumes for consistency.
- Added regression test for local explicit-session-dir resumes and session-header cwd updates.
2026-06-08 01:09:47 +02:00
can1357 41aa4de9b2 fix(packages/coding-agent): resolved OSC5522 BEL and metadata behavior
- Tracked kitty-dot payload listings to emit BEL-terminated OSC5522 responses.
- Updated non-kitty-dot writes to include mime in metadata and drop ST terminator.
- Adjusted enhanced-paste tests to assert BEL terminator and metadata formatting.
2026-06-08 01:09:47 +02:00
can1357 5be2600b92 fix(coding-agent): normalized relative --cwd flag before downstream use
- Updated startup handling so `applyStartupCwd` now re-syncs `parsed.cwd` to the resolved absolute project directory after `setProjectDir` runs.
- Adjusted the CLI cwd tests to verify a relative `--cwd` argument is normalized to an absolute path and does not double-resolve against the new process cwd.
2026-06-08 00:58:22 +02:00
can1357 181419b65b fix(coding-agent/modes): fixed Esc interrupt acknowledgement to update loader immediately
- Added an interrupt state in EventController to switch the working label to `Interrupting...` and suspend intent-driven updates until the turn resets.
- Called `notifyInterrupting()` from streaming-interrupt paths in InputController and exposed it on InteractiveModeContext so Esc acknowledgement shows immediately while tools tear down.
- Added tests to verify loader acknowledgement, freeze of late intent updates during interruption, and label updates resuming on the next agent start.
2026-06-08 00:54:54 +02:00
Can Bölük cab7eb920c Merge branch 'main' into fix/parse-cwd-flag 2026-06-08 00:54:38 +02:00
Can Bölük bf4f675298 Merge branch 'main' into fix/session-resume-after-worktree-move 2026-06-08 00:48:29 +02:00
can1357 ba4abb7e2f fix(coding-agent): excluded cwd-less legacy sessions from relocation guard
- Guard now skips sessions with empty cwd, not just undefined.
- Prevents path.resolve("") collision from hijacking a moved session.
2026-06-08 00:47:39 +02:00
can1357 bad1e2acd6 fix: restricted GitHub Copilot auth to COPILOT_GITHUB_TOKEN
- Changed the `github-copilot` service provider to resolve credentials only from `COPILOT_GITHUB_TOKEN`.
- Updated CLI extra help text to document `COPILOT_GITHUB_TOKEN` as the GitHub Copilot environment variable.
- Reworded environment variable docs to reflect the revised Copilot/GitHub token usage and order.
2026-06-08 00:42:23 +02:00
bling cfa9a2d53e fix(coding-agent): resume sessions after a worktree move/rename
When a session's working directory is moved or renamed (e.g. `git worktree
move`), the session file stays under the old cwd-encoded bucket while the new
directory is empty. Resuming was lossy:

- `--continue` rejected the terminal breadcrumb purely on cwd mismatch and then
  found nothing in the new bucket, silently starting a fresh empty session.
- cross-project `--resume <id>` only offered to *fork* (duplicate) the session
  into the new directory, forcing manual id selection and leaving a stale copy.

Detect relocation via the strong, low-false-positive signal "recorded cwd no
longer exists on disk" and re-root in place with the existing `moveTo()`:

- `continueRecent` re-roots the terminal's last session into the current
  directory when its recorded cwd is gone and the new location has no sessions
  of its own (otherwise behavior is unchanged). `readTerminalBreadcrumb` is
  refactored into `readTerminalBreadcrumbEntry` returning the raw cwd +
  session file so callers can interpret a cwd mismatch.
- cross-project `--resume <id>` offers "Move (re-root)" instead of fork when the
  source directory is gone; a still-existing different project still forks.

Tests: continue-relocation (re-root on move, no-hijack on plain cd, prefer
local recent) and cross-project move-vs-fork routing.
2026-06-07 18:34:51 -04:00
can1357 72be2a54e7 Merge remote-tracking branch 'origin/farm/1f3e0007/fix-ctrl-z-suspend' 2026-06-08 00:30:27 +02:00
can1357 4a0eba8092 Merge remote-tracking branch 'origin/farm/8b6c0673/fix-follow-up-goal-command' 2026-06-08 00:29:53 +02:00
can1357 248f14cc3b Merge remote-tracking branch 'origin/farm/e318626d/retry-generic-upstream-error' 2026-06-08 00:29:12 +02:00
can1357 ae420d49f0 Merge remote-tracking branch 'origin/farm/915457a5/fix-kitty-osc-5522-mime-listing' 2026-06-08 00:28:41 +02:00
Can Bölük 84ddda3c1b Merge pull request #2060 from Null3rror/fix/mcp-tool-approval-tier
fix(mcp): declare approval tier for MCP tools to prevent hangs in non-yolo mode
2026-06-08 00:26:25 +02:00
Can Bölük 0aa22b7120 Merge pull request #1947 from DarkPhilosophy/fix/empty-stop-guard-tooluse
fix(coding-agent): retry orphaned toolUse stops to prevent history corruption
2026-06-08 00:20:54 +02:00