Closed LukasK13 closed 1 year ago
Hey there @postlund, mind taking a look at this issue as it has been labeled with an integration (apple_tv
) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)
apple_tv documentation apple_tv source (message by IssueLinks)
Same issue.
any news or updates?
Same issue
I am also facing the same issue :(. Manually set the internal_url to use http and using the plain IP, with no luck
Did you guys add the port 8123 after your internal url? - I just changed from having my URLs specified in yaml to back into the UI (because repairs told me to specify my country lol and yaml mode wasn't working for me) and forgot to add the port and it broke my HomePod TTS but I just added :8123 back to the end of the internal url and TTS is back up and running
Yes, I am using IP + port, still no luck
Same issue
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
Also reported in the beta integration: https://github.com/postlund/pyatv/issues/1884
Can someone re-test this once the new release is out?
Can someone re-test this once the new release is out?
Hi @postlund, thank you for your efforts to smash this bug! I've just installed the dev docker container and now getting a 400 error:
2023-06-29 21:54:35.226 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [139883752632080] RTSP/1.0 method SETUP failed with code 400: Bad Request
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 205, in handle_call_service
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1957, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 1997, in _execute_service
return await cast(
^^^^^^^^^^^
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 833, in entity_service_call
response_data = task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1191, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 877, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/apple_tv/media_player.py", line 300, in async_play_media
await self.atv.stream.stream_file(media_id)
File "/usr/local/lib/python3.11/site-packages/pyatv/core/facade.py", line 370, in stream_file
await self.relay("stream_file")(
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/__init__.py", line 353, in stream_file
await client.initialize(self.core.service.properties)
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/stream_client.py", line 375, in initialize
await self._protocol.setup(self.timing_client.port, self.control_client.port)
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/protocols/airplayv2.py", line 42, in setup
setup_resp = await self.rtsp.setup(
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/support/rtsp.py", line 176, in setup
return await self.exchange("SETUP", headers=headers, body=body)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/support/rtsp.py", line 293, in exchange
resp = await self.connection.send_and_receive(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/support/http.py", line 473, in send_and_receive
raise exceptions.HttpError(
pyatv.exceptions.HttpError: RTSP/1.0 method SETUP failed with code 400: Bad Request
Let me know what I can provide to help you with this!
Can someone re-test this once the new release is out?
Hi @postlund, thank you for your efforts to smash this bug!
I've just installed the dev docker container and now getting a 400 error:
2023-06-29 21:54:35.226 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [139883752632080] RTSP/1.0 method SETUP failed with code 400: Bad Request Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 205, in handle_call_service await hass.services.async_call( File "/usr/src/homeassistant/homeassistant/core.py", line 1957, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 1997, in _execute_service return await cast( ^^^^^^^^^^^ 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 833, in entity_service_call response_data = task.result() # pop exception if have ^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1191, in async_request_call return await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 877, in _handle_entity_call result = await task ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/apple_tv/media_player.py", line 300, in async_play_media await self.atv.stream.stream_file(media_id) File "/usr/local/lib/python3.11/site-packages/pyatv/core/facade.py", line 370, in stream_file await self.relay("stream_file")( File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/__init__.py", line 353, in stream_file await client.initialize(self.core.service.properties) File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/stream_client.py", line 375, in initialize await self._protocol.setup(self.timing_client.port, self.control_client.port) File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/raop/protocols/airplayv2.py", line 42, in setup setup_resp = await self.rtsp.setup( ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pyatv/support/rtsp.py", line 176, in setup return await self.exchange("SETUP", headers=headers, body=body) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pyatv/support/rtsp.py", line 293, in exchange resp = await self.connection.send_and_receive( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pyatv/support/http.py", line 473, in send_and_receive raise exceptions.HttpError( pyatv.exceptions.HttpError: RTSP/1.0 method SETUP failed with code 400: Bad Request
Let me know what I can provide to help you with this!
Huh, would not have expected that. Is this with pyatv 0.13.2?
Yes
0e1b1d444717:/config# pip show pyatv
Name: pyatv
Version: 0.13.2
Summary: A client library for Apple TV and AirPlay devices
Home-page: https://pyatv.dev
Author: Pierre Ståhl
Author-email: pierre.staahl@gmail.com
License: MIT
Location: /usr/local/lib/python3.11/site-packages
Requires: aiohttp, async-timeout, chacha20poly1305-reuseable, cryptography, ifaddr, mediafile, miniaudio, protobuf, requests, srptools, zeroconf
Required-by:
0e1b1d444717:/config# pip show homeassistant
Name: homeassistant
Version: 2023.8.0.dev20230629
Summary: Open-source home automation platform running on Python 3.
Home-page:
Author:
Author-email: The Home Assistant Authors <hello@home-assistant.io>
License: Apache-2.0
Location: /usr/local/lib/python3.11/site-packages
Editable project location: /usr/src/homeassistant
Requires: aiohttp, astral, async-timeout, atomicwrites-homeassistant, attrs, awesomeversion, bcrypt, certifi, ciso8601, cryptography, home-assistant-bluetooth, httpx, ifaddr, Jinja2, lru-dict, orjson, pip, PyJWT, pyOpenSSL, python-slugify, PyYAML, requests, typing-extensions, ulid-transform, voluptuous, voluptuous-serialize, yarl
Required-by:
Did you guys add the port 8123 after your internal url? - I just changed from having my URLs specified in yaml to back into the UI (because repairs told me to specify my country lol and yaml mode wasn't working for me) and forgot to add the port and it broke my HomePod TTS but I just added :8123 back to the end of the internal url and TTS is back up and running
I've just setup my HomePod with the UI and unable to play local media either. Core 2023.7.2
edit: I should add TTS works (after a significant delay)
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
The problem
I set up my HomePod mini using the Apple TV integration and I am able to control the volume of the HomePod and play/pause music from AppleMusic. However I am unable to play music from Home-Assistant's local media. Furthermore tts is not working as well. When trying to play an audio file (either local music or tts), the following error message is shown.
What version of Home Assistant Core has the issue?
2022.10.3
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
Apple TV
Link to integration documentation on our website
https://www.home-assistant.io/integrations/apple_tv/
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
No response