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

Enable / disable Hue Motion Sensor illuminance sensor causes error #104608

Closed
Bidthedog opened this issue Nov 27, 2023 · 5 comments · Fixed by #113064
Closed

Enable / disable Hue Motion Sensor illuminance sensor causes error #104608

Bidthedog opened this issue Nov 27, 2023 · 5 comments · Fixed by #113064
Assignees

Comments

@Bidthedog
Copy link

Bidthedog commented Nov 27, 2023

The problem

Enabling / disabling the light sensor on the hue motion sensor via an automation, script or via the UI produces an error and does not enable / disable the light sensor function. I could do with this so I can get more accurate mean lux measurements, as I use the illuminance sensor to detect light levels over the last 5 / 10 mins, and turn the light on accordingly.

Enabling / disabling the motion sensor function works OK, though.

What version of Home Assistant Core has the issue?

core-2023.11.3

What was the last working version of Home Assistant Core?

No idea, sorry

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Philips Hue

Link to integration documentation on our website

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

Diagnostics information

config_entry-hue-0c657344a4772fa701b2732f8d155f31.json.txt

Example YAML snippet

No response

Anything in the logs that might be useful for us?

2023-11-27 17:24:35.299 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140073676824256] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 123, in async_request_call
    return await task(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/sensors.py", line 179, in set_enabled
    await self.update(id, MotionPut(enabled=enabled))
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/base.py", line 153, in update
    await self._bridge.request("put", endpoint, json=data)
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/__init__.py", line 177, in request
    resp.raise_for_status()
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1005, in raise_for_status
    raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')

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 230, in handle_call_service
    await hass.services.async_call(
  File "/usr/src/homeassistant/homeassistant/core.py", line 2035, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2072, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
    return await service.entity_service_call(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 876, in entity_service_call
    response_data = await _handle_entity_call(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 948, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/hue/switch.py", line 105, in async_turn_off
    await self.bridge.async_request_call(
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 134, in async_request_call
    raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')
2023-11-27 17:24:41.473 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140073676824256] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 123, in async_request_call
    return await task(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/sensors.py", line 179, in set_enabled
    await self.update(id, MotionPut(enabled=enabled))
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/base.py", line 153, in update
    await self._bridge.request("put", endpoint, json=data)
  File "/usr/local/lib/python3.11/site-packages/aiohue/v2/__init__.py", line 177, in request
    resp.raise_for_status()
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1005, in raise_for_status
    raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')

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 230, in handle_call_service
    await hass.services.async_call(
  File "/usr/src/homeassistant/homeassistant/core.py", line 2035, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2072, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
    return await service.entity_service_call(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 876, in entity_service_call
    response_data = await _handle_entity_call(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 948, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/hue/switch.py", line 99, in async_turn_on
    await self.bridge.async_request_call(
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 134, in async_request_call
    raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.3.100/clip/v2/resource/motion/dbce1c40-2d04-466b-9240-25828f2598af')

Additional information

No response

@home-assistant
Copy link

Hey there @balloob, @marcelveldt, mind taking a look at this issue as it has been labeled with an integration (hue) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of hue 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 hue 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)


hue documentation
hue source
(message by IssueLinks)

@Sectorchan
Copy link

+1 here

@r1chards
Copy link

r1chards commented Feb 3, 2024

+1 more - with a error "Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/4330ae49-7867-45be-b935-087b6b218c21')"

Thanks*)

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:238
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 22:47:48 (9 occurrences)
Last logged: 22:55:40

[140702577459264] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/4330ae49-7867-45be-b935-087b6b218c21')
[140702577459264] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/3f97dbf9-b67c-4d7d-9dfb-3df4917b6b6b')
[140702660064192] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/3f97dbf9-b67c-4d7d-9dfb-3df4917b6b6b')
[140702660064192] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/4330ae49-7867-45be-b935-087b6b218c21')
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 123, in async_request_call
return await task(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/sensors.py", line 179, in set_enabled
await self.update(id, MotionPut(enabled=enabled))
File "/usr/local/lib/python3.11/site-packages/aiohue/v2/controllers/base.py", line 153, in update
await self._bridge.request("put", endpoint, json=data)
File "/usr/local/lib/python3.11/site-packages/aiohue/v2/init.py", line 177, in request
resp.raise_for_status()
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1059, in raise_for_status
raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/4330ae49-7867-45be-b935-087b6b218c21')

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 238, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2149, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2186, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 272, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 882, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 952, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/hue/switch.py", line 105, in async_turn_off
await self.bridge.async_request_call(
File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 134, in async_request_call
raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.8.34/clip/v2/resource/motion/4330ae49-7867-45be-b935-087b6b218c21')

@yozh
Copy link

yozh commented Mar 6, 2024

Same problem here... I have this is part of my automations, and just noticed it stopped working.

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:240
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 6:08:06 PM (10 occurrences)
Last logged: 7:09:35 PM

[139848518436160] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')
[139849546413760] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')
[139848566427840] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')
[139848590481728] Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 123, in async_request_call
return await task(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiohue/v2/controllers/sensors.py", line 179, in set_enabled
await self.update(id, MotionPut(enabled=enabled))
File "/usr/local/lib/python3.12/site-packages/aiohue/v2/controllers/base.py", line 153, in update
await self._bridge.request("put", endpoint, json=data)
File "/usr/local/lib/python3.12/site-packages/aiohue/v2/init.py", line 177, in request
resp.raise_for_status()
File "/usr/local/lib/python3.12/site-packages/aiohttp/client_reqrep.py", line 1060, in raise_for_status
raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')

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 240, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2279, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2316, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 962, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/hue/switch.py", line 105, in async_turn_off
await self.bridge.async_request_call(
File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 134, in async_request_call
raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: Request failed due connection error: 404, message='Not Found', url=URL('https://192.168.1.161/clip/v2/resource/motion/b5a3ce1b-355e-403e-a0ad-442f28a2be44')

@yozh
Copy link

yozh commented Mar 8, 2024

Bump ?

@github-actions github-actions bot locked and limited conversation to collaborators Apr 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants