rytilahti / python-miio

Python library & console tool for controlling Xiaomi smart appliances
https://python-miio.readthedocs.io
GNU General Public License v3.0
3.7k stars 553 forks source link

Error with Windows x64 python #733

Closed tegger2000 closed 4 years ago

tegger2000 commented 4 years ago

Hello, i cannot flash my robot with ubuntu on VM (ERROR:miio.updater:No request was made.) I tried it on Windows, but i got this error

mirobo --ip 192.168.188.33 --token XXXXXXXXXXXX update-firmware --ip 192.168.188.63 C:\Users\example\Documents\vacuum_2008_valetudo_0_5_3.pkg
Going to update from C:\Users\example\Documents\vacuum_2008_valetudo_0_5_3.pkg
INFO:miio.updater:Serving on 0.0.0.0:21873, timeout 10
INFO:miio.updater:Using local C:\Users\example\Documents\vacuum_2008_valetudo_0_5_3.pkg (md5: 4287fe021c6119939859d3eaad5e8ceb)
Hosting file at http://192.168.188.63:21873/vacuum_2008_valetudo_0_5_3.pkg
Traceback (most recent call last):
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\example\Downloads\python3.7portable\WPy64-3760\python-3.7.6.amd64\Scripts\mirobo.exe\__main__.py", line 7, in <module>
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\click_common.py", line 59, in __call__
    return self.main(*args, **kwargs)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\core.py", line 782, in main
    rv = self.invoke(ctx)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\decorators.py", line 73, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\click\core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\vacuum_cli.py", line 610, in update_firmware
    update_res = vac.update(url, md5)
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\device.py", line 197, in update
    return self.send("miIO.ota", payload)[0] == "ok"
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\device.py", line 147, in send
    command, parameters, retry_count, extra_parameters=extra_parameters
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\miioprotocol.py", line 150, in send
    self.send_handshake()
  File "c:\users\example\downloads\python3.7portable\wpy64-3760\python-3.7.6.amd64\lib\site-packages\miio\miioprotocol.py", line 62, in send_handshake
    header = m.header.value
AttributeError: 'NoneType' object has no attribute 'header'
ERROR:miio.updater:No request was made..
rytilahti commented 4 years ago

731 should have fixed this, please reopen if it is still not working.