Commit ae1fbd4
authored
fix: handle missing ScanID and TaskID in AnalysisContext.AddFinding (#27)
Refactors AddFinding to populate missing ScanID and TaskID from the
analysis context.
Adds a defensive fallback to a Nil UUID if IDs are still missing,
preventing "unable to encode empty string into binary format for uuid"
errors during database persistence.
Logs a warning when the fallback is used to aid in debugging.
Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>1 parent 287d624 commit ae1fbd4
1 file changed
Lines changed: 25 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
55 | | - | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
56 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
57 | 80 | | |
58 | 81 | | |
0 commit comments