Skip to content

Resolve threads as primary acknowledgement, not replies - #13894

Merged
AmethystLiang merged 1 commit into
mainfrom
should-resolve-comments
Aug 12, 2026
Merged

AmethystLiang merged 1 commit into
mainfrom
should-resolve-comments

Conversation

@AmethystLiang

Copy link
Copy Markdown
Contributor

Problem

When Orca resolves review comments after launching an AI agent, it posts a "Fixing." reply AND resolves the thread. Since a resolved thread immediately collapses on the host, the reply is redundant noise — the user can already see the thread is handled.

Solution

Resolve open threads without replying to them. The thread resolution itself is the acknowledgement. Only post "Fixing." replies for:

  • Threads that are already resolved (no close action available)
  • Standalone conversation comments (no resolve endpoint)
  • Review summaries on anchors that don't support replies

Key changes:

  • Introduced buildSnapshottedThreadResolver to resolve threads against review state captured at launch time (prevents the panel navigating away from dropping the resolve)
  • Separated GitHub and GitLab resolve targets to handle degraded PR entries (missing prRepo) that can still resolve
  • Removed live-state gating on resolves — they're snapshotted at launch, so slow agent delivery or navigation no longer silently skips them
  • Refactored acknowledgePRCommentsAfterAiLaunch to prioritize resolve over reply

Testing

New test file pr-comment-snapshotted-thread-resolver.test.ts covers:

  • GitHub resolve against snapshotted PR (with and without prRepo)
  • GitLab resolve against snapshotted MR iid
  • Handling of missing targets and host failures
  • Optimistic UI updates guarded by panel context check

Updated tests in pr-comments-ai-launch-ack.test.ts validate:

  • Resolvable threads resolve without replying
  • Failed resolves are counted and reported
  • Already-resolved threads fall back to reply
  • Conversation half still batches into one post
  • Bounded concurrency maintained across all cases

Collapsed threads visibly close on the host — this is the
acknowledgement. An extra reply only adds noise. Snapshot the
resolution target at launch to prevent silent drops if the panel
navigates before agent delivery. Only reply for comments without
resolution endpoints.
@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The comment acknowledgement flow now captures GitHub and GitLab resolution targets at launch. After prompt delivery, it resolves eligible host threads using those snapshots. It posts replies only for comments that the host cannot resolve. The resolver reports failures, preserves bulk processing after rejected host calls, and limits optimistic updates to the active review. Tests cover provider handling, persistence, failures, navigation, batching, and concurrency. Localized prompts and errors describe the updated behavior.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the problem, solution, and tests, but omits the required Screenshots, AI Review Report, Security Audit, and Notes sections. Add the missing template sections, state “No visual change” if applicable, complete the testing checklist, and document cross-platform review and security findings.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly states the primary change: thread resolution replaces replies as the acknowledgement method.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 9a8616f8-521a-4c0b-8818-721a64e5a1d0

📥 Commits

Reviewing files that changed from the base of the PR and between 55beeeb and d4f530c.

📒 Files selected for processing (11)
  • src/renderer/src/components/pr-comments-resolution-prompt.ts
  • src/renderer/src/components/right-sidebar/ChecksPanel.tsx
  • src/renderer/src/components/right-sidebar/pr-comment-snapshotted-thread-resolver.test.ts
  • src/renderer/src/components/right-sidebar/pr-comment-snapshotted-thread-resolver.ts
  • src/renderer/src/components/right-sidebar/pr-comments-ai-launch-ack.test.ts
  • src/renderer/src/components/right-sidebar/pr-comments-ai-launch-ack.ts
  • src/renderer/src/i18n/locales/en.json
  • src/renderer/src/i18n/locales/es.json
  • src/renderer/src/i18n/locales/ja.json
  • src/renderer/src/i18n/locales/ko.json
  • src/renderer/src/i18n/locales/zh.json

"branch": "Sync Branch"
},
"7e4b2a19c0": "No se pudo resolver el PR de GitHub para responder."
"7e4b2a19c0": "No se pudo resolver el PR de GitHub para responder.",

@coderabbitai coderabbitai Bot Aug 12, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Refer to the GitHub review thread, not the pull request.

The text "No se pudo resolver el PR de GitHub para responder." says that Orca could not resolve the pull request itself. Use wording consistent with Line 10167, such as "No se pudo resolver el hilo del PR de GitHub para responder."

Proposed wording
-            "7e4b2a19c0": "No se pudo resolver el PR de GitHub para responder.",
+            "7e4b2a19c0": "No se pudo resolver el hilo del PR de GitHub para responder.",
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"7e4b2a19c0": "No se pudo resolver el PR de GitHub para responder.",
"7e4b2a19c0": "No se pudo resolver el hilo del PR de GitHub para responder.",

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Fixing. Will be in the next commit

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@AmethystLiang, thanks for confirming. I'll keep this thread open until the fix lands in the next commit.

You are interacting with an AI system.

@AmethystLiang
AmethystLiang merged commit 96c17b4 into main Aug 12, 2026
45 checks passed
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
Collapsed threads visibly close on the host — this is the
acknowledgement. An extra reply only adds noise. Snapshot the
resolution target at launch to prevent silent drops if the panel
navigates before agent delivery. Only reply for comments without
resolution endpoints.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant