Carglglz / upydev

Command line tool for MicroPython devices
https://pypi.org/project/upydev/
MIT License
57 stars 9 forks source link

-h doesn't work #3

Closed maho closed 4 years ago

maho commented 4 years ago
(.venv) maho@udlaptop:~/workspace/upydev$ upydev -h
Traceback (most recent call last):
  File "/home/maho/workspace/garageopen/.venv/bin/upydev", line 7, in <module>
    exec(compile(f.read(), __file__, 'exec'))
  File "/home/maho/workspace/upydev/upydev_dir/bin/upydev", line 1432, in <module>
    parser.add_argument("-@", help=help_dv, required=False).completer = ChoicesCompleter(see_global_devs())
  File "/home/maho/workspace/upydev/upydev_dir/bin/upydev", line 197, in see_global_devs
    with open('{}/UPY_G.config'.format(upydev.__path__[0]), 'r', encoding='utf-8') as group:
FileNotFoundError: [Errno 2] No such file or directory: '/home/maho/workspace/upydev/upydev/UPY_G.config'
maho commented 4 years ago

last working revision is 60470b1

Carglglz commented 4 years ago

Hi @maho

Thanks for the report.

The error is because there is no global 'UPY_G.config' group file yet, do:

upydev make_group -g -f UPY_G -devs esp_room1 192.168.1.42 mypass

or substitute 192.168.1.42 and mypass for the actual ip and password of the device. This will make -h works again.

But yes I already fix this in the next commit (which I've just pushed) and then I will upload version 0.1.8 to Pypi)

Carglglz commented 4 years ago

Just release version 0.1.8, so this bug should be already fixed .