diff options
author | Manish Kumar <manishjpiet@gmail.com> | 2020-09-06 14:59:12 +0530 |
---|---|---|
committer | Ghanshyam Mann <gmann@ghanshyammann.com> | 2020-09-06 14:14:09 +0000 |
commit | 5d82a025077322fe024f3670e013d27897a4e680 (patch) | |
tree | cbddcebb91477bbd437586edd8c476949d293831 | |
parent | 6ff0187d334b6967b9de776d2f1276c0d10685d1 (diff) | |
download | osprofiler-5d82a025077322fe024f3670e013d27897a4e680.tar.gz |
Fix StopIteration error on Ubuntu Focalvictoria-em3.4.0
As per victoria cycle testing runtime and community goal,
we need to migrate upstream CI/CD to Ubuntu Focal(20.04).
StopIteration error happening in pep8 job when running on Focal.
we can see the failure in https://review.opendev.org/#/c/744331/
Change-Id: Iecdd3bfddb95adec77f8581f844cfc74ca59fc73
Story: #2007865
Task: #402207
-rw-r--r-- | osprofiler/hacking/checks.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/osprofiler/hacking/checks.py b/osprofiler/hacking/checks.py index b31a47d..2723210 100644 --- a/osprofiler/hacking/checks.py +++ b/osprofiler/hacking/checks.py @@ -73,7 +73,10 @@ def skip_ignored_lines(func): line = logical_line.strip() if not line or line.startswith("#") or line.endswith("# noqa"): return - yield next(func(logical_line, filename)) + try: + yield next(func(logical_line, filename)) + except StopIteration: + return return wrapper |