Generalize UI events for cataloging tasks#2369
Merged
Conversation
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
wagoodman
commented
Nov 28, 2023
spiffcs
approved these changes
Nov 29, 2023
Contributor
spiffcs
left a comment
There was a problem hiding this comment.
Small nits, but if changes not needed or can be left alone feel free to auto merge =)
| Default: "Downloading go mod", | ||
| }, | ||
| HideOnSuccess: true, | ||
| ParentID: "TODO", // TODO: setting this to non-empty will cause the progress bar to be nested, but this needs to be more specific |
Contributor
There was a problem hiding this comment.
nit: Is this TODO for solving in this PR?
Contributor
Author
There was a problem hiding this comment.
yeah, I need to remove the value, but this will be taken care of fully in #1383 . The impact is that this will be another sibling task and not nested under the "cataloging packages" task.
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
spiffcs
added a commit
to coheigea/syft
that referenced
this pull request
Dec 5, 2023
* main: (40 commits) chore(deps): bump anchore/sbom-action from 0.15.0 to 0.15.1 (anchore#2392) Retrieve remote licenses using pom.properties when there is no pom.xml (anchore#2315) fix(java): improve identification for org.apache.tapestry artifacts (anchore#2384) fix(java): improve identification for io.ratpack artifacts (anchore#2379) fix(java): improve identification for org.apache.cassandra artifacts (anchore#2386) fix(java): improve identification for org.neo4j.procedure artifacts (anchore#2388) fix: bump fangs for ptr summarize fix (anchore#2387) fix(java): improve identification for org.elasticsearch artifacts (anchore#2383) fix(java): improve identification for org.apache.geode artifacts (anchore#2382) fix(java): improve identification for org.apache.tomcat.embed artifacts (anchore#2381) fix(java): improve identification for io.projectreactor.netty artifacts (anchore#2378) fix(java): improve identification for org.eclipse.platform artifacts (anchore#2349) Generalize UI events for cataloging tasks (anchore#2369) chore(deps): update tools to latest versions (anchore#2376) chore(deps): bump github.com/google/go-containerregistry (anchore#2377) chore: fix tests failing due to Mac Rosetta cache (anchore#2374) fix: improve dotnet portable executable identification (anchore#2133) fix file metadata cataloger to use resolved locations (anchore#2370) fix: logging level for parsing potential PE files (anchore#2367) only remove breaking-change label when there are schema changes (anchore#2371) ... Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
GijsCalis
pushed a commit
to GijsCalis/syft
that referenced
this pull request
Feb 19, 2024
* generalize ui events for cataloging tasks Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * moderate review comments Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * incorporate review comments Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * rename cataloger task progress object Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * migrate cataloger task fn to bus helper Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> --------- Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
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.
This PR replaces the set of events relating to cataloging down to a single event type, setting up #1383 for generalized cataloging tasks. There is no functional change to the appearance of the UI with this code change:
In the future this code reorg sets up for a set of cataloger tasks that may be related to one another in a tree-like form, expressed in the UI (see an example in anchore/bubbly#29).
Detailed changes:
PackageCatalogerStarted,FileMetadataCatalogerStarted, andFileDigestsCatalogerStartedevent types, handlers, and related tests. These are being replaced with the existingCatalogerTaskStartedevent.CatalogerTaskStartedevent handling with a new stateful handler. The handler creates and maintains a singlecatalogerTaskStateinstance. This instance is responsible for injecting new models into the bubbletea event loop.simpleHandleradapter for the existing handlers that do not raise uptea.Cmds with new models (a change brought in by Add tree-of-models bubble component bubbly#29)monitor.GenericTaskto be able to specify a task ID, a parent ID, and limited formatting optionsflatten) based on the latest bubbletea lib changesThis is a breaking change since some underlying event types have been removed from the API.
(This is work broken off of #1383 )