Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to check off list items using Mealie integration #132038

Open
kmanning514 opened this issue Dec 2, 2024 · 2 comments
Open

Unable to check off list items using Mealie integration #132038

kmanning514 opened this issue Dec 2, 2024 · 2 comments
Assignees

Comments

@kmanning514
Copy link

The problem

I am able to add new items to a shopping list that is connected to mealie, and verified they show up there. However, if I attempt to check off an item as completed I get an error. I am not sure if this is the proper place to submit this, or if there is a section specifically for the mealie integration:

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(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2802, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2845, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1007, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1079, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/todo/init.py", line 505, in _async_update_todo_item
await entity.async_update_todo_item(item=TodoItem(**updated_data))
File "/usr/src/homeassistant/homeassistant/components/mealie/todo.py", line 196, in async_update_todo_item
raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: An error occurred updating an item in TESTMEALIE
2024-12-01 22:16:03.045 DEBUG (MainThread) [homeassistant.components.mealie] Finished fetching MealieStatistics data in 0.018 seconds (success: True)
2024-12-01 22:16:07.950 DEBUG (MainThread) [homeassistant.components.mealie] Finished fetching MealieShoppingList data in 0.119 seconds (success: True)
2024-12-01 22:16:07.950 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140065286795424] Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/mealie/todo.py", line 192, in async_update_todo_item
await self.coordinator.client.update_shopping_item(
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 278, in update_shopping_item
await self._put(
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 155, in _put
return await self._request(METH_PUT, uri, data=data, params=params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 110, in _request
raise MealieValidationError(
aiomealie.exceptions.MealieValidationError: ('Mealie validation error', {'response': '{"detail":[{"type":"uuid_parsing","loc":["body","foodId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}},{"type":"uuid_parsing","loc":["body","labelId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}},{"type":"uuid_parsing","loc":["body","unitId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}}]}'})

The above exception was the direct cause of the following 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(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2802, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2845, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1007, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1079, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/todo/init.py", line 505, in _async_update_todo_item
await entity.async_update_todo_item(item=TodoItem(**updated_data))
File "/usr/src/homeassistant/homeassistant/components/mealie/todo.py", line 196, in async_update_todo_item
raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: An error occurred updating an item in TESTMEALIE
2024-12-01 22:16:45.848 DEBUG (MainThread) [homeassistant.components.mealie] Finished fetching MealieShoppingList data in 0.127 seconds (success: True)
2024-12-01 22:16:52.884 DEBUG (MainThread) [homeassistant.components.mealie] Finished fetching MealieShoppingList data in 0.122 seconds (success: True)
2024-12-01 22:16:56.981 DEBUG (MainThread) [homeassistant.components.mealie] Finished fetching MealieShoppingList data in 0.709 seconds (success: True)
2024-12-01 22:16:56.982 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140065286795424] Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/mealie/todo.py", line 192, in async_update_todo_item
await self.coordinator.client.update_shopping_item(
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 278, in update_shopping_item
await self._put(
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 155, in _put
return await self._request(METH_PUT, uri, data=data, params=params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 110, in _request
raise MealieValidationError(
aiomealie.exceptions.MealieValidationError: ('Mealie validation error', {'response': '{"detail":[{"type":"uuid_parsing","loc":["body","foodId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}},{"type":"uuid_parsing","loc":["body","labelId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}},{"type":"uuid_parsing","loc":["body","unitId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of urn:uuid: followed by [0-9a-fA-F-], found N at 1"}}]}'})

The above exception was the direct cause of the following 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(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2802, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2845, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1007, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1079, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/todo/init.py", line 505, in _async_update_todo_item
await entity.async_update_todo_item(item=TodoItem(**updated_data))
File "/usr/src/homeassistant/homeassistant/components/mealie/todo.py", line 196, in async_update_todo_item
raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: An error occurred updating an item in TESTMEALIE

What version of Home Assistant Core has the issue?

core-2024.11.3

What was the last working version of Home Assistant Core?

not sure if it is version related, or config related

What type of installation are you running?

Home Assistant Supervised

Integration causing the issue

Mealie (HACS)

Link to integration documentation on our website

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

Diagnostics information

config_entry-mealie-01JE2REJY5Y4T6S1QCX30Q1V7Q.json

Example YAML snippet

No response

Anything in the logs that might be useful for us?

File "/usr/local/lib/python3.12/site-packages/aiomealie/mealie.py", line 110, in _request
    raise MealieValidationError(
aiomealie.exceptions.MealieValidationError: ('Mealie validation error', {'response': '{"detail":[{"type":"uuid_parsing","loc":["body","foodId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1"}},{"type":"uuid_parsing","loc":["body","labelId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1"}},{"type":"uuid_parsing","loc":["body","unitId"],"msg":"Input should be a valid UUID, invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1","input":"None","ctx":{"error":"invalid character: expected an optional prefix of `urn:uuid:` followed by [0-9a-fA-F-], found `N` at 1"}}]}'})

The above exception was the direct cause of the following exception

Additional information

No response

@home-assistant
Copy link

home-assistant bot commented Dec 2, 2024

Hey there @joostlek, @andrew-codechimp, mind taking a look at this issue as it has been labeled with an integration (mealie) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of mealie can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign mealie Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


mealie documentation
mealie source
(message by IssueLinks)

@andrew-codechimp
Copy link
Contributor

Hi, you reported this in the right place!

This was identified last week and a fix #131951 is going into 2024.12 which should sort this.

@joostlek joostlek modified the milestone: 2024.12.0 Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants