wlatic / hassio.addons

20 stars 16 forks source link

Error while running #8

Closed KTibow closed 3 years ago

KTibow commented 3 years ago

This is an error I'm getting. Do you know what it is?

 Add-on: Tuya Grab
 Key Grabber for Tuya Local
-----------------------------------------------------------
 Add-on version: 0.7
 You are running the latest version of this add-on.
parse error: Expected string key before ':' at line 1, column 4
[12:54:42] ERROR: Unknown HTTP error occured
 System:   (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2021.4.0b0
 Home Assistant Supervisor: 2021.03.9
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[12:54:44] INFO: Starting Auto Shutdown Timer
[12:54:44] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'
./run: line 24: echo: write error: Broken pipe
[12:54:55] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'
./run: line 24: echo: write error: Broken pipe
[12:55:06] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'
./run: line 24: echo: write error: Broken pipe
[12:55:17] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'

Thanks for looking at it.

wlatic commented 3 years ago

Looks like the docker is running fine but there is an error in tiny tuya: Check this one: https://github.com/jasonacox/tinytuya/issues/19

KTibow commented 3 years ago

Aah, thanks!

KTibow commented 3 years ago

It would be good if you could update the docs for the site redesign.

KTibow commented 3 years ago

I'm still getting an error.

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Add-on: Tuya Grab
 Key Grabber for Tuya Local
-----------------------------------------------------------
 Add-on version: 0.7
 You are running the latest version of this add-on.
parse error: Expected string key before ':' at line 1, column 4
[12:52:17] ERROR: Unknown HTTP error occured
 System:   (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2021.4.0b0
 Home Assistant Supervisor: 2021.03.9
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[12:52:19] INFO: Starting Auto Shutdown Timer
[12:52:19] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'
./run: line 24: echo: write error: Broken pipe
[12:52:30] INFO: Starting Tuya Device Capture
TinyTuya Setup Wizard [1.2.3]
    Existing settings:
        API Key=h5kt7ucjagtfypjtkenf 
        Secret=3b68ac78c8af4efdb25cf2610e651ad5
        DeviceID=877356515002910dd7b9
        Region=us
    Use existing credentials (Y/n): Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.8/site-packages/tinytuya/__main__.py", line 49, in <module>
    wizard.wizard(color)
  File "/usr/lib/python3.8/site-packages/tinytuya/wizard.py", line 206, in wizard
    uid = response_dict['result']['uid']
KeyError: 'result'
wlatic commented 3 years ago

It would be good if you could update the docs for the site redesign.

I'll get round to it! The addon is pretty much useless if I dont get the docs updated.

KTibow commented 3 years ago

You could also just recommend https://github.com/codetheweb/tuyapi/blob/master/docs/SETUP.md#listing-tuya-devices-from-the-tuya-smart-or-smart-life-apps.

KTibow commented 3 years ago

I found some working saved creds in the tuya-cli wizard. It's working.