Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
Perfect5th committed Nov 27, 2024
1 parent afa3bdf commit ca1a16d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion landscape/lib/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,10 @@ def fake():
try:
deferred = f(*args, **kwargs)

if hasattr(deferred, "result") and isinstance(deferred.result, Failure):
if (
hasattr(deferred, "result")
and isinstance(deferred.result, Failure)
):
# Required for some failures to get GC'd properly flushed.
# Twisted did this in versions < 24.10, but now we have to.
deferred.result.cleanFailure()
Expand Down

0 comments on commit ca1a16d

Please sign in to comment.