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

Update cve status options and apply updates across test fixtures #186

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

mtruj013
Copy link
Contributor

@mtruj013 mtruj013 commented Dec 5, 2024

Done

  • Updated cve statuses to replace "active" with "in-progress"

QA

  • Check out this feature branch
  • Run the site using the command dotrun
    • If you get errors in this step, stop and restart the docker container then try dotrun again
  • View the site locally in your web browser at: http://0.0.0.0:8030/security/cves.json
  • See that the endpoint returns without error and that the default CVE status is "in-progress" instead of "active"

Issue / Card

Fixes https://warthogs.atlassian.net/browse/WD-15029

@mtruj013 mtruj013 marked this pull request as draft December 5, 2024 20:38
@mtruj013
Copy link
Contributor Author

mtruj013 commented Dec 5, 2024

Bug to be fixed: Running migration is throwing the following error psycopg2.errors.InvalidTextRepresentation: invalid input value for enum cve_statuses: "active"

@petesfrench
Copy link
Contributor

What I have done:

  • unzipped 'sample-security-data.sql.gz' and updated 'active' to 'in-progress'
  • added db as an import as the 'generate-sample-security-data.py' was complaining
  • removed enum as a sqlalchemy import to appease the linter gods

Copy link
Contributor

@petesfrench petesfrench left a comment

Choose a reason for hiding this comment

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

LGTM, just a question to clarify something. Might be my lack on context but maybe a more detailed comment would help future devs

response = self.client.get("/security/cves.json")

assert response.status_code == 200
# Only the CVE with the default status should be returned
Copy link
Contributor

Choose a reason for hiding this comment

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

What is the default status? in progress?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants