Skip to content

Fix attestation commit in webview view#8839

Merged
alexr00 merged 3 commits into
mainfrom
alexr00/widespread-mastodon
Jul 15, 2026
Merged

Fix attestation commit in webview view#8839
alexr00 merged 3 commits into
mainfrom
alexr00/widespread-mastodon

Conversation

@alexr00

@alexr00 alexr00 commented Jul 13, 2026

Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings July 13, 2026 13:26
@alexr00 alexr00 self-assigned this Jul 13, 2026

Copilot AI 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.

Pull request overview

This PR fixes approval-with-attestation behavior when approving from the webview’s dropdown/context menu by threading the addAttestation flag through the webview context and ensuring the approve command path can create/push the attestation commit and splice the resulting timeline event without a full refresh.

Changes:

  • Include addAttestation in the webview context used by the review submit dropdown/context menu.
  • Extend review context/command argument types to optionally carry addAttestation.
  • Update approve command handlers (overview panel + active PR view) to optionally create an attestation commit and pass through additional timeline events.
Show a summary per file
File Description
webviews/components/comment.tsx Adds addAttestation into the data-vscode-context payload for the review dropdown/context menu.
src/github/views.ts Extends ReviewCommentContext with optional addAttestation to support passing the flag through context-menu commands.
src/github/pullRequestOverview.ts Updates overview-panel approve command path to optionally create an attestation commit and forward additional timeline events.
src/github/activityBarViewProvider.ts Updates active PR view approve command path to optionally create an attestation commit and forward additional timeline events.

Review details

  • Files reviewed: 4/4 changed files
  • Comments generated: 1
  • Review effort level: Low

Comment thread src/github/pullRequestOverview.ts Outdated
@alexr00
alexr00 enabled auto-merge (squash) July 13, 2026 14:34
Copilot AI review requested due to automatic review settings July 13, 2026 14:35

Copilot AI 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.

Review details

  • Files reviewed: 4/4 changed files
  • Comments generated: 0 new
  • Review effort level: Low

@alexr00
alexr00 disabled auto-merge July 13, 2026 14:48
Copilot AI review requested due to automatic review settings July 15, 2026 09:53
@alexr00
alexr00 enabled auto-merge (squash) July 15, 2026 09:53

Copilot AI 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.

Review details

  • Files reviewed: 4/4 changed files
  • Comments generated: 4
  • Review effort level: Low

Comment on lines 629 to 631
<ContextDropdown
optionsContext={() => makeCommentMenuContext(owner, repo, number, availableActions, pendingCommentText, shouldDisableNonApproveButtons)}
optionsContext={() => makeCommentMenuContext(owner, repo, number, availableActions, pendingCommentText, shouldDisableNonApproveButtons, addAttestation)}
defaultAction={defaultSubmitAction}
Comment on lines 808 to 810
<ContextDropdown
optionsContext={() => makeCommentMenuContext(pr.owner, pr.repo, pr.number, availableActions, pr.pendingCommentText, shouldDisableNonApproveButtons)}
optionsContext={() => makeCommentMenuContext(pr.owner, pr.repo, pr.number, availableActions, pr.pendingCommentText, shouldDisableNonApproveButtons, addAttestation)}
defaultAction={defaultSubmitAction}
Comment on lines +988 to +994
private async approvePullRequestCommand(context: SubmitReviewArgs): Promise<void> {
const result = context.addAttestation
? await addAttestationCommit(this._folderRepositoryManager, this._item)
: undefined;
if (context.addAttestation && !result) {
return;
}
Comment on lines +409 to +415
private async approvePullRequestCommand(context: SubmitReviewArgs): Promise<void> {
const result = context.addAttestation
? await addAttestationCommit(this._folderRepositoryManager, this._item)
: undefined;
if (context.addAttestation && !result) {
return;
}
@alexr00
alexr00 merged commit 62f3d5e into main Jul 15, 2026
8 checks passed
@alexr00
alexr00 deleted the alexr00/widespread-mastodon branch July 15, 2026 09:59
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.

3 participants