Skip to content

LocationData for parsers#14395

Open
dogboat wants to merge 49 commits intoDefectDojo:devfrom
dogboat:locations-dogboat-parser-metadata
Open

LocationData for parsers#14395
dogboat wants to merge 49 commits intoDefectDojo:devfrom
dogboat:locations-dogboat-parser-metadata

Conversation

@dogboat
Copy link
Contributor

@dogboat dogboat commented Feb 26, 2026

This PR updates how parser/importer interaction works for locations in V3. Rather than having parsers return lists of concrete model types, they return LocationData objects, a dataclass that can be changed separate from models. This also allows us to start tracking other data that might be useful in the future that is not tied directly to a model class; this PR introduces dependency info gathering to that end. Parsers have been updated accordingly.

A few other changes are present to locations-related models. The hash field on URL has been renamed to identity_hash and some fields have been added to Location(Finding|Product)Reference models to allow us to track data pertinent to the association between a Location and Finding/Product.

@github-actions github-actions bot added New Migration Adding a new migration file. Take care when merging. unittests parser labels Feb 26, 2026
Copy link
Contributor

@Maffooch Maffooch left a comment

Choose a reason for hiding this comment

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

Very clean implementation!

Copy link
Contributor

@mtesauro mtesauro left a comment

Choose a reason for hiding this comment

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

Approved

@valentijnscholten valentijnscholten added this to the 2.56.0 milestone Feb 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

New Migration Adding a new migration file. Take care when merging. parser unittests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants