This repository was archived by the owner on Jan 13, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 126
This repository was archived by the owner on Jan 13, 2023. It is now read-only.
Exception when invoking help(iota) in examples/shell.py #41
Copy link
Copy link
Closed
Labels
Description
- Launch
examples/shell.py. - 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.