You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by bh...@apache.org on 2016/07/15 11:16:36 UTC

[1/2] cloudstack-cloudmonkey git commit: fix bug in using readline in Windows

Repository: cloudstack-cloudmonkey
Updated Branches:
  refs/heads/master 38b68fbe0 -> 319c2dc09


fix bug in using readline in Windows


Project: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/commit/3d9d7795
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/tree/3d9d7795
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/diff/3d9d7795

Branch: refs/heads/master
Commit: 3d9d7795cdc9e3337a3493f2f370d801c4b4b96b
Parents: 38b68fb
Author: Phillip Kent <ph...@xmlsoup.com>
Authored: Tue Apr 26 11:21:01 2016 +0100
Committer: Phillip Kent <ph...@xmlsoup.com>
Committed: Tue Apr 26 11:21:01 2016 +0100

----------------------------------------------------------------------
 cloudmonkey/cloudmonkey.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/blob/3d9d7795/cloudmonkey/cloudmonkey.py
----------------------------------------------------------------------
diff --git a/cloudmonkey/cloudmonkey.py b/cloudmonkey/cloudmonkey.py
index e32878e..b106362 100644
--- a/cloudmonkey/cloudmonkey.py
+++ b/cloudmonkey/cloudmonkey.py
@@ -67,7 +67,8 @@ except ImportError, e:
     print("Module readline not found, autocompletions will fail", e)
 else:
     import rlcompleter
-    if 'libedit' in readline.__doc__:
+    readline_doc = getattr(readline, '__doc__', '')
+    if readline_doc is not None and 'libedit' in readline_doc:
         readline.parse_and_bind("bind ^I rl_complete")
         readline.parse_and_bind("bind ^R em-inc-search-prev")
         normal_readline = False


[2/2] cloudstack-cloudmonkey git commit: Merge pull request #13 from phillipkent/fix_bug_windows_readline

Posted by bh...@apache.org.
Merge pull request #13 from phillipkent/fix_bug_windows_readline

fix bug in using readline in WindowsI found a bug with use of 'readline' for Python 2.7 on Windows 7. Cloudmonkey fails to run with this error:

File c:\python27\lib\site-packages\cloudmonkey\cloudmonkey.py  line 70 module>
            If libedit in readline.__doc__
TypeError:  argument of type NoneType is not iterable

It requires modification of cloudmonkey.py at line 70.

The error and fix are the same as reported here:
http://bugs.python.org/issue18852
https://hg.python.org/cpython/rev/3070fdd58645

Note: I haven't tested this for Cloudmonkey in other Windows versions, or other Python versions.

* pr/13:
  fix bug in using readline in Windows

Signed-off-by: Rohit Yadav <ro...@shapeblue.com>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/commit/319c2dc0
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/tree/319c2dc0
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack-cloudmonkey/diff/319c2dc0

Branch: refs/heads/master
Commit: 319c2dc097fcf7607d352d9fb26f13e8051074ff
Parents: 38b68fb 3d9d779
Author: Rohit Yadav <ro...@shapeblue.com>
Authored: Fri Jul 15 16:46:05 2016 +0530
Committer: Rohit Yadav <ro...@shapeblue.com>
Committed: Fri Jul 15 16:46:05 2016 +0530

----------------------------------------------------------------------
 cloudmonkey/cloudmonkey.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------