Skip to content

fix(chat): round-1 bug-hunt fixes (silent image drops, thinking-only hold, transcript JSON cap, image-driven overflow) - #299

Closed
kahme247 wants to merge 1 commit into
mainfrom
bug-hunt/mainchat-round1
Closed

kahme247 wants to merge 1 commit into
mainfrom
bug-hunt/mainchat-round1

Conversation

@kahme247

Copy link
Copy Markdown
Collaborator

Found by the round-1 bug-hunt fleet (area: main chat), all reproduced before fixing.

  • MAJOR: oversized/over-cap images were silently dropped when other images were accepted (only the zero-acceptance case reported a skip). processImageFiles now reports attachmentImagesSkipped with the count whenever skipped > 0; the zero-acceptance branch (including the at-limit wording and the :813 send refusal) is untouched.
  • MINOR: a thinking-only finished reply vanished instead of being held until its saved copy landed (hasVisibleAssistantContent counts only text/image). New hasHoldableAssistantContent() (visible content OR a non-empty thinking block) is now the message_end hold predicate; other hasVisibleAssistantContent call sites are unchanged.
  • MINOR: the subagent transcript dialog rendered unbounded tool-call input JSON (text rows were capped at 400 chars, tool-call inputs were not). Tool-call inputs are now sliced to the same 400-char budget.
  • MINOR: the user-bubble "Show full input" toggle never appeared when overflow came from late-loading images (measurement ran before images loaded and the observer never refired). The overflow measurement is now re-run on image load via onLoad on the bubble's ClickableImages.

Tests: ChatInput suites (image-skip-notice 2/2, queue-attachments 33/33, clipboard-image 7/7, ChatInput 22/22, navigation 6/6, btw 3/3, slow 4/4), assistant-response 4/4, message-overflow 2/2, SubagentTranscriptDialog 11/11, MessageView 47/47, useAgentSession.rpc 175/175; tsc clean; lint 0 errors (10 pre-existing warnings, identical on clean main). Parent re-verified: same targeted suites, tsc, and eslint on the pushed commit.

Caveats: an identity-move mid-read race can still drop images outside the counted path (reporting that count from inside a state updater would be a side effect); the transcript cap covers tool-call inputs only, not untruncated assistant text blocks in the same branch; only the user bubble got onLoad, not other ClickableImage uses. One MessageView run showed a single failure that did not reproduce in two subsequent full runs — consistent with the known MessageView load flake.

- Report dropped images even when siblings are accepted (processImageFiles
  now keeps the attachmentImagesSkipped notice for partial drops).
- Hold thinking-only finished replies until the saved copy lands, via a new
  hasHoldableAssistantContent predicate (other call sites keep the stricter
  hasVisibleAssistantContent).
- Cap subagent transcript tool-call input JSON at the 400-char text budget.
- Re-measure user-bubble overflow when bubble images load so the
  Show full input toggle appears for image-driven overflow.
@coderabbitai

coderabbitai Bot commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 59 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews currently available.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ede2eaa4-bd38-4776-96ad-ba4916f77bfe
Commits

Reviewing files that changed from the base of the PR and between 7d0ce59 and 86261b6.

Files selected for processing: 10
  • components/ChatInput.image-skip-notice.test.mjs
  • components/ChatInput.tsx
  • components/MessageView.test.mjs
  • components/MessageView.tsx
  • components/SubagentTranscriptDialog.test.mjs
  • components/SubagentTranscriptDialog.tsx
  • hooks/useAgentSession.rpc.test.mjs
  • hooks/useAgentSession.ts
  • lib/assistant-response.test.mjs
  • lib/assistant-response.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@kilo-code-bot

kilo-code-bot Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Code Review Roast 🔥

Verdict: No Issues Found | Recommendation: Merge

Oh wait, this PR is actually clean. I need to sit down. I had my flamethrower warmed up and everything.

📊 Overall: Like finding a unicorn in production — I didn't think clean PRs existed anymore, but here we are.

Files Reviewed (10 files)
  • components/ChatInput.image-skip-notice.test.mjs
  • components/ChatInput.tsx
  • components/MessageView.test.mjs
  • components/MessageView.tsx
  • components/SubagentTranscriptDialog.test.mjs
  • components/SubagentTranscriptDialog.tsx
  • hooks/useAgentSession.rpc.test.mjs
  • hooks/useAgentSession.ts
  • lib/assistant-response.test.mjs
  • lib/assistant-response.ts

Fix these issues in Kilo Cloud


Reviewed by free · Input: 61.1K · Output: 3.6K · Cached: 446.4K

@kahme247 kahme247 added the needs rebase Rebase onto current main; needs re-review label Nov 5, 2026
@kahme247

kahme247 commented Nov 5, 2026

Copy link
Copy Markdown
Collaborator Author

The Bun server/daemon architecture has landed on main, so this PR needs to be rebased and re-reviewed against the new architecture before it can be merged. Please rebase onto current main, resolve the conflicts, and request re-review once CI is green.

@andrebrait andrebrait left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the image, thinking-only reply and transcript-display fixes. Maintainer triage at 86261b6d1519d92be9ea7a85b3506ae988af4609: three changes remain useful on main—the thinking-only hold predicate, tool-call input display cap, and image-onLoad overflow remeasurement. Targeted scratch regressions failed when each corresponding fix was reverted.

The ChatInput silent-drop fix is now superseded by #371: over-budget images become uploaded file attachments instead of entering the old skipped-image path. Please drop that hunk and ChatInput.image-skip-notice.test.mjs rather than restore the obsolete drop policy. A mechanical partial merge can also leave a reference to the no-longer-defined skipped variable.

Rebase the remaining fixes and migrate any jiti/static DOM imports to the current Bun/dynamic Testing Library convention. The input cap currently stringifies the full payload before slicing, so describe it as a display cap rather than a bound on serialization work. An ellipsis would make truncation clearer.

No real-browser run, omp persistence probe, CI or full suite was performed locally. This is triage, not merge approval.

@andrebrait

Copy link
Copy Markdown
Collaborator

Hi @kahme247, thank you for your contribution, and apologies for the long wait on this PR. We really appreciate the time and effort you have put into it.

We are working through a major refactor of ompweb, including switching to our own build of omp. We are close to finishing that work; once the refactor is complete, we will turn our attention back to the pending PRs, including this one.

Thank you for your patience and for helping improve ompweb!

@kahme247

Copy link
Copy Markdown
Collaborator Author

Hi, thanks for this PR. It currently conflicts with main and can't be merged as-is — please rebase it onto current main and resolve the conflicts. Once it's rebased I'll re-run the checks.

Beyond the rebase: please drop the ChatInput skip-notice hunk (superseded by #371); the remaining three fixes are still wanted.

@kahme247

Copy link
Copy Markdown
Collaborator Author

Closing this as superseded by maintainer rework #561, which keeps the three remaining fixes (MessageView overflow re-measure on image load, 400-char cap on subagent transcript tool-call input, thinking-only finished replies held on screen) and drops the ChatInput skip-notice hunk as superseded by #371's rework (images now route through processImageFiles/attachAsFiles, with no silent-drop path left).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs rebase Rebase onto current main; needs re-review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants