From 8fe02cb3bae12fefd95770a7caf411a520965ba5 Mon Sep 17 00:00:00 2001 From: Mats Wichmann Date: Sun, 14 Apr 2019 13:04:56 -0600 Subject: [PR #3352] fix sider complaints: bare except Sider in the CI system doesn't like the change which added a try/except block for a version without a dot. This was copied from a different file, so to fix the complaint, four instances are actually updated to "except ValueError" - I am assuming that this is the only thing that could go wrong, a version string cannot be converted with int(foo), which would throw ValueError. Signed-off-by: Mats Wichmann --- test/Java/RMIC.py | 4 ++-- test/Repository/RMIC.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/Java/RMIC.py b/test/Java/RMIC.py index 021f666..c8848e9 100644 --- a/test/Java/RMIC.py +++ b/test/Java/RMIC.py @@ -102,13 +102,13 @@ if java_version.count('.') == 1: major, minor = java_version.split('.') try: curver = (int(major), int(minor)) - except: + except ValueError: pass elif java_version.count('.') == 0: # java 11? try: curver = (int(java_version), 0) - except: + except ValueError: pass # Check the version of the found Java compiler. diff --git a/test/Repository/RMIC.py b/test/Repository/RMIC.py index 3eeab9b..aa4a57e 100644 --- a/test/Repository/RMIC.py +++ b/test/Repository/RMIC.py @@ -44,13 +44,13 @@ if java_version.count('.') == 1: major, minor = java_version.split('.') try: curver = (int(major), int(minor)) - except: + except ValueError: pass elif java_version.count('.') == 0: # java 11? try: curver = (int(java_version), 0) - except: + except ValueError: pass # Check the version of the found Java compiler. -- cgit v0.12