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

Error: player command failed no active device found #46

Open
mseiringer opened this issue Nov 10, 2021 · 3 comments
Open

Error: player command failed no active device found #46

mseiringer opened this issue Nov 10, 2021 · 3 comments

Comments

@mseiringer
Copy link

Hi everyone!
We are getting this error and don't know how to solve it.
"player command failed no active device found"
We are grateful for all your tips. THANKS!

@267industries
Copy link

Hi everyone,
We are getting the same error. Could some help us out please?
Thank you in advance.

@appsbymansa
Copy link

Same problem here... Have you found a solution?

@Jwho303
Copy link

Jwho303 commented May 13, 2023

I found that you can gather the devices before playing. It's a hack but just to get over to the next step. you gather the devices and then pass them into the request

               DeviceResponse devices = await client.Player.GetAvailableDevices();
                string s = $" Devices: {devices.Devices.Count}";
				for (int i = 0; i < devices.Devices.Count; i++)
				{
                    s += $"\n{devices.Devices[i].Name}";

				}
                Debug.Log(s);

                // Play track in context of the playlist
                PlayerResumePlaybackRequest request = new PlayerResumePlaybackRequest()
                {
                    ContextUri = _contextUri,
                    OffsetParam = new PlayerResumePlaybackRequest.Offset() { Uri = _track.Uri },
                    DeviceId = devices.Devices[0].Id
                };
                await client.Player.ResumePlayback(request);

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

4 participants