Skip to content

Commit c421ed8

Browse files
committed
Fix a Python exception that occurred while running the SourceKit stress tester
For reasons I don’t fully understand `subbuilder_result` can be `None`, so we can’t assign the `logfile` property here.
1 parent 40bfd73 commit c421ed8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

project.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1008,7 +1008,8 @@ def build(self, stdout=sys.stdout):
10081008
subbuilder_result = self.subbuilder.initialize(*([subtarget] + self.payload())).build(
10091009
stdout=output_fd
10101010
)
1011-
subbuilder_result.logfile = log_filename
1011+
if subbuilder_result:
1012+
subbuilder_result.logfile = log_filename
10121013
results.add(subbuilder_result)
10131014
finally:
10141015
if output_fd is not sys.stdout:

0 commit comments

Comments
 (0)