Skons / hassio-addons

7 stars 4 forks source link

Unknown error #36

Closed EvertJob closed 1 year ago

EvertJob commented 1 year ago

Hi,

I'm getting the following error and don't see what's wrong.

[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: Dutch gas prices
 Get gas prices from dutch gas stations
-----------------------------------------------------------
 Add-on version: 2022.3.25.1
 You are running the latest version of this add-on.
 System: Debian GNU/Linux 11 (bullseye)  (amd64 / qemux86-64)
 Home Assistant Core: 2022.12.7
 Home Assistant Supervisor: 2022.12.0
-----------------------------------------------------------
 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... 
Log level is set to INFO
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[18:52:53] ERROR: Got unexpected response from the API: Service not enabled
[18:52:54] INFO: Log_level: info
[18:52:54] INFO: mqtt_host: 
[18:52:54] INFO: mqtt_port: 
[18:52:54] INFO: Starting dutch gas prices...
Traceback (most recent call last):
  File "/app/main.py", line 25, in <module>
    start(str(sys.argv[1]),str(sys.argv[2]),str(sys.argv[3])) 
IndexError: list index out of range
[cmd] /run.sh exited 1
[cont-finish.d] executing container finish scripts...
[cont-finish.d] 99-message.sh: executing... 
-----------------------------------------------------------
                Oops! Something went wrong.

 We are so sorry, but something went terribly wrong when
 starting or running this add-on.

 Be sure to check the log above, line by line, for hints.
-----------------------------------------------------------
[cont-finish.d] 99-message.sh: exited 0.
[cont-finish.d] done.
[s6-finish] waiting for services.
[s6-finish] sending all processes the TERM signal.
Skons commented 1 year ago

It seems you have not configured an mqqt server

EvertJob commented 1 year ago

Yeah, just saw it. Got the sensor working once. See it on the MQTT server on the logs but no response in Home Assistant:

service: mqtt.publish
data:
  topic: 'dgp/gas_stations'
  payload_template: >-
    {"fuel_type":"euro98","radius":15,"latitude":{{state_attr("person.evert",
    "latitude") }},"longitude":{{state_attr("person.evert",
    "longitude") }},"to_publish":5}
[2022-12-18 20:08:11] INFO    : Received payload '{"fuel_type":"diesel","radius":15,"latitude":x,"longitude":v,"to_publish":3}' on topic 'dgp/gas_stations'
[2022-12-18 20:10:18] INFO    : Received payload '{"station_id":6577,"fuel_type":"diesel"}' on topic 'dgp/gas_station'

Edit: After 5 minutes I'm getting response, Is that the correct response time??

Skons commented 1 year ago

You mean it takes 5 minutes from request to publish? You can see the progress that’s made in the logging of the addon. Due to tesseract being used as image processor, and depending on the number of gas stations and the hardware used: yeah 5 minutes can be correct…