Skip to content

Conversation

@ctlai95
Copy link
Contributor

@ctlai95 ctlai95 commented Feb 4, 2025

Problem

Issues detected by auto-review feature are not populating the code issues treeview list unless you run a manual /review first.

Screenshot 2025-02-04 at 3 00 08 PM

This issue is happening because vscode.window.createTreeView is hidden inside SecurityIssuesTree class which only gets invoked when you call SecurityIssuesTree.instance.focus(). Since we don't want to focus the tree view for auto-reviews, the treeview itself is never created.

Solution

Move the treeview creation to activation so that it always gets created when the extension is activated


  • Treat all work as PUBLIC. Private feature/x branches will not be squash-merged at release time.
  • Your code changes must meet the guidelines in CONTRIBUTING.md.
  • License: I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions
Copy link

github-actions bot commented Feb 4, 2025

  • This pull request implements a feat or fix, so it must include a changelog entry (unless the fix is for an unreleased feature). Review the changelog guidelines.
    • Note: beta or "experiment" features that have active users should announce fixes in the changelog.
    • If this is not a feature or fix, use an appropriate type from the title guidelines. For example, telemetry-only changes should use the telemetry type.

@ctlai95 ctlai95 marked this pull request as ready for review February 4, 2025 23:24
@ctlai95 ctlai95 requested review from a team as code owners February 4, 2025 23:24
@jpinkney-aws
Copy link
Contributor

Going to merge this past the code freeze because teams haven't started verification and it seems important

@jpinkney-aws jpinkney-aws merged commit 69db397 into aws:master Feb 5, 2025
25 of 26 checks passed
s7ab059789 pushed a commit to s7ab059789/aws-toolkit-vscode that referenced this pull request Feb 19, 2025
## Problem

Issues detected by auto-review feature are not populating the code
issues treeview list unless you run a manual `/review` first.

<img width="1594" alt="Screenshot 2025-02-04 at 3 00 08 PM"
src="https://github.com/user-attachments/assets/4b817fad-a17e-4ce6-8374-fb81634f18b1"
/>

This issue is happening because `vscode.window.createTreeView` is hidden
inside `SecurityIssuesTree` class which only gets invoked when you call
`SecurityIssuesTree.instance.focus()`. Since we don't want to focus the
tree view for auto-reviews, the treeview itself is never created.

## Solution

Move the treeview creation to activation so that it always gets created
when the extension is activated


---

- Treat all work as PUBLIC. Private `feature/x` branches will not be
squash-merged at release time.
- Your code changes must meet the guidelines in
[CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines).
- License: I confirm that my contribution is made under the terms of the
Apache 2.0 license.
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.

4 participants