diff --git a/plugins/currency/ethereum/etherscan_balance_ b/plugins/currency/ethereum/etherscan_balance_ index 03c323d3..e3bc3d2b 100755 --- a/plugins/currency/ethereum/etherscan_balance_ +++ b/plugins/currency/ethereum/etherscan_balance_ @@ -110,7 +110,7 @@ except ValueError: try: eth = int(etherscan_balance['result']) -except (KeyError, ValueError) as exc: +except (KeyError, ValueError): print("JSON result error!", file=sys.stderr) sys.exit(9) diff --git a/plugins/monit/monit_parser b/plugins/monit/monit_parser index f7fb73a0..aefe5615 100755 --- a/plugins/monit/monit_parser +++ b/plugins/monit/monit_parser @@ -76,7 +76,7 @@ def get_monit_status_xml(): auth_value = "Basic %s" % auth_base64_str req.add_header("Authorization", auth_value) conn = urllib.request.urlopen(req) - except urllib.error.URLError as exc: + except urllib.error.URLError: conn = None if conn is None: raise RuntimeError("Failed to open monit status URL: {}".format(MONIT_XML_URL)) diff --git a/plugins/network/sockstat-via-procfs b/plugins/network/sockstat-via-procfs index 88afe093..8311eaa7 100755 --- a/plugins/network/sockstat-via-procfs +++ b/plugins/network/sockstat-via-procfs @@ -29,7 +29,7 @@ if len(sys.argv) > 1: print('%s.label %s' % (name, label)) sys.exit(0) -re_num = re.compile('(\d+)') +re_num = re.compile(r'(\d+)') sockstat = open('/proc/net/sockstat').read() numbers = re_num.findall(sockstat)