Skip to content

fix(completion): execute each inline acceptance once - #94

Merged
BartvHelvert merged 1 commit into
masterfrom
fix/inline-accept-once
Nov 6, 2026
Merged

BartvHelvert merged 1 commit into
masterfrom
fix/inline-accept-once

Conversation

@BartvHelvert

Copy link
Copy Markdown
Owner

What this changes

Execute an inline completion command from the inserting client's acknowledgement in split mode. A forwarded Tab can also select a backend session; executing from both notifications could run one item's command twice when the acknowledgement consumed an earlier matching offer before the backend selection arrived. Local IDE acceptance still executes directly.

Retain the selected remote offer until the client acknowledges it, just as for a session the client's insertion ended. Add regressions for both notification orders and repeated acknowledgement.

Fixes #76

How it was tested

  • The acknowledgement-before-Tab regression fails against the original code with two executions instead of one.
  • WSL: all nine inline-completion unit tests passed, including the two new regressions; the real split-mode inline-completion UI test passed.
  • Windows CI: all nine unit tests and the real UI test passed: https://github.com/BartvHelvert/CodeBridge/actions/runs/42095737673. Temporary traces confirmed the real backend offer was associated with the remote client.
  • Temporary tracing was removed from this PR. Normal PR CI provides the full-suite check; not repeated locally.

Checklist

  • Nothing is special-cased for one extension.
  • A new feature has a UI test. Existing UI regression run; two unit regressions added.
  • No internal, override-only, obsolete or deprecated platform API.
  • docs/ is updated where behaviour changed, docs/status.md especially. Restores existing once-per-insertion behavior; no API or setup changes.
  • Third-party material keeps its notice and is listed in NOTICE.md. No third-party material added.

Let the inserting client own split-mode command execution. A forwarded Tab may select a backend session after the acknowledgement consumed an earlier matching offer; executing from both paths ran one command twice.

Refs #76
@BartvHelvert
BartvHelvert merged commit bd9de76 into master Nov 6, 2026
5 of 8 checks passed
@BartvHelvert
BartvHelvert deleted the fix/inline-accept-once branch November 6, 2026 21:01
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.

Accepting one inline completion can run its command twice

1 participant