diff options
author | Angelos Evripiotis <jevripiotis@bloomberg.net> | 2019-06-06 11:23:16 +0100 |
---|---|---|
committer | bst-marge-bot <marge-bot@buildstream.build> | 2019-06-06 16:49:36 +0000 |
commit | ed51c482ff86478e0130086705b5618f70fab6da (patch) | |
tree | 6ec117b1f0492fb8df68f9058d11dddc5c615f02 /src/buildstream/_frontend | |
parent | b216febd888f2b7ab763db0045ac5736d0a9a16a (diff) | |
download | buildstream-ed51c482ff86478e0130086705b5618f70fab6da.tar.gz |
Use 'is' when comparing against JobStatusaevri/job_msg_enum
Since JobStatus is an enum, it's clearer to compare using 'is' -
equality comparison will fail in the same cases, but might lull folks
into thinking that comparison with integer would also work.
Diffstat (limited to 'src/buildstream/_frontend')
-rw-r--r-- | src/buildstream/_frontend/app.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/buildstream/_frontend/app.py b/src/buildstream/_frontend/app.py index d4ea83871..7aff52af6 100644 --- a/src/buildstream/_frontend/app.py +++ b/src/buildstream/_frontend/app.py @@ -526,7 +526,7 @@ class App(): # Dont attempt to handle a failure if the user has already opted to # terminate - if status == JobStatus.FAIL and not self.stream.terminated: + if status is JobStatus.FAIL and not self.stream.terminated: if isinstance(job, ElementJob): element = job.element |