Commit 053b579
Discard awaitable result with explicit underscore in resiliency interceptor
CodeQL's `py/ineffectual-statement` heuristic re-flagged `await result` in
`AsyncClientResiliencyInterceptor._record_outcome` after the previous fix:
the rule treats expression statements whose value is discarded as unused, and
does not recognise that `await` is always a side-effecting suspension point
(the whole purpose of the call is to run the async recreate callback to
completion).
Rewriting the line as `_ = await result` keeps the exact same runtime
behaviour but documents the intent (return value intentionally discarded) and
satisfies the linter.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 935503f commit 053b579
1 file changed
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
152 | | - | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
153 | 156 | | |
154 | 157 | | |
0 commit comments