Commit 6c046e8
committed
Split list_runs into two literal SQL statements
Opengrep's ``python_sql_rule-hardcoded-sql-expression`` can't prove the
dynamically built SQL string in ``list_runs`` is safe even with the
parameters bound, so it keeps firing as a false positive on PR runs.
Branch the two cases (with/without source_type filter) into two fully
literal queries — no string concatenation, just placeholders — so the
rule has nothing to flag. Behaviour and test coverage unchanged.1 parent 6c0e048 commit 6c046e8
1 file changed
Lines changed: 15 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
169 | | - | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
170 | 178 | | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
182 | 185 | | |
183 | 186 | | |
184 | 187 | | |
| |||
0 commit comments