jenkins-bot has submitted this change and it was merged.
Change subject: (bug 59970) show clear error message if httplib2 is not found ......................................................................
(bug 59970) show clear error message if httplib2 is not found
and suggest to git submodule update --init to get it
Change-Id: I6abae2d811311e340f3756d6084c461faff1b3dc --- M pwb.py 1 file changed, 8 insertions(+), 0 deletions(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/pwb.py b/pwb.py index 86c9b9e..b07b0e9 100644 --- a/pwb.py +++ b/pwb.py @@ -103,6 +103,14 @@ os.path.join(rewrite_path, 'externals') ] + sys.path[1:]
+# try importing the known externals, and raise an error if they are not found +try: + import httplib2 +except ImportError as e: + print("ImportError: %s" % e) + print("Did you clone without --recursive? Try running 'git submodule update --init'.") + sys.exit(1) + if "PYWIKIBOT2_DIR" not in os.environ: os.environ["PYWIKIBOT2_DIR"] = os.path.split(__file__)[0]
pywikibot-commits@lists.wikimedia.org