Skip to content
This repository was archived by the owner on Jan 13, 2023. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions iota/commands/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,14 @@ def discover_commands(package, recursively=True):

commands = {}

for _, name, is_package in walk_packages(package.__path__):
for _, name, is_package in walk_packages(package.__path__, package.__name__ + '.'):
# Loading the module is good enough; the CommandMeta metaclass will
# ensure that any commands in the module get registered.
sub_package = import_module(package.__name__ + '.' + name)

# Prefix in name module move to function "walk_packages" for fix
# conflict with names importing packages
# Bug https://github.com/iotaledger/iota.lib.py/issues/63
sub_package = import_module(name)

# Index any command classes that we find.
for (_, obj) in get_members(sub_package):
Expand Down