Skip to content

SIA plugin log warning: blocking call #147380

Open
@kadavris

Description

@kadavris

The problem

Integration seem to be working, but I just saw this warning. Full trace from the log included.

BTW, also there is another problem with it:

2025-06-23 20:26:33.054 WARNING (ImportExecutor_0) [py.warnings] /usr/local/lib/python3.13/site-packages/pysiaalarm/data/data.py:7: UserWarning: pkg_resources is deprecated as an AP
I. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Set
uptools<81.
  import pkg_resources

Thanks!

What version of Home Assistant Core has the issue?

core-2025.6.1

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

SIA Alarm

Link to integration documentation on our website

https://www.home-assistant.io/integrations/sia/

Diagnostics information

No response

Example YAML snippet

Anything in the logs that might be useful for us?

2025-06-23 20:26:35.639 WARNING (MainThread) [homeassistant.util.loop] Detected blocking call to open with args ('/usr/local/lib/python3.13/site-packages/pysiaalarm/data/sia_codes.j
son', 'rb') in /usr/local/lib/python3.13/site-packages/pkg_resources/__init__.py, line 1909: return open(self._fn(self.module_path, resource_name), 'rb') inside the event loop; This
 is causing stability issues. Please create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue
For developers, please see https://developers.home-assistant.io/docs/asyncio_blocking_operations/#open
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 227, in <module>
    sys.exit(main())
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 213, in main
    exit_code = runner.run(runtime_conf)
  File "/usr/src/homeassistant/homeassistant/runner.py", line 154, in run
    return loop.run_until_complete(setup_and_run_hass(runtime_config))
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 706, in run_until_complete
    self.run_forever()
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 677, in run_forever
    self._run_once()
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 2034, in _run_once
    handle._run()
  File "/usr/local/lib/python3.13/asyncio/events.py", line 89, in _run
    self._context.run(self._callback, *self._args)
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/aio/server.py", line 54, in handle_line
    event = self.parse_and_check_event(data)
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/base_server.py", line 64, in parse_and_check_event
    event = SIAEvent.from_line(line, self.accounts)
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/event.py", line 161, in from_line
    return SIAEvent(
  File "<string>", line 28, in __init__
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/event.py", line 266, in __post_init__
    self.set_sia_code()
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/event.py", line 106, in set_sia_code
    self.sia_code = _load_sia_codes().get(self.code)  # pylint: disable=E1101
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/data/data.py", line 44, in _load_sia_codes
    data = _load_data(FILE_SIA_CODES)
  File "/usr/local/lib/python3.13/site-packages/pysiaalarm/data/data.py", line 38, in _load_data
    stream = pkg_resources.resource_stream(__name__, file)
  File "/usr/local/lib/python3.13/site-packages/pkg_resources/__init__.py", line 1387, in resource_stream
    return get_provider(package_or_requirement).get_resource_stream(
  File "/usr/local/lib/python3.13/site-packages/pkg_resources/__init__.py", line 1909, in get_resource_stream
    return open(self._fn(self.module_path, resource_name), 'rb')

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions