Skip to content

feat: add diff commit session launcher#585

Merged
matt2e merged 1 commit intomainfrom
kick-off-commit-sesh-from-diff
Apr 9, 2026
Merged

feat: add diff commit session launcher#585
matt2e merged 1 commit intomainfrom
kick-off-commit-sesh-from-diff

Conversation

@matt2e
Copy link
Copy Markdown
Contributor

@matt2e matt2e commented Apr 8, 2026

Summary

  • add a commit session launcher to the diff modal and supporting frontend/backend wiring
  • prefill launch context from visible diff feedback and queue state
  • tighten launcher copy and omit branch scope from the launch context

@matt2e matt2e requested review from baxen and wesbillman as code owners April 8, 2026 01:57
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d21f2ff8f9

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +2457 to +2458
let Some((json, remainder)) = rest.split_once(CLOSE) else {
return Err("Queued session prompt had malformed launch context".to_string());
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Fall back when launch-context prefix is user text

drain_queued_sessions_for_branch now parses every queued prompt through extract_launch_context, and this helper returns an error whenever a prompt starts with <launch-context> but does not contain valid BranchSessionLaunchContext JSON. In that case the session never starts and can block later queued sessions on the same branch. This is reachable with ordinary queued prompts (no launch context supplied) if a user message begins with that tag, so parsing should degrade to "treat as plain prompt" instead of hard-failing the drain path.

Useful? React with 👍 / 👎.

@matt2e matt2e force-pushed the kick-off-commit-sesh-from-diff branch from 1ba2742 to fbd719e Compare April 8, 2026 04:28
Add a commit session launcher to the diff modal sidebar, allowing users
to kick off commit sessions directly from the diff view. The launcher
composes a prompt with launch context (commit SHA, review ID, branch
scope) embedded as XML metadata, which is extracted at drain time to
provide the agent with relevant diff context.

Key changes:
- Commit session launcher component pinned to diff modal sidebar
- Launch context embedding/extraction in session queue pipeline
- Shared stripXmlTags utility to deduplicate XML block stripping
- Queue state awareness with live session status updates
- Commit prompt prefill extracted for reuse across entry points

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@matt2e matt2e force-pushed the kick-off-commit-sesh-from-diff branch from 02192e9 to 2dee480 Compare April 9, 2026 01:58
@matt2e matt2e merged commit d8b3ecb into main Apr 9, 2026
5 checks passed
@matt2e matt2e deleted the kick-off-commit-sesh-from-diff branch April 9, 2026 02:05
loganj added a commit that referenced this pull request Apr 9, 2026
…ktree-dis

* origin/main: (45 commits)
  feat(penpal): persist recent files activity across restarts (#595)
  feat: persist open windows, tabs, and geometry across app restarts (#588)
  feat(staged): generate next prefill text when generating notes (#594)
  feat(staged): add "Run again" button to action output dialog (#593)
  feat: queue repo sessions in project MCP with async cancellation fix (#591)
  fix(staged): lowercase "building" subtitle for consistency (#592)
  fix(staged): use completedAt for commit prefill timeline ranking (#590)
  fix: add per-branch mutex to prevent worktree setup race condition (#589)
  feat: add diff commit session launcher (#585)
  fix: avoid error state for empty titled code reviews (#587)
  fix: cancel in-flight auto reviews before manual sessions (#584)
  feat(settings): add repo context search (#583)
  fix(staged): sort timeline items by completion time so queued items appear before completed ones (#568)
  fix: drain queued branch sessions from backend lifecycle (#579)
  fix: restore resume session metadata for resumed actions (#580)
  feat(staged): add purple diff comment theme (#578)
  fix(ui): hide branch actions during setup (#572)
  fix: validate parsed PR URLs before extraction (#577)
  fix: centralize staged relative time updates (#576)
  fix: avoid UI freezes when starting background sessions (#575)
  ...

# Conflicts:
#	apps/penpal/internal/watcher/watcher.go
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