nes: show thumbsdown icon for previously rejected NES in log tree#309408
Merged
nes: show thumbsdown icon for previously rejected NES in log tree#309408
Conversation
Previously rejected NES entries now show a 👎 icon instead of no specific icon. Uses direct outcome assignment to avoid false warnings on the succeeded→previouslyRejected transition. Also registers the rebasedEdit (when present) with the rejection collector.
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the Copilot inline edits (NES) logging UI to clearly indicate when a suggestion was previously rejected, by introducing a dedicated log outcome and icon and wiring it up from the provider logic.
Changes:
- Added a thumbs-down icon and mapped a new
previouslyRejectedlog outcome to it. - Introduced
markAsPreviouslyRejected()onInlineEditRequestLogContextto set the new outcome without triggering outcome-transition warnings. - Updated
NextEditProviderto mark log contexts as previously rejected and to rejectrebasedEditwhen present.
Show a summary per file
| File | Description |
|---|---|
| extensions/copilot/src/platform/inlineEdits/common/utils/utils.ts | Adds a new thumbs-down icon definition for log rendering. |
| extensions/copilot/src/platform/inlineEdits/common/inlineEditLogContext.ts | Adds previouslyRejected outcome, icon mapping, and a setter method to apply it. |
| extensions/copilot/src/extension/inlineEdits/node/nextEditProvider.ts | Marks relevant flows as previously rejected and ensures rebased edits are collected for rejection. |
Copilot's findings
Comments suppressed due to low confidence (1)
extensions/copilot/src/extension/inlineEdits/node/nextEditProvider.ts:340
- New behavior is introduced for the “previously rejected” paths (setting a distinct log outcome and rejecting
rebasedEditwhen present), but there doesn’t appear to be test coverage validating it. Please add/extendNextEditProvidertests to cover: (1) a cached edit markedrejectedresults in the log context being marked previously rejected, and (2) when a cached rejected edit hasrebasedEdit, that exact edit is passed toRejectionCollector.reject.
const cachedEdit = this._nextEditCache.lookupNextEdit(docId, documentAtInvocationTime, selections);
if (cachedEdit?.rejected) {
logger.trace('cached edit was previously rejected');
telemetryBuilder.setStatus('previouslyRejectedCache');
telemetryBuilder.setWasPreviouslyRejected();
logContext.markAsPreviouslyRejected();
const rejectedEdit = cachedEdit.rebasedEdit ?? cachedEdit.edit;
if (rejectedEdit) {
this._rejectionCollector.reject(docId, rejectedEdit);
}
- Files reviewed: 3/3 changed files
- Comments generated: 2
…ogContext.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
jrieken
approved these changes
Apr 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously rejected NES entries now show a 👎 icon instead of no specific icon. Uses direct outcome assignment to avoid false warnings on the succeeded→previouslyRejected transition. Also registers the rebasedEdit (when present) with the rejection collector.