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

Introduce Snippet to Flaw conversion #388

Merged
merged 3 commits into from
Nov 30, 2023
Merged

Conversation

jobselko
Copy link
Contributor

@jobselko jobselko commented Nov 27, 2023

This PR introduces methods for converting Snippet into Flaw. As a result, it also updates the snippet's structure and its creation in the NVD collector to ease the flaw creation. The most significant change is that Snippet now uses many-to-one instead of many-to-many relationship (Flaw can be associated with many Snippet objects, but a Snippet can only have one Flaw object).

Closes OSIDB-1546

@jobselko jobselko requested a review from a team November 27, 2023 15:26
@jobselko jobselko self-assigned this Nov 27, 2023
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from 1a6cbc4 to 9c83078 Compare November 27, 2023 15:29
Copy link
Contributor

@osoukup osoukup left a comment

Choose a reason for hiding this comment

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

I have a few smaller change requests but mostly looks good.

collectors/nvd/collectors.py Outdated Show resolved Hide resolved
docs/CHANGELOG.md Outdated Show resolved Hide resolved
osidb/models.py Outdated Show resolved Hide resolved
osidb/models.py Outdated Show resolved Hide resolved
osidb/models.py Show resolved Hide resolved
@osoukup osoukup mentioned this pull request Nov 27, 2023
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from e76e3fe to 9366c2d Compare November 30, 2023 08:11
@jobselko jobselko marked this pull request as draft November 30, 2023 08:14
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from 9366c2d to 878f6a6 Compare November 30, 2023 09:02
@jobselko jobselko marked this pull request as ready for review November 30, 2023 09:08
@jobselko jobselko requested a review from osoukup November 30, 2023 09:08
Copy link
Contributor

@osoukup osoukup left a comment

Choose a reason for hiding this comment

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

I have one question I would like to clarify. Otherwise all OK.

osidb/models.py Outdated Show resolved Hide resolved
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch 2 times, most recently from 2cdcc2b to 7ccf11a Compare November 30, 2023 15:56
Copy link
Contributor

@osoukup osoukup left a comment

Choose a reason for hiding this comment

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

LGTM

@jobselko jobselko enabled auto-merge November 30, 2023 16:01
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from 7ccf11a to 1c115a8 Compare November 30, 2023 16:06
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from 1c115a8 to 1849be8 Compare November 30, 2023 16:34
@jobselko jobselko force-pushed the convert_snippet_to_flaw branch from 1849be8 to 6f37db1 Compare November 30, 2023 16:50
@jobselko jobselko added this pull request to the merge queue Nov 30, 2023
Merged via the queue into master with commit fa1d095 Nov 30, 2023
11 checks passed
@jobselko jobselko deleted the convert_snippet_to_flaw branch November 30, 2023 17:02
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