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

"stop the music" control does not work #101

Open
v0d0r opened this issue Aug 28, 2019 · 10 comments
Open

"stop the music" control does not work #101

v0d0r opened this issue Aug 28, 2019 · 10 comments

Comments

@v0d0r
Copy link

v0d0r commented Aug 28, 2019

Thanks for an awesome skill. I really enjoy this skill and would love to see it improve.
It does however not seem to listen when I tell it to stop. I believe the correct command is "stop the music"?
I can see on the terminal it does pick up the voice command. Goes silent for a moment then continues the music.
Any other logs or details I can send that will help?


play background

Just one moment while I look for that
Listening to the playlist background
stop playing music
stop the music stop the music


@forslund
Copy link
Owner

Hmm, does the more general "stop" work?

@v0d0r
Copy link
Author

v0d0r commented Aug 28, 2019

I tried it a few times now again neither stop nor stop the music works.
I tried "pause the music" now and this works first time.

@forslund
Copy link
Owner

I can reproduce to some extent...I can see that the StopMusic intents aren't registering properly, but for me the generic "stop" works.

Will continue to investigate / fix

@v0d0r
Copy link
Author

v0d0r commented Aug 29, 2019

Not urgent at all. I can live with pause. Just throwing it out there to let you know. To be honest its already exceeding my expectations. My google home speaker I cannot get to do playlists at all from spotify. It was super frustrating for a paid for product. Mycroft spotify-skill out of box first time play background and it plays it without issues. Super impressed Thanks.

@v0d0r
Copy link
Author

v0d0r commented Aug 29, 2019

Not sure if its related. But when I issue the stop command I also see a 403 to the spotify api on my terminal:

17:38:02.297 - SpotifySkill - INFO - Pausing Spotify...
17:38:03.005 - mycroft-spotify_forslund.spotify:pause:146 - ERROR - http status: 403, code:-1 - https://api.spotify.com/v1/me/player/pause?device_id=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx:

@forslund
Copy link
Owner

forslund commented Sep 2, 2019

I think I may have found a possible cause for this and have submitted a PR to mycroft-core.

@jshep321
Copy link

Hi,

I have this problem as well, with any (stop|pause|etc) keyword. I determined that my problem is a mismatched audio playback state machine. If "pause spotify" doesn't work, that means that I started spotify from a desktop client (or mobile) and the audio state comes back empty.

By speaking play spotify (while already playing) and then speaking pause spotify, it works.

I guess a periodic status query from the skill to spotify would be an easy (but inefficient) fix if there's no way to subscribe to get a push; I haven't looked at the API at all.

@forslund
Copy link
Owner

This has so far been intentionally been left out. We've decided that for now the player should only be able to affect playback if the skill started it (or if playback is taken over using "play spotify"). Mainly because another skill could be playing something on the device (news or something) while you play Spotify in another room using your phone. and a pause command would then pause both the news and Spotify.

This can perhaps be improved. The currently activated playback skill could be tracked by Mycroft and the pause could be sent directly to the playing skill if there is no playing skill it could send it globally perhaps...

The public api does not (as far as I know) support pushes.

@jshep321
Copy link

jshep321 commented Dec 7, 2019

Two suggestions that might be better just "not working":

  1. a self.speak.dialog("currently you are not in control of spotify") and/or
  2. a backend web setting (i.e. checkbox) to allow for always being in control?

@forslund
Copy link
Owner

forslund commented Dec 7, 2019

Indeed good suggestions. and possibly a handler for "stop spotify" which explicitly allows stopping (since you clearly want to stop spotify)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants