Commits

madjar committed a756c11

Fixed helpers.confirm not working in python3. Fixes #14.

  • Participants
  • Parent commits d352d8f

Comments (0)

Files changed (1)

 import sys
 from types import GeneratorType
 
-from argh.six import b, u, string_types, text_type, BytesIO
+from argh.six import b, u, string_types, text_type, BytesIO, PY3
 from argh.exceptions import CommandError
 from argh.utils import get_subparsers
 from argh.completion import autocomplete
     ATTR_ALIAS, ATTR_ARGS, ATTR_NO_NAMESPACE, ATTR_WRAPPED_EXCEPTIONS
 )
 
+if PY3:
+    def raw_input(text):
+        return input(text.decode())
 
 __all__ = [
     'ArghParser', 'add_commands', 'autocomplete', 'dispatch', 'confirm',