Introduction of an exception saying that we do not support Python 2 anymore.
authorfunilrys <redacted>
Thu, 26 Jul 2018 19:59:18 +0000 (21:59 +0200)
committerSteven Black <redacted>
Thu, 6 Sep 2018 03:51:27 +0000 (23:51 -0400)
This patch is the begining of https://github.com/StevenBlack/hosts/issues/729

updateHostsFile.py

index e9a10187c6181dcc009bcb9190032dfbb25226fb..c44a89796e396afa4b08eeab4ebe74325625fc74 100644 (file)
@@ -33,8 +33,7 @@ if PY3:
     from urllib.request import urlopen
     raw_input = input
 else:  # Python 2
-    from urllib2 import urlopen
-    raw_input = raw_input  # noqa
+    raise Exception('We do not support Python 2 anymore.')
 
 # Syntactic sugar for "sudo" command in UNIX / Linux
 if platform.system() == "OpenBSD":
git clone https://git.99rst.org/PROJECT