Skip to content
This repository has been archived by the owner on Jan 13, 2023. It is now read-only.

Exception when invoking help(iota) in examples/shell.py #41

Closed
todofixthis opened this issue Apr 11, 2017 · 1 comment
Closed

Exception when invoking help(iota) in examples/shell.py #41

todofixthis opened this issue Apr 11, 2017 · 1 comment
Labels

Comments

@todofixthis
Copy link
Contributor

  1. Launch examples/shell.py.
  2. Type help(iota).
In [3]: help(iota)
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
pyota/iota/api.py in __getattr__(self, command)
     97     try:
---> 98       command_class = self.commands[command]
     99     except KeyError:

KeyError: '__name__'

During handling of the above exception, another exception occurred:

InvalidCommand                            Traceback (most recent call last)
pyota/examples/shell.py in <module>()
----> 1 help(iota)

python3.6/site.py in __call__(self, *args, **kwds)
    503     def __call__(self, *args, **kwds):
    504         import pydoc
--> 505         return pydoc.help(*args, **kwds)
    506
    507 def sethelper():

python3.6/pydoc.py in __call__(self, request)
   1856     def __call__(self, request=_GoInteractive):
   1857         if request is not self._GoInteractive:
-> 1858             self.help(request)
   1859         else:
   1860             self.intro()

python3.6/pydoc.py in help(self, request)
   1909             else: doc(str, 'Help on %s:', output=self._output)
   1910         elif isinstance(request, Helper): self()
-> 1911         else: doc(request, 'Help on %s:', output=self._output)
   1912         self.output.write('\n')
   1913

python3.6/pydoc.py in doc(thing, title, forceload, output)
   1643     try:
   1644         if output is None:
-> 1645             pager(render_doc(thing, title, forceload))
   1646         else:
   1647             output.write(render_doc(thing, title, forceload, plaintext))

python3.6/pydoc.py in render_doc(thing, title, forceload, renderer)
   1618     if renderer is None:
   1619         renderer = text
-> 1620     object, name = resolve(thing, forceload)
   1621     desc = describe(object)
   1622     module = inspect.getmodule(object)

python3.6/pydoc.py in resolve(thing, forceload)
   1610         return object, thing
   1611     else:
-> 1612         name = getattr(thing, '__name__', None)
   1613         return thing, name if isinstance(name, str) else None
   1614

pyota/iota/api.py in __getattr__(self, command)
    101         '{cls} does not support {command!r} command.'.format(
    102           cls     = type(self).__name__,
--> 103           command = command,
    104         ),
    105       )

InvalidCommand: Iota does not support '__name__' command.
@todofixthis todofixthis added this to Scheduled v1.2.x in PyOTA Apr 11, 2017
todofixthis added a commit that referenced this issue Apr 24, 2017
@todofixthis todofixthis moved this from Scheduled v1.2.x to Done v1.2.0 in PyOTA Apr 24, 2017
@todofixthis
Copy link
Contributor Author

Scheduled for release: v1.2.0

@todofixthis todofixthis removed this from Done v1.2.0 in PyOTA Aug 16, 2017
marko-k0 pushed a commit to marko-k0/iota.lib.py that referenced this issue Jul 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant