Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: populate tree [IDE-712] #218

Merged

Conversation

bastiandoetsch
Copy link
Contributor

@bastiandoetsch bastiandoetsch commented Nov 15, 2024

Description

Working:

  • it adds nodes and issues (not in the right order and has lots of bugs still)
  • file navigation
  • range highlighting of issue
  • issue description retrieval
  • correct population of info nodes
  • correct population of product nodes & content root (=project) nodes
  • caching per folder (I hope)

TODO:

  • lots of testing to SnykToolView
  • lots of testing of the differen tree nodes
  • suffix counts
  • styling
  • not all project icons are retrieved correctly (whysoever, it's always juice shop)
  • severity sorting & severity icons in IssueTreeNode

Current version:
image
image

Checklist

  • Tests added and all succeed
  • Linted
  • CHANGELOG.md updated
  • README.md updated, if user-facing

Screenshots / GIFs

Visuals that may help the reviewer. Please add screenshots for any UI change. GIFs are most welcome!

@bastiandoetsch bastiandoetsch requested a review from a team as a code owner November 15, 2024 16:46
@ShawkyZ ShawkyZ changed the title Feat/ide 712 populate tree feat: populate tree [IDE-712] Nov 18, 2024
@ShawkyZ
Copy link
Contributor

ShawkyZ commented Nov 20, 2024

Stylings and additional tests will be done in a followup PR.

import java.util.Arrays;
import java.util.Objects;

public class PublishDiagnostics316Param {
Copy link
Contributor

Choose a reason for hiding this comment

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

fyi: this was added to mitigate performance issues when deserializing for every issue

@ShawkyZ ShawkyZ merged commit 4a658cd into feat/IDE-711_create_a_new_snyk_view Nov 20, 2024
4 checks passed
@ShawkyZ ShawkyZ deleted the feat/IDE-712_populate-tree branch November 20, 2024 14:58
ShawkyZ added a commit that referenced this pull request Nov 25, 2024
* feat: add view with tree view, browser and toolbar buttons

* feat: added initial text and image to browser view. No styling!

* fix: added buttons and handlers for product activation

* fix: update the string for use in Eclipse

* feat: Added Tree and View Menu

* tidy: fix imports

* fix: cleanup image when plugin is shuting down

* feat: enable/disable products, viewmenu buttons and preferencepage

* fix: added filters to preferencesstore

* fix: added handlers for each severity

* chore: remove JAVASE-21 from manifest

* feat: add interfaces and first functionality to retrieve html

* fix: tests

* fix: use basehandler for handlers

* tidy: rename rootobject to rootnode

* feat: updated viewmenu and added handlers for stop scan and clear cache commands

* feat/IDE-712_populate-the-tree-view-with-publish-diagnostics-data-from-IaC,-Open-Source-and-Code,-using-a-local-cache (#215)

* chore: wip

* fix: add info nodes for no issues found and no fixable issues found

* fix: tests

* feat: add initial tree filling impl

* feat: display info nodes

* feat: add generic filter method to cache

* feat: show view when scanning

* feat: choose the right icon for root nodes in the treeview

* tidy: remove the open preference action, replaced by preference handler

* fix: removed conflicting handlers

* feat/clear cache on command

* fix: move strings to bundle.properties

* fix: also clear scanstate when clearing cache

* fix: added a SnykIcon class for all imagedescriptors and added collaps/expand treeviewer.

* feat: adding logic for fixable issues filter.

* fix: updated UX to use enabled/disabled icons

* chore: added unit test for BaseTreeNode

* tidy: make fixable comments more clear

* fix: update lsconfiguration when preferences has been updated

* tidy: reformat unit tests

* fix: call ui updates after state updates

* fix: handle enable/disable of tree filters

* fix: remove unneeded ImageDescriptorProvider

* fix: update Ignores Preferences and some tidying

* feat: populate tree [IDE-712] (#218)

* feat: add project level

* fix: tests

* feat: add file & issue nodes (wip)

* feat: add issue navigation

* fix: add missing icons

* fix: node filtering

* fix: create custom publishDiagnostic for faster deserilization

* fix: use Webview2 browser on Windows

* chore: added comment

* wip: cancel all scans

* tidy: clean up unused things

* fix: clean up tree when scan is cancelled

* fix: expand treenodes after product nodes are added to tree

* fix: added unit tests for progressmanager

* fix: indentation

* fix: dont run progress cancellation in UI

---------

Co-authored-by: Knut Funkel <knut.funkel@snyk.io>
Co-authored-by: Abdelrahman Shawki Hassan <shawki.hassan@snyk.io>

* fix: progress manager and tests (#222)

* Fix/tests (#223)

fix: tests on command line

* feat: add product node suffixes (#224)

* feat: new setting for consistent ignores [IDE-714] (#221)

* feat: prepending the treenodes for ignores and AI Fix with identifier

* fix: added space after ignore tag

* feat: add a call to read feature flags, and call that function to read snykCodeConsistentIgnores

* fix: expand treeviewer to show all issues.

* fix: wip remvoe ignores filters if needed

* fix: rename file

* fix: call featureflag service after auth and settings persistence

* fix: notifyProgress if param is null

* feat: taskprocessor for sending tasks after ls init

* fix: tests use current pref

* feat: filter issues based on ignore preferences

* fix: remove commands if ff for ignores are false

* fix: adding the handlers and commands for filters

* fix: adding an asyncExec on the ui updates

---------

Co-authored-by: Abdelrahman Shawki Hassan <shawki.hassan@snyk.io>

* feat: style description panel (#220)

* wip: html provider

* fix: populate tree after snyk.Scan success

* refactor: use css from LS

* wip: html provider

* fix: merge conflicts

* fix: added HtmlProviderFactory tests

* fix: use comperator for sorting issues

* refactor: create BrowserHandler

* fix: cache theme instance

* fix: cache test

* fix: HtmlProviderTest doesn't extend LsBaseTest

* fix: ignore calling workbench if in test

* fix: assert nonexisting string

* fix: publishDiagnostics tests

* fix: dont get workbench if test

---------

Co-authored-by: Bastian Doetsch <bastian.doetsch@snyk.io>
Co-authored-by: Abdelrahman Shawki Hassan <shawki.hassan@snyk.io>
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