Skip to content

Adding and Item results in a "str object has not get attribute error" on Home assistant 2025.1.3 #16

@vhamburger

Description

@vhamburger

Since updating to 2025.1.3 I get the following error in the log when adding an item to Bring:
[139859841001232] Unexpected exception Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 245, in handle_call_service response = await hass.services.async_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ...<7 lines>... ) ^ File "/usr/src/homeassistant/homeassistant/core.py", line 2795, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2838, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1006, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ hass, entity, func, data, call.context ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ) ^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1078, in _handle_entity_call result = await task ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/todo/__init__.py", line 464, in _async_add_todo_item await entity.async_create_todo_item( ...<9 lines>... ) File "/config/custom_components/bring/todo.py", line 148, in async_create_todo_item await self.coordinator.bring_api.purchase_item(item_summary, item_specification) File "/config/custom_components/bring/bring.py", line 244, in purchase_item await self.__put( ...<3 lines>... ) File "/config/custom_components/bring/bring.py", line 131, in __put await self.check_response(response) File "/config/custom_components/bring/bring.py", line 90, in check_response if result.get("errorCode"): ^^^^^^^^^^ AttributeError: 'str' object has no attribute 'get'

Any chance looking at this and correcting it? I guess it has to do with a changed python version in HA...

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