Skip to content

feat: add missing finding status helper#48

Merged
Rowuni merged 7 commits into
developfrom
feature/F4-SQLite-and-persistence
May 17, 2026
Merged

feat: add missing finding status helper#48
Rowuni merged 7 commits into
developfrom
feature/F4-SQLite-and-persistence

Conversation

@Lutow
Copy link
Copy Markdown
Collaborator

@Lutow Lutow commented May 16, 2026

Issue liée

F4

link : #5

Description

This pull request refactors and extends the findings repository functions to make them more flexible and to support updating finding statuses. The most significant changes include renaming and enhancing the findings query function to support filtering, and adding a new function to update the status of a finding.

Changements

Backend

  • Renamed list_findings to get_findings_by_scan and added support for dynamic filtering via a filters dictionary parameter, allowing queries for findings with additional criteria.
  • Added update_finding_status, a new function that updates the status of a given FindingORM object, commits the change, and refreshes the object from the database.change typing from list to Sequence, keep filtering and add the missing find status function

Frontend

  • Nothing

Checklist

  • tsc --noEmit passe sans erreur
  • Le backend démarre (uvicorn main:app)
  • Pas de secret / clé / token commité
  • Les types TypeScript sont alignés sur les modèles Pydantic
  • Les changements nécessaires à la documentation ont été faits

change typing from list to Sequence, keep filtering and add the missing find status function
@Lutow Lutow self-assigned this May 16, 2026
Copilot AI review requested due to automatic review settings May 16, 2026 16:54
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the backend repository layer to support more flexible retrieval of findings for a scan and adds a helper to update a finding’s status (aligned with issue #5’s persistence layer work).

Changes:

  • Renamed list_findings to get_findings_by_scan and added optional filters to build dynamic query predicates.
  • Added update_finding_status to persist a status change on an existing FindingORM and refresh it.

Comment thread backend/repository.py Outdated
Comment thread backend/repository.py Outdated
Comment thread backend/repository.py
Lutow and others added 3 commits May 16, 2026 18:58
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Ensure update_finding_status accepts FindingStatus and stores its canonical value.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.

Comment thread backend/repository.py Outdated
Comment thread backend/repository.py Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@Rowuni Rowuni linked an issue May 16, 2026 that may be closed by this pull request
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.

Comment thread backend/repository.py
Comment thread backend/repository.py
Comment thread backend/repository.py Outdated
@Rowuni Rowuni self-assigned this May 17, 2026
@Rowuni Rowuni merged commit 6c59992 into develop May 17, 2026
@Rowuni Rowuni deleted the feature/F4-SQLite-and-persistence branch May 17, 2026 15:49
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.

F4 - SQLite + couche de persistance

3 participants