Commit Graph
5931 Commits
Author SHA1 Message Date
Mohamed Boudra 4dfd7c18a0 fix(markdown): preserve reader position while responses grow
Keep the same message component boundary when a live row becomes retained history, preserving Mermaid runtimes and selection nodes. Observe paced child text commits at the web viewport so sticky-bottom follows before the next frame.
2026-10-15 18:15:14 +02:00
Mohamed Boudra 5e413ad36c test(markdown): cover state retention during image arrival 2026-10-15 17:41:35 +02:00
Mohamed Boudra 9e240d5d61 fix(markdown): reserve pending images and harden web rendering 2026-10-15 17:17:49 +02:00
Mohamed Boudra 30b7b269e9 fix(markdown): preserve first definitions across Mermaid segments 2026-10-15 17:03:08 +02:00
Mohamed Boudra a97f02e16f docs(markdown): record native selection and image limitations 2026-10-15 16:55:48 +02:00
Mohamed Boudra ad4d910aef fix(markdown): retry transient image decode failures 2026-10-15 16:55:15 +02:00
Mohamed Boudra b88b018d5f fix(markdown): preserve literal image fallback labels 2026-10-15 16:54:07 +02:00
Mohamed Boudra f90e160ac6 fix(markdown): normalize HTML following code elements 2026-10-15 16:53:16 +02:00
Mohamed Boudra 65f16f6322 fix(markdown): preserve spacing between HTML elements 2026-10-15 16:52:02 +02:00
Mohamed Boudra e7589cbc86 fix(markdown): classify web links explicitly and complete renderer types 2026-10-15 16:42:14 +02:00
Mohamed Boudra e014113792 fix(markdown): preserve complete assistant messages on native 2026-10-15 16:40:41 +02:00
Mohamed Boudra f829ce6ef3 fix(markdown): keep the first image reference definition 2026-10-15 16:25:58 +02:00
Mohamed Boudra e851a71ded fix(markdown): normalize only parsed HTML nodes 2026-10-15 16:24:52 +02:00
Mohamed Boudra 9e275bf361 fix(markdown): size inline images to the line and collapse failed loads 2026-10-15 16:22:37 +02:00
Mohamed Boudra 58f2fed621 fix(markdown): keep the renderer tree stable while images resolve 2026-10-15 16:17:52 +02:00
Mohamed Boudra 8e1dd51ff0 fix(markdown): create renderer types when applying package patch
The published nightly omits both MarkdownRenderers type files. Represent them as new files so patch-package succeeds on a fresh npm install, matching the already patched development package.
2026-10-15 16:17:32 +02:00
Mohamed Boudra fca12a89d6 fix(markdown): normalize inline HTML before rendering 2026-10-15 16:08:55 +02:00
Mohamed Boudra 648f290687 fix(markdown): restore file link hover tooltips on web 2026-10-15 16:05:50 +02:00
Mohamed Boudra 8057a65f41 fix(markdown): restore selection highlight on web 2026-10-15 16:00:26 +02:00
Mohamed Boudra 134b796859 fix(markdown): derive table and task list colours from the theme 2026-10-15 15:57:03 +02:00
Mohamed Boudra f5fb20cc55 fix(markdown): preserve encoded image paths after rebase
Keep the shared renderer image normalization and file-read regression coverage that originally lived in the main integration merge.
2026-10-15 15:33:33 +02:00
Mohamed Boudra 307f0dee0d test(markdown): exercise find across whole-message history 2026-10-15 15:32:20 +02:00
Mohamed Boudra d2169a061c fix(markdown): preserve authored empty link titles 2026-10-15 15:32:20 +02:00
Mohamed Boudra ee4a5bca7a fix(markdown): avoid empty web history measurements 2026-10-15 15:32:19 +02:00
Mohamed Boudra b782963970 fix(markdown): retain diagram identity and reference scope 2026-10-15 15:32:19 +02:00
Mohamed Boudra 3d06f652b2 fix(markdown): restore diagrams and preserve link origin 2026-10-15 15:32:19 +02:00
Mohamed Boudra 554530a667 fix(markdown): preserve file links and image revisions 2026-10-15 15:32:19 +02:00
Mohamed Boudra 35302f7251 test: verify library image controls and isolate website config 2026-10-15 15:32:19 +02:00
Mohamed Boudra 096508240f feat(markdown): use enriched renderer across all platforms 2026-10-15 15:32:19 +02:00
Mohamed Boudra 3639084530 revert(app): remove shared prose-run renderer changes
Reverts ab4737bb2 and ac47e1063 before replacing the Markdown engine across all platforms.
2026-10-15 15:32:02 +02:00
Mohamed Boudra 2db3488dbd fix(app): preserve Markdown containers before grouping prose 2026-10-15 15:32:02 +02:00
Mohamed Boudra bf100e1752 fix(app): share selectable native prose across Markdown surfaces 2026-10-15 15:32:02 +02:00
Mohamed Boudra ab234d5f12 fix(app): skip prose classification for blocks over the render cap 2026-10-15 15:32:02 +02:00
Mohamed Boudra 633950bb6a fix(app): preserve bracketed IPv6 links in native prose 2026-10-15 15:32:02 +02:00
Mohamed Boudra 1fbdac728f fix(app): keep growing markdown on the streaming block renderer 2026-10-15 15:32:02 +02:00
Mohamed Boudra 9b7a6ba782 fix(app): preserve parser-owned links and streaming tilde tails 2026-10-15 15:32:02 +02:00
Mohamed Boudra aeaee471a6 fix(app): preserve home paths and normalized prose links 2026-10-15 15:32:02 +02:00
Mohamed Boudra 9bbfe29c0e fix(app): bound prose append work and preserve markdown edge cases 2026-10-15 15:32:02 +02:00
Mohamed Boudra d42e0ca00c fix(app): preserve provisional syntax at cached reveal boundaries 2026-10-15 15:32:02 +02:00
Mohamed Boudra eedf916023 fix(app): preserve native prose entities and links while bounding preparation cost 2026-10-15 15:32:02 +02:00
Mohamed Boudra 7023d20a5b fix(app): preserve markdown source and file actions in native prose
Prepare original source blocks with source-position edits from the assistant parser. Keep reference scope and live/history projection consistent, and retain link text when dispatching workspace file actions.
2026-10-15 15:32:02 +02:00
Mohamed Boudra 5bf0e4b588 fix(app): preserve inline image formatting and reference scope 2026-10-15 15:32:02 +02:00
Mohamed Boudra 9ef289e7f4 fix(app): allow additive task lists and admonitions in native prose 2026-10-15 15:32:02 +02:00
Mohamed Boudra ae649cf7ec docs: record native prose compatibility fixes and heading limits 2026-10-15 15:32:02 +02:00
Mohamed Boudra 83061e0312 fix(app): preserve markdown semantics and render limits in prose runs 2026-10-15 15:32:02 +02:00
Mohamed Boudra e831814d73 docs: explain native prose selection boundaries and tradeoffs 2026-10-15 15:32:01 +02:00
Mohamed Boudra 75907b360b fix(app): render selectable native prose with enriched markdown 2026-10-15 15:32:01 +02:00
Mohamed Boudra d8f79925d1 fix(app): group native assistant prose into selectable runs 2026-10-15 15:32:01 +02:00
paseo-bot[bot]andGrant Ammons 80badb3b8f fix(opencode): answer multi-select v2 questions from the question card (#6149)
Closes #6135

Co-authored-by: Grant Ammons <grant@grant.dev>
2026-10-15 15:15:19 +02:00
71f575e16a Keep malformed Claude question answers retryable (#6936)
* fix: reject a question permission that would deliver no answer

Answering an `AskUserQuestion` permission in any shape but
`updatedInput.answers` keyed by one of its questions resolves as `allow` and
delivers nothing. The waiting agent is told "The user did not answer the
questions." — an affirmative falsehood rather than silence, so neither side can
see that anything failed. The responder sees success; the agent believes the
human declined and acts on that.

The field it is most natural to reach for cannot work. `selectedActionId` is
`z.string().optional()` with no membership check, and is read only for `plan`
kinds; a question advertises `actions: undefined`, so there is no action id to
name in the first place.

It is also unrecoverable. `respondToPermission` deletes the request from
`pendingPermissions` on entry, so the malformed answer consumes it and the retry
fails with "No pending permission request". The guard runs before that delete,
and `AgentManager` drops its own copy only once the call resolves, so both maps
survive the throw and the request stays answerable.

The answer contract is per provider, so the guard is in the Claude provider
rather than in `AgentManager`. Claude keeps an answer only when its key is a
question's full text or its header and its value is a non-empty string; Codex's
`mapCodexQuestionResponseByHeader` reads headers only and deliberately selects
each question's first option when nothing maps, which a shared guard would have
rejected; OpenCode reads headers only as well.

`resolveClaudeAskUserQuestionAnswers` is extracted from
`normalizeClaudeAskUserQuestionUpdatedInput` with no change in behaviour, and
both it and the guard now use it. So "would this deliver anything" is answered
by the code that does the delivering, rather than by a second copy of its rule —
which matters more than it looks, because that rule has two details easy to
restate wrongly: `readNonEmptyString` tests `value.trim()` for emptiness but
returns the *original* string, so a question named `" Which colour? "` is keyed
by that padding; and an empty `updatedInput.questions` array is a list that wins
over the request's own questions and maps nothing, not an absent one.

Verified on a live daemon over the MCP `respond_to_permission` path against a
seat whose question text is literally `" Which colour? "`: `selectedActionId`,
the trimmed key, an empty echoed question list and a numeric answer are each
rejected with the request still pending, and
`{"answers":{" Which colour? ":"Ochre"}}` then reaches the agent.

One known limit: the WebSocket path (`session.ts handleAgentPermissionResponse`)
catches the throw and emits an `activity_log` error rather than failing the
call, because a permission response is modelled as a notification. So
`paseo permit allow` still prints `allowed` and exits 0 for a rejected shape.
The destructive half is closed on every path — the request survives and the
agent is never told a falsehood — but closing the reporting half needs a
protocol change.

* test(claude): cover the question-answer-required retry path

A non-deliverable answer to an AskUserQuestion permission is rejected, but
the pending request survives it: a corrected retry against the same request
id is accepted, and the waiting agent receives the answer.

Mutation testing on a fork found that the existing suite does not pin this
ordering — moving the deliverability check to run after the request is
deleted from pendingPermissions still leaves every existing test green. This
test reds against that change.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

---------

Co-authored-by: Thomas Van <minhthong@gmail.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Co-authored-by: paseo-bot[bot] <266920839+paseo-bot[bot]@users.noreply.github.com>
Co-authored-by: paseo-bot <paseo-bot@users.noreply.github.com>
2026-10-15 14:21:03 +02:00