After the scan is finished, the GetFindings call is used to retrieve the findings of the scan. When doing a revised scan after resolving some findings in your code, this API call still returns the (now closed) findings and are marked with status=Closed.
This status currently isn't actively used by the codeguru Python module in the Docker image. Because of this, the output file generated includes closed findings. The SARIF and SAST formats however don't include the finding status, so you have no way to differentiate it yourself.
The GetFinding call supports the status argument which allows retrieving only open findings, which I think would be the best solution to resolve the issue.
After the scan is finished, the GetFindings call is used to retrieve the findings of the scan. When doing a revised scan after resolving some findings in your code, this API call still returns the (now closed) findings and are marked with status=Closed.
This status currently isn't actively used by the codeguru Python module in the Docker image. Because of this, the output file generated includes closed findings. The SARIF and SAST formats however don't include the finding status, so you have no way to differentiate it yourself.
The GetFinding call supports the status argument which allows retrieving only open findings, which I think would be the best solution to resolve the issue.