Nothing Special   »   [go: up one dir, main page]

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

Crash on handlePlayerCommand() #150

Open
2opremio opened this issue Nov 21, 2024 · 4 comments
Open

Crash on handlePlayerCommand() #150

2opremio opened this issue Nov 21, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@2opremio
Copy link
Contributor
2opremio commented Nov 21, 2024

Using today's master:

Nov 21 15:59:51 duchamp systemd[1]: Started go-librespot.service - Yet another open-source Spotify Connect compatible client, written in Go.
Nov 21 15:59:51 duchamp go-librespot[10047]: time="2024-11-21T15:59:51Z" level=info msg="running go-librespot 0.0.0"
Nov 21 15:59:51 duchamp go-librespot[10047]: time="2024-11-21T15:59:51Z" level=info msg="api server listening on 127.0.0.1:3678"
Nov 21 15:59:51 duchamp go-librespot[10047]: time="2024-11-21T15:59:51Z" level=info msg="zeroconf server listening on port 41787"
Nov 21 15:59:51 duchamp go-librespot[10047]: time="2024-11-21T15:59:51Z" level=info msg="loading previously persisted zeroconf credentials" username=aacosta
Nov 21 15:59:52 duchamp go-librespot[10047]: time="2024-11-21T15:59:52Z" level=info msg="authenticated AP as redacted"
Nov 21 15:59:52 duchamp go-librespot[10047]: time="2024-11-21T15:59:52Z" level=info msg="authenticated Login5 as redacted"
Nov 21 15:59:59 duchamp go-librespot[10047]: panic: runtime error: invalid memory address or nil pointer dereference
Nov 21 15:59:59 duchamp go-librespot[10047]: [signal SIGSEGV: segmentation violation code=0x1 addr=0x14 pc=0x61e0cc]
Nov 21 15:59:59 duchamp go-librespot[10047]: goroutine 62 [running]:
Nov 21 15:59:59 duchamp go-librespot[10047]: main.(*AppPlayer).handlePlayerCommand(0x10ace10, {0x80a474, 0xc2ad60}, {0x4f73aa45, {0x122c330, 0x27}, {{0x1011c80, 0x8}, {0x0, 0x0}, ...}})
Nov 21 15:59:59 duchamp go-librespot[10047]:         /src/cmd/daemon/player.go:152 +0xe94
Nov 21 15:59:59 duchamp go-librespot[10047]: main.(*AppPlayer).handleDealerRequest(0x10ace10, {0x80a474, 0xc2ad60}, {0x11939c0, {0x117d740, 0x24}, {0x4f73aa45, {0x122c330, 0x27}, {{0x1011c80, ...}, ...}}})
Nov 21 15:59:59 duchamp go-librespot[10047]:         /src/cmd/daemon/player.go:347 +0xf4
Nov 21 15:59:59 duchamp go-librespot[10047]: main.(*AppPlayer).Run(0x10ace10, {0x80a474, 0xc2ad60}, 0x1090b00)
Nov 21 15:59:59 duchamp go-librespot[10047]:         /src/cmd/daemon/player.go:573 +0x4bc
Nov 21 15:59:59 duchamp go-librespot[10047]: created by main.(*App).withAppPlayer in goroutine 1
Nov 21 15:59:59 duchamp go-librespot[10047]:         /src/cmd/daemon/main.go:232 +0x37c
Nov 21 15:59:59 duchamp systemd[1]: go-librespot.service: Main process exited, code=exited, status=2/INVALIDARGUMENT

This started happening systematically a couple of days ago.

This seems to be the culprit:

		p.state.lastTransferTimestamp = transferState.Playback.Timestamp

Probably a nil pointer? I haven't had time to take a look into it and won't until next week.

@szygmunt
Copy link

Offtop: could you share your go-libtespot.service file?

@2opremio
Copy link
Contributor Author
[Unit]
Description=Yet another open-source Spotify Connect compatible client, written in Go
Documentation=https://github.com/devgianlu/go-librespot
Wants=sound.target
After=sound.target
Wants=network-online.target
After=network-online.target

[Service]
ExecStart=/home/fons/go-librespot
User=fons
Restart=always
RestartSec=5

[Install]
WantedBy=default.target

@devgianlu devgianlu added the bug Something isn't working label Nov 21, 2024
@devgianlu
Copy link
Owner

p.state cannot be nil because it is initialized before handlePlayerCommand even has a chance to be called, transferState is not a pointer, this leaves out only transferState.Playback to be nil. Makes very little sense.

@2opremio How are you transfering playback to go-librespot?

@2opremio
Copy link
Contributor Author
2opremio commented Nov 21, 2024

With https://github.com/zmb3/spotify , using my personal account. It has been working flawlessly for years with spotifyd (and up until now, for a couple of weeks, with go-librespot).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants