Skip to content

miplug discover throws exception #339

Closed
@ghost

Description

Running miplug discover results in exception:

miplug discover
Traceback (most recent call last):
  File "/home/pi/.local/bin/miplug", line 11, in <module>
    sys.exit(cli())
  File "/home/pi/.local/lib/python3.5/site-packages/miio/click_common.py", line 53, in __call__
    return self.main(*args, **kwargs)
  File "/home/pi/.local/lib/python3.5/site-packages/click/core.py", line 697, in main
    rv = self.invoke(ctx)
  File "/home/pi/.local/lib/python3.5/site-packages/click/core.py", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/pi/.local/lib/python3.5/site-packages/click/core.py", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/pi/.local/lib/python3.5/site-packages/click/core.py", line 535, in invoke
    return callback(*args, **kwargs)
  File "/home/pi/.local/lib/python3.5/site-packages/miio/plug_cli.py", line 50, in discover
    miio.Plug.discover()
AttributeError: 'function' object has no attribute 'discover'

Same error happens on android (termux, python 3.6.5), raspberry pi (Python 3.5.3), and macos (Python 3.6.5).

I tried removing the released pip version and installed instead from master with

pip3 install git+https://github.com/rytilahti/python-miio

but still getting the same error.

Reproducible with current master: fb595be

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions