jenkins-bot has submitted this change and it was merged.

Change subject: Make setup.py py3-compatible
......................................................................


Make setup.py py3-compatible

Change-Id: I87ab31344e66fb32f604bca1cf76d6ff5cda7fd2
---
M setup.py
1 file changed, 9 insertions(+), 10 deletions(-)

Approvals:
  Xqt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/setup.py b/setup.py
index b022d2f..717771c 100644
--- a/setup.py
+++ b/setup.py
@@ -18,16 +18,14 @@
 from setuptools.command import install
 
 test_deps = []
+testcollector = "tests"
 
-if sys.version_info[0] != 2:
-    raise RuntimeError("ERROR: Pywikipediabot only runs under Python 2")
-elif sys.version_info[1] < 6:
-    raise RuntimeError("ERROR: Pywikipediabot only runs under Python 2.6 or 
higher")
-elif sys.version_info[1] == 6:
-    test_deps = ['unittest2']
-    testcollector = "tests.utils.collector"
-else:
-    testcollector = "tests"
+if sys.version_info[0] == 2:
+    if sys.version_info[1] < 6:
+        raise RuntimeError("ERROR: Pywikipediabot only runs under Python 2.6 
or higher")
+    elif sys.version_info[1] == 6:
+        test_deps = ['unittest2']
+        testcollector = "tests.utils.collector"
 
 
 class pwb_install(install.install):
@@ -67,5 +65,6 @@
     ],
     cmdclass={
         'install': pwb_install
-    }
+    },
+    use_2to3=True
 )

-- 
To view, visit https://gerrit.wikimedia.org/r/90750
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I87ab31344e66fb32f604bca1cf76d6ff5cda7fd2
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: python3
Gerrit-Owner: Merlijn van Deen <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to