From 96ef4e0bd8a08e4f1faaa04aa99be378afa460e1 Mon Sep 17 00:00:00 2001 From: Arbitrage0 Date: Fri, 4 May 2018 12:09:49 +0100 Subject: [PATCH 1/2] Regex on Line 127 Hi, I had a feeling that the added '/' in the regex was messing up with returning the solidity version, because for me it kept returning "None", however removing that made it better. Please do check. --- ethereum/tools/_solidity.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ethereum/tools/_solidity.py b/ethereum/tools/_solidity.py index f655f7546..4af796ded 100644 --- a/ethereum/tools/_solidity.py +++ b/ethereum/tools/_solidity.py @@ -124,7 +124,7 @@ def solc_parse_output(compiler_output): def compiler_version(): """ Return the version of the installed solc. """ version_info = subprocess.check_output(['solc', '--version']) - match = re.search(b'^Version: ([0-9a-z.-]+)/', version_info, re.MULTILINE) + match = re.search(b'^Version: ([0-9a-z.-]+)', version_info, re.MULTILINE) if match: return match.group(1) From de649cfbb670f5df2f17e79f1428f66c6a71a28c Mon Sep 17 00:00:00 2001 From: Arbitrage0 Date: Sat, 5 May 2018 12:45:06 +0100 Subject: [PATCH 2/2] Update _solidity.py --- ethereum/tools/_solidity.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ethereum/tools/_solidity.py b/ethereum/tools/_solidity.py index 4af796ded..159a943db 100644 --- a/ethereum/tools/_solidity.py +++ b/ethereum/tools/_solidity.py @@ -123,7 +123,7 @@ def solc_parse_output(compiler_output): def compiler_version(): """ Return the version of the installed solc. """ - version_info = subprocess.check_output(['solc', '--version']) + version_info = subprocess.check_output(['solc', '--version'], stderr=subprocess.STDOUT) match = re.search(b'^Version: ([0-9a-z.-]+)', version_info, re.MULTILINE) if match: