Open radim-kliment opened 10 months ago
Have you removed the anonymized Configuration section, or does it just not show?
Do you really have a backtick after ENABLE_WEBSOCKET=true
in your Docker Compose file, or is that an error in pasting the output here?
@koenvervloesem I updated anonymised conf. Backtick removed it is an error by pasting it there.
Ok with your edited backtrace I can see now that the error seems to happen in the Bluetooth adapters section. I'm not sure why this happens. Do you have the same error if you run python3 -m TheengsGateway.diagnose
directly on your Raspberry Pi, not in a Docker container?
Ok with your edited backtrace I can see now that the error seems to happen in the Bluetooth adapters section. I'm not sure why this happens. Do you have the same error if you run
python3 -m TheengsGateway.diagnose
directly on your Raspberry Pi, not in a Docker container?
yes
/usr/lib/python3.9/runpy.py:127: RuntimeWarning: 'TheengsGateway.diagnose' found in sys.modules after import of package 'TheengsGateway', but prior to execution of 'TheengsGateway.diagnose'; this may result in unpredictable behaviour
warn(RuntimeWarning(msg))
# Theengs Gateway Diagnostics
## Package Versions
| Name | Value |
|--------------------|--------|
| Theengs Gateway | 1.2.0 |
| Theengs Decoder | 1.6.7 |
| Bleak | 0.21.1 |
| Bluetooth Clocks | 0.2.0 |
| Bluetooth Numbers | 1.1.1 |
| Paho MQTT | 1.6.1 |
| Bluetooth Adapters | 0.16.0 |
## Python
| Name | Value |
|----------------|---------------------|
| Version | 3.9.2 |
| Implementation | CPython |
| Compiler | GCC 10.2.1 20210110 |
| Executable | /usr/bin/python3 |
## Operating System
| Name | Value |
|--------------|----------------------------------------|
| System | Linux |
| Release | 6.1.21-v7+ |
| Version | #1642 SMP Mon Apr 3 17:20:52 BST 2023 |
| Machine type | armv7l |
## Configuration
File: /root/theengsgw.conf
Configuration file not found
## Bluetooth adapters
Default adapter: hci0
### hci0
| Name | Value |
|--------------|-------------------------|
| address | B8:27:EB:XX:XX:XX |
| sw_version | raspberrypi |
| hw_version | usb:v1D6Bp0246d0537 |
| passive_scan | 0 |
| manufacturer | Raspberry Pi Foundation |
Traceback (most recent call last):
File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/usr/local/lib/python3.9/dist-packages/TheengsGateway/diagnose.py", line 190, in <module>
asyncio.run(diagnostics(config_path))
File "/usr/lib/python3.9/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
return future.result()
File "/usr/local/lib/python3.9/dist-packages/TheengsGateway/diagnose.py", line 172, in diagnostics
await _adapters()
File "/usr/local/lib/python3.9/dist-packages/TheengsGateway/diagnose.py", line 155, in _adapters
_section(adapter, properties) # type: ignore[arg-type]
File "/usr/local/lib/python3.9/dist-packages/TheengsGateway/diagnose.py", line 55, in _section
print(f"| {name:{max_name}} | {value:{max_value}} |")
TypeError: unsupported format string passed to NoneType.__format__
I verified this on a Raspberry Pi and found the error. Fixed in https://github.com/theengs/gateway/pull/206, which will be in the next Theengs Gateway release.
In the meantime changing your log level to INFO may solve the issue
In the meantime changing your log level to INFO may solve the issue
Thanks, I solved it for now by disabling internal rpi bluetooth adapter and use external usb bluetooth dongle.
Describe the bug After a start of a service via docker compose I get this error:
Environment last version of docker and docker compose on raspberry pi 3b yml:
Additional context