-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
0.59 breaks pychromecast #10926
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
Comments
Yeah, I've lost streaming too since upgrade. |
@mf-social are you casting to a group within HA (not the group created in home app) or just a single device? |
I haven't grouped any of the devices in HA, just in Google Home app. My configuration is simply I have 3 devices (living room, kitchen and bedroom) I have 2 groups (everywhere - all 3, and downstairs - living room and kitchen) I cannot cast to anything atm. They wake up when the Hope this is enough information, but if you need anything else let me know. |
I just reported it, I'm not a python guy lol. Hopefully someone with some knowledge on the subject can help us. Thanks for confirming. I was hoping it wasn't just because I have devices grouped in HA. I stopped using google home groups because the device ID would change randomly and I'd get occasional errors |
+1 for me. Also use Groups in GH. |
Same here Home Assistant release ( Python release ( Description of problem: Expected: Problem-relevant
Additional info: No issues when downgrading to 0.58.1 Firmware version: |
I'm also having issues with TTS to a Google Home unit, with a simple automation that triggers TTS when the garage door changes state (e.g. "Garage Door Is Open" when it opens). Worked under 0.58.1 (and prior) and Logbook shows that the automation is triggering. Only one Chromecast device, the Google Home. Getting this traceback:
|
CC @OttoWinter |
I seem to be experiencing the same issue on 0.59.1 |
Huh... That's really weird. Even more so because I myself am not experiencing any of these errors. Anyway, I'm really sorry for breaking some cast devices. Now to the error: I think it's really weird these errors are appearing when attempting play some audio and in the SocketClient class; I mean the code I changed was only used during the initialization phase and so it would be much easier to understand if the initialization of some devices failed and they wouldn't show up, but that doesn't seem to be the case here. My first guess would be that some parameter handed to SocketClient is incorrect - but the only one is cast_type which probably wouldn't cause such an error. I really currently have no idea what might be causing this. I'm currently not at home but I'll look into it more in a few hours. |
Just noticed this commit which corresponds quite well with the error (self.connecting staying set to True -> the mentioned error in the log because self.connecting is True). I don't really know why I bumped the version to 1.0.2 in my Hass PR #10728 (probably to include home-assistant-libs/pychromecast#198 - I don't know much about how pip works), but maybe somebody could try without that commit and share their results. Thx! |
Ah, sorry for CCing you @OttoWinter but thanks for trying to figure it out anyway. Would be great if someone that experiences the error can report back if that fixes it. |
I actually don't think that the referenced commit is part of the release that we included. If someone can try with reverting these changes, that might be the culprit: https://github.com/balloob/pychromecast/pull/184/files#diff-9829f5e02f299d2bfb52a4d320201b8eR820 |
@OttoWinter @balloob Issue is present on all devices except Ultra. Ultra also is the only one that still shows the volume control. My setup (diff ver from @chocomega) @OttoWinter can you compare with yours please? Side note: I did get, I believe always on 1st attempt of tts the following error:
|
So I just figured out how to recreate this issue using my Google Home Mini (version 1.28.100429). For me, after restarting Home Assistant the Home Mini works and I can play tts without a problem - though if I stop the "Default Media Playback" using the power on/off button in hass, I experience the same issue as @chocomega : Only the playback-begin chime is played but nothing else + the |
I'm now starting to think that the chime issue and SocketClient error are unrelated because I now am able to replicate the chime issue with a small script - but I'm not getting any import pychromecast
import time
import logging
logging.basicConfig(level=logging.DEBUG)
c = pychromecast.get_chromecasts()[0]
mc = c.media_controller
URL = 'https://www.soundhelix.com/examples/mp3/SoundHelix-Song-1.mp3'
print("Casting media...")
mc.play_media(URL, 'music')
time.sleep(10)
print("Stopping app...")
c.quit_app()
time.sleep(5)
print("Casting media...")
mc.play_media(URL, 'music')
time.sleep(10) (That song is just a random mp3 I snagged from the internet and does not remotely reflect my music interest 😂 ) |
Same here cannot play mp3 files keep getting: pychromecast.error.NotConnected: Chromecast is connecting... |
@balloob Ok, I just tried removing your suspected culprit home-assistant-libs/pychromecast#184 and the chime issue appears to be gone now! I guess this is because _block_till_launched only calls the callback passed to _send_launch_message if the library is in blocking mode, which it is not in home assistant. I'm not quite sure whether that will also fix the NotConnected error, but I will try that in a moment. |
Home Assistant release ( Component/platform: Description of problem: Expected:
Updating to new version
Running
|
Reverting Hass.io to 0.58.1 resolves the issue |
Currently on .58.1 I have not upgraded to 59. I am unable to get the google mini to play. I do get the google chime startup, but no audio |
I'm reverting to the old pychromecast in 0.59.2. Will give people time to figure out what is wrong with the new pychromecast version. |
Thanks all! If you need me to test anything, please let me know! |
I have now rolled back Home Assistant (Running in Docker on Synology) to 0.58.1, however my chromecast devices are still not being discovered. Any ideas? |
@jjanderson Chromecast discovery doesn't currently work inside Docker containers (zeroconf basically only listens on one interface for discovery messages). |
@OttoWinter This was working until around 58 cant remember which version it stopped wortking on, but all my Chromecast devices used to be discovered (LG Musicflows x4, Android with caster app) even the groups were discovered correctly... and that was without stipulating host or anything else, pure discovery... in fact it used to annoy me that it would actually discover things I did not want to have in the UI so actually made these hidden in my customize.yaml, so I definately know that discovery did used to work in docker |
I have discovery currently working in docker, 0.59.2, network is set to host mode though. The other issue I have is that the minis I have don't seem to play the tts sound on the first go, if i sent it I heard the notification tone and then nothing, then send it again and it plays, kind of like it needs to be woken up. |
@jjanderson Sorry, I didn't think of the import pychromecast
pychromecast.get_chromecasts() |
@danpowell That issue should be fixed via home-assistant-libs/pychromecast#202, could you try with the latest pychromecast version? |
Uh oh!
There was an error while loading. Please reload this page.
Make sure you are running the latest version of Home Assistant before reporting an issue.
You should only file an issue if you found a bug. Feature and enhancement requests should go in the Feature Requests section of our community forum:
Home Assistant release (
hass --version
):0.59
Python release (
python3 --version
):3.6
Component/platform:
pychromecast
Description of problem:
Ever since upgrade to 0.59, I get multiple tracebacks for pychromecast. Downgrading to 0.58.1 resolves the issue. Easily reproduced by running any automation that has a cast action.
Expected:
No errors
Problem-relevant
configuration.yaml
entries and steps to reproduce:not sure if this is relevant - #10728 as that is the only change to the platform I can see in the repo.
Traceback (if applicable):
Additional info:
If this is due to the firmware on cast devices and the API, I am not sure what needs to be done in HA if anything as this seems to be a breaking change with the pychromecast version bump. I only have this configuration in HA.
I also see the latest version via the setup says 1.0.2 but this link says 1.0.1 is
https://github.com/balloob/pychromecast/releases/tag/1.0.1
Maybe I'm missing something.
The text was updated successfully, but these errors were encountered: