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

no device is found #310

Closed
verajosemanuel opened this issue Feb 24, 2020 · 26 comments
Closed

no device is found #310

verajosemanuel opened this issue Feb 24, 2020 · 26 comments

Comments

@verajosemanuel
Copy link

verajosemanuel commented Feb 24, 2020

installed spotifyd and spt.
run spotifyd

 ps -ef | grep spotify
jose     11868     1  0 12:40 ?        00:00:00 spotifyd
jose     11885 11656  0 12:40 pts/4    00:00:00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn spotify

run spt (installed via snap)

2020-02-24_12-42

@Rigellute
Copy link
Owner

Could be that you've logged in to a different account using spotifyd compared to the account used to create the client credientials for spotify-tui?

@verajosemanuel
Copy link
Author

Nop

@er0k
Copy link

er0k commented Feb 25, 2020

I have the same issue on debian buster

$ uname -srv
Linux 4.19.0-8-amd64 #1 SMP Debian 4.19.98-1 (2020-01-26)

$ spotifyd --version
spotifyd 0.2.24

$ spt --version
spotify-tui 0.15.0

I get "No devices found" in spotify-tui.

However, if I start spotifyd and then use the Spotify client on my phone, the spotifyd device shows in the Android client. Once I switch to the spotifyd device with the Android client, the spotifyd device appears in spotify-tui and I can use it normally. So, it seems like there may be an issue with autodiscovery between spotifyd and spotify-tui?

@Rigellute
Copy link
Owner

Hmm... spotify-tui calls the devices endpoint from the spotify api and displays that list.

Is it possible that the spotifyd client is not active when spotify-tui goes to this devices screen? We could implement some polling on that endpoint (currently the request is only made when that screen is first shown).

@Spinnerthing
Copy link

I wonder if the issue is related to spotifyd, I have been having issues with spotifyd not being viewable as a device with either the spotify web client or spt, but if I use the official spotify client on linux it can see spotifyd device and once that has seen it then spotifyd is visible to both the web client and spt.

@pablodz
Copy link

pablodz commented Feb 25, 2020

You need a spotify client open, maybe your phone, TV or other device. Premium is necessary.

@Spinnerthing
Copy link

Spinnerthing commented Feb 25, 2020

Actually for me it was a fail regarding config for spotifyd, it was in discovery mode because the username/password was not set. (Because it was not reading the conf file where I'd put it due to a typo)

@Spinnerthing
Copy link

@er0k your issue sounds like a config fail in spotifyd, when it doesn't have a valid username/password then it has a discovery mode which needs an official client to make it then become discoverable to spotify tui and even the web client.

@nachocarballeda
Copy link

You need a spotify client open, maybe your phone, TV or other device. Premium is necessary.

I solve the same issue with this reply :¬|

@Rigellute
Copy link
Owner

Closing as @ZurMaD and @nachocarballeda are correct. Premium is necessary to control playback

@breuerfelix
Copy link

same issue here.
i have the spotifyd daemon run at startup as a system service.

when i start spotify tui right after system start it is able to detect the device. if i wanna hear music some hours later it is not able to detect my spotifyd again even though it is running fine. i can start listening on that via smartphone. AFTER i hit start on the smartphone it shows up when pressing d again on spotify tui.

Seems like some idling problem to me. any advices ?

@datkush420
Copy link

I'm having the same issue as outlined above by @breuerfelix. The devices menu "d" is empty. If I open spotify on my phone and select my computer, go back to terminal and hit "d" again, the list populates and I can play music.

@breuerfelix
Copy link

@Rigellute maybe reopen this issue again ? :)

@Spinnerthing
Copy link

@breuerfelix I don't think these are issues with spotify-tui but spotifyd, @datkush420 issue sounds more like a config issue with spotifyd going in to discovery mode.

For you @breuerfelix maybe try open a bug report with spotifyd about it not being discoverable after a while of inactivity. When I had my issues I found a similar sort of problem was being discussed there too.

@breuerfelix
Copy link

breuerfelix commented May 6, 2020

@Spinnerthing i don't think the problem is spotifyd not being discoverable.
My Smartphone (fresh start or start from idle) is doing really fine with discovering the daemon on my computer :)

@Spinnerthing
Copy link

@breuerfelix interesting to hear, maybe post a new bug report with that all of that relevant information if you can't find another bug relating to it?
This issue people experienced in this bug report, me included, before was not a bug.

@datkush420
Copy link

datkush420 commented May 7, 2020

I can open the official Spotify client on any device (tablets, phones, laptops, android, ios, mac, windows, linux, etc.) and immediately see spotifyd named "rhArchLinux". Spotify-tui is the only client that can't see it. I don't see how this is an issue with spotifyd when spotify-tui is the only client having trouble seeing it.

--EDIT-- it was the spotityd config after all. The wiki said to specify an audio device to stream audio to "device = alsa_audio_device" which I had set as "pulse" but spotifyd was giving a panic "pulseaudio sink does not support specifying a device name". As soon as I removed that line it worked immediately.

Thanks for the help :)

@Spinnerthing
Copy link

@datkush420 I am glad to hear it's resolved. The discovery mode of spotifyd does easily cause confusion with spotify-tui.

@marcelbuesing
Copy link

Quote from spotify API docs:

Connect Web API relies on local network connections to discover and interact with some devices.

For example, when:

  • A new device is added to the network
  • A device is in “sleep” mode
  • A device on the local network is currently tied to another user account, or
  • Other reasons specific to the device

As a result, some devices that appear in the Connect picker within the Spotify application may not always be visible or available on the Connect Web API Endpoints.

https://developer.spotify.com/documentation/web-api/guides/using-connect-web-api/

Is there some way to programmatically do the same as the Spotify clients do for network device discovery, I assume it's something related to mdns?

@UdittLamba
Copy link

You need a spotify client open, maybe your phone, TV or other device. Premium is necessary.

that's what spotifyd is for...

@dxtr85
Copy link

dxtr85 commented Apr 21, 2022

I have both daemon and spotify-tui built from source.
TUI does not detect daemon, I can not even connect from my phone (daemon is seen from my phone).

dxtr@W540:/projects/spotifyd$ ./target/release/spotifyd --version
spotifyd 0.3.3
dxtr@W540:
/projects/spotifyd$ ../spotify-tui/target/release/spt --version
spotify-tui 0.25.0

@TornaxO7
Copy link

TornaxO7 commented Jul 3, 2022

You need a spotify client open, maybe your phone, TV or other device. Premium is necessary.

This should be added to the README in my opinion or I was just blind.

Anyways, is it possible to hear music without having the spotify-client running?

@mirachh
Copy link

mirachh commented Jan 26, 2024

Same problem. Any solution?

@TornaxO7
Copy link

@mirachh I highly recommend spotify-player since it's easier to setup and actively maintained.

@mirachh
Copy link

mirachh commented Jan 26, 2024

Thanks...

@jaketae
Copy link

jaketae commented Jan 30, 2024

Here's something that worked for me on macOS.

  1. Install spotifyd and spotify-tui
  2. Set up spotifyd (documentation)
  3. Start spotifyd via brew services start spotifyd
  4. Run spt; spotifyd should now show up as an available device

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