Skip to content

Adding ASX code A200 creates key error 0 #3

@grantclem

Description

@grantclem

When adding this ASX code to the ticker line of the yaml file the following error occurs:

TICKER: "VGS,VAS,A200"

2023-03-29 10:07:51.880121 WARNING Error: ------------------------------------------------------------
2023-03-29 10:09:17.735538 WARNING asx_sensor: ------------------------------------------------------------
2023-03-29 10:09:17.735861 WARNING asx_sensor: Unexpected error running initialize() for asx_sensor
2023-03-29 10:09:17.736096 WARNING asx_sensor: ------------------------------------------------------------
2023-03-29 10:09:17.736693 WARNING asx_sensor: Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/appdaemon/app_management.py", line 165, in initialize_app
    await utils.run_in_executor(self, init)
  File "/usr/lib/python3.10/site-packages/appdaemon/utils.py", line 337, in run_in_executor
    response = future.result()
  File "/usr/lib/python3.10/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/appdaemon/apps/utils/asx_sensor.py", line 70, in initialize
    self.load()
  File "/config/appdaemon/apps/utils/asx_sensor.py", line 138, in load
    div_y = jtags[0]['year']
KeyError: 0

It appears to happen when adding any asx code that is alpha numeric.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions