inputusername / rescrobbled Goto Github PK
View Code? Open in Web Editor NEWMPRIS music scrobbler daemon
License: GNU General Public License v3.0
MPRIS music scrobbler daemon
License: GNU General Public License v3.0
It looks like rescrobbled stopped working after GNOME Music changed changed the MPRIS identity from "GnomeMusic" to "org.gnome.Music". No tracks are being submitted any more.
"systemctl --user status rescrobbled.service" only gives me:
jan 22 16:10:23 Khazam-dum systemd[3842]: Started An MPRIS scrobbler.
jan 22 16:10:24 Khazam-dum rescrobbled[64205]: Authenticated with ListenBrainz successfully!
jan 22 16:10:24 Khazam-dum rescrobbled[64205]: Looking for an active MPRIS player...
If I change the white list to "vlc" and play a track it works as expected.
Using version 0.5.0 on Ubuntu 21.10.
I successly compiled it from this page. I'm using artix linux.
https://aur.archlinux.org/packages/rescrobbled-git
However, whenever I try to launch it, I get these error messages.
rescrobbled Authenticated with Last.fm successfully! thread 'main' panicked at 'invalid url or method: Error(InvalidBaseUrl)', /home/bud/.cargo/registry/src/github.com-1ecc6299db9ec823/attohttpc-0.17.0/src/request/builder.rs:52:41 stack backtrace: note: Some details are omitted, run with
RUST_BACKTRACE=full for a verbose backtrace
Authenticated with Last.fm successfully! thread 'main' panicked at 'invalid url or method: Error(InvalidBaseUrl)', /home/bud/.cargo/registry/src/github.com-1ecc6299db9ec823/attohttpc-0.17.0/src/request/builder.rs:52:41 stack backtrace: 0: 0x56057837e1a3 - <unknown> 1: 0x5605783a3eec - <unknown> 2: 0x5605783777d5 - <unknown> 3: 0x56057837fa01 - <unknown> 4: 0x56057837f6d3 - <unknown> 5: 0x5605783800a3 - <unknown> 6: 0x56057837ff97 - <unknown> 7: 0x56057837e654 - <unknown> 8: 0x56057837fcc2 - <unknown> 9: 0x5605780270b3 - <unknown> 10: 0x560578027203 - <unknown> 11: 0x5605780acdef - <unknown> 12: 0x5605780b927d - <unknown> 13: 0x5605780addbb - <unknown> 14: 0x56057803805d - <unknown> 15: 0x56057803b701 - <unknown> 16: 0x560578039aa3 - <unknown> 17: 0x56057804d779 - <unknown> 18: 0x560578372a02 - <unknown> 19: 0x56057803b898 - <unknown> 20: 0x7fcb0403c290 - <unknown> 21: 0x7fcb0403c34a - __libc_start_main 22: 0x560578027395 - <unknown> 23: 0x0 - <unknown>
This looks like a great project, and I would love to use it.
I use libre.fm however and it doesn't seem to be supported.
I'd be more than happy to try my hand at implementing it myself in a PR as well.
I'm just not sure how quickly I'll be able to get to it.
I'm pretty busy with IRL things as well as various projects.
As a side note: Once the feature gets implemented and I start using it
(I'll most likely end up using it daily), I will also be glad to create Gentoo ebuilds for this.
Edit: I'd also be happy to make an OpenRC service too.
I used the Arch Linux AUR package to build rescrobbled
.
The process aborts with:
Compiling listenbrainz v0.4.1
Compiling rustfm-scrobble v1.1.0
Compiling rescrobbled v0.5.0 (/home/patrik/.cache/yay/rescrobbled-git/src/rescrobbled)
error[E0658]: use of unstable library feature 'duration_zero'
--> src/mainloop.rs:111:23
|
111 | if length.is_zero() {
| ^^^^^^^
|
= note: see issue #73544 <https://github.com/rust-lang/rust/issues/73544> for more information
error: aborting due to previous error
Is this an error on my/Arch's side?
rescrobbled is started by systemd and runs fine at first. But after a longer time without any active mpris player running it seems to silently die somehow.
The process itself is still running, but there is no more logging message.
strace shows this:
[pid 94080] nanosleep({tv_sec=1, tv_nsec=0}, 0x7ffe6d0cfc20) = 0
[pid 94080] sendmsg(6, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="l\1\0\1\0\0\0\0^\354\0\0b\0\0\0\1\1o\0\1\0\0\0/\0\0\0\0\0\0\0"..., iov_len=120}, {iov_base="", iov_len=0}], msg_iovlen=2, msg_controllen=0, msg_flags=0}, MSG_NOSIGNAL) = 120
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 500) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 476) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 463) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 454) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 445) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 432) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 416) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 404) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 388) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 377) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 361) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 352) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 335) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 323) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 314) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 303) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 294) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 284) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 275) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 264) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 251) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 240) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 227) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 208) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 192) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 181) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 163) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 151) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 139) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 125) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 114) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 102) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 92) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 79) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 67) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 55) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 44) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 33) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 22) = 1 ([{fd=6, revents=POLLIN}])
[pid 94080] poll([{fd=6, events=POLLIN}], 1, 11) = 1 ([{fd=6, revents=POLLIN}])
this should be easy to fix
I'm looking at packaging rescrobbled for fedora and ran into an issue with notify-rust. Apparently there are some packages in Fedora that aren't compatible with 4.5.6 due to the changes to zbus/zvariant so that is holding up the ability to upgrade to 4.5.6 or greater.
My question is will 4.5.3 for example work fine? Thanks!
Both qdbus
and playerctl
show xesam:artist
just fine.
Same rescrobbled
works fine with Firefox
on my system.
// rescrobbled --version
rescrobbled v0.6.1
// journalctl --user -fu rescrobbled
Nov 03 18:29:06 futpib-laptop rescrobbled[779855]: ----
Nov 03 18:29:06 futpib-laptop rescrobbled[779855]: Now playing: - Plein Soleil ()
Nov 03 18:29:06 futpib-laptop rescrobbled[779855]: Failed to update status on Last.fm
Nov 03 18:29:06 futpib-laptop rescrobbled[779855]: Caused by:
Nov 03 18:29:06 futpib-laptop rescrobbled[779855]: Now playing request failed: Status code 400 Bad Request indicates failure
// qdbus org.mpris.MediaPlayer2.tdesktop /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Metadata
mpris:artUrl:
mpris:length: 398000000
mpris:trackid:
xesam:artist: World's End Girlfriend
xesam:title: Plein Soleil
// playerctl -p tdesktop metadata
tdesktop mpris:artUrl
tdesktop mpris:length 398000000
tdesktop mpris:trackid '/org/desktop_app/track/0'
tdesktop xesam:artist World's End Girlfriend
tdesktop xesam:title Plein Soleil
listenbrainz-rust
depends on reqwest
and therefore pulls in a bunch of crates from the async/tokio ecosystem for no reason. I've written listenbrainz
, which uses ureq
, bringing in significantly fewer dependencies.
I have already attempted to port rescrobbled over to listenbrainz
, but it seems to randomly error sometimes when submitting songs or authenticating. Need to investigate.
Currently these files are simply read from/stored in the crate root. It would be better to use directories following the operating system's conventions, for example using dirs.
Hi, thanks for your project !
I was impatient to get support for custom listenbrainz servers since I'm a maloja user, unfortunately I couldn't manage to authenticate
Rescrobbled version is latest, built locally from source
Config (cleaned) looks like that :
[[listenbrainz]]
url = "https://my_maloja_host/apis/listenbrainz"
token = "my_token"
Url and token work in other apps.
Error is :
Authenticated with Last.fm successfully!
Failed to authenticate with ListenBrainz (https://my_maloja_host/apis/listenbrainz)
Looking for an active MPRIS player...
I can provide url and token in private if you want.
Hi! I added my API key and shared secret to ~/.config/rescrobbled/config.toml, but the terminal shows the message "Warning: no scrobbling services defined".
I tried creating a new API, but the same issue. Should I add an URL to the API request from last.fm before making it?
I don't want to scrobble from every player that sends mpris signals, so it would be helpful to read from the config file either a player whitelist or blacklist. In a little applet I use for displaying the currently played track, I use the following:
PLAYER_BLACKLIST_REGEXP = r'Gwenview|plasma-browser-integration|mpv|chromium\.instance'
This is then checked against the beginning of the player's broadcasted name (as returned by playerctl
) so that my applet can ignore anything from those players.
I think for rescrobbled, a whitelist probably makes more sense and would be simpler to implement (no real need for regex matching, just literal full matches).
Since we have a lot of Electron/Chromium based media players in the Linux world, it's hard to whitelist these, as their Identity
property always(?) has the value of "Chromium". So basically if I have three of this kind of players, I can't whitelist just one of them, as the Identity
is the same:
Lines 59 to 69 in f901d95
Using the unique D-Bus name works, but the unique part automatically changes every time the player is restarted, so it's not a long term solution.
Would it be feasible to take the whitelisting a little further to provide more control to the user?
I am using tidal-hifi as a Chromium/Electron app on Ubuntu 20.04 and only get the title/artist via MPRIS - nothing more, nothing less. To solve this, I currently only deleted the corresponding lines out of the source code and set the length to a constant of 30 seconds - which works in my case but I don't really like the solution.
I documented my changes here: Mastermindzh/tidal-hifi#11 (comment)
There should be an option to ignore the missing track length.
I get the following error for most of the songs I downloaded locally from youtube:
Failed to update status on ListenBrainz
Caused by:
API error (400): field track_metadata.release_name is empty.
Failed to submit track to ListenBrainz
Caused by:
API error (400): field track_metadata.release_name is empty.
The listenbrains documentation lists:
Which means the release_name field should be optional.
I assume the issue is that release_name gets submitted with an empty value while it should probably be omitted entirely instead.
Thanks for the awesome project and any kind of support!
With unspecified min-play-time
scrobbling happens after just a few seconds after a track starts playing. Tho if I specify min-play-time
, specified time works fine. There's some info:
Distro: Arch
Rescrobbled v0.6.2, installed with AUR
Player: Amberol (Flatpak)
config.toml
:
lastfm-key = "<key>"
lastfm-secret = "<secret>"
player-whitelist = [ "io.bassi.Amberol" ]
$ systemctl status rescrobbled --user
:
ноя 25 16:35:14 lazurit-81vw systemd[1097]: Started An MPRIS scrobbler.
ноя 25 16:35:14 lazurit-81vw rescrobbled[58317]: Authenticated with Last.fm successfully!
ноя 25 16:35:14 lazurit-81vw rescrobbled[58317]: Looking for an active MPRIS player...
ноя 25 16:35:14 lazurit-81vw rescrobbled[58317]: Found active player Amberol
ноя 25 16:35:14 lazurit-81vw rescrobbled[58317]: ----
ноя 25 16:35:14 lazurit-81vw rescrobbled[58317]: Now playing: Dion Timmer - Midnight Zone (Enter Achroma)
ноя 25 16:35:15 lazurit-81vw rescrobbled[58317]: Status updated on Last.fm successfully
ноя 25 16:35:30 lazurit-81vw rescrobbled[58317]: Track submitted to Last.fm successfully
ноя 25 16:37:36 lazurit-81vw rescrobbled[58317]: ----
ноя 25 16:37:36 lazurit-81vw rescrobbled[58317]: Now playing: Dion Timmer - Sandman Sleeps (Enter Achroma)
ноя 25 16:37:37 lazurit-81vw rescrobbled[58317]: Status updated on Last.fm successfully
ноя 25 16:37:53 lazurit-81vw rescrobbled[58317]: Track submitted to Last.fm successfully
$ playerctl status -l
:
io.bassi.Amberol
$ playerctl metadata
:
io mpris:artUrl file:///home/lazurit/.var/app/io.bassi.Amberol/cache/amberol/covers/744e9e31dac6774a7ddaa358a0451e69897a2413d9a42763a48ec2e355b65b67.png
io xesam:artist Dion Timmer
io xesam:title Sandman Sleeps
io mpris:length 230000000
io xesam:album Enter Achroma
Hi!
I'm running into the issue that seems to have been discussed before.
#10
I am running spotifyd as a systemd user service. If I start up ncspot and start playing music, rescrobbled will state Looking for an active MPRIS player...
. If I stop the spotifyd service, then rescrobbled will start scrobbling, Found active player ncspot
.
I have player-whitelist = ["ncspot"]
in my config.toml. I tried commenting that out, but it made no difference.
I'm using arch linux and the AUR package of rescrobbled.
https://aur.archlinux.org/packages/rescrobbled-git/
Hi! I wanted to let you know that I put together an AUR package of rescrobbled for ArchLinux/AUR users. https://aur.archlinux.org/packages/rescrobbled-git/ Whether or not you choose to link to it is up to you of course, I just wanted to be sure you were aware of it.
lastfm-token
should be lastfm-key
. Took me a while to find out why it wasn't working.
It would be nice to have an option like min-play-percent
that would be used something like
min-play-percent-in-seconds = ( min-play-percent / 100 ) * ( mpris:length / 1000000 )
Then have the submission time used be min-play-percent-in-seconds
or min-play-time
, whichever is set and has the highest value.
This would let a user retain an absolute minimum while adding a relative minimum, giving better control over only scrobbling what you're actually listening to.
I have 10 minute+ tracks that I'll decide I don't want to listen to 30 seconds in, as well as tracks that are 30 seconds. Setting an absolute minimum of 30 seconds would make the scrobbler blind to my shorter tracks and risk scrobbling longer tracks I'm not really listening to.
Hi,
so I installed rescrobbled and set the Last.fm API key and secret in the config.toml
file.
Upon running systemctl --user start rescrobbled.service
I would get authentication failed.
So after reading the rest of the README.md
it would require me to start the application in the terminal so I can enter my Last.fm credentials.
Now my question is: Do I still need the API key/secret of Last.fm since a token is obtained? See: "A long-lasting session token is then obtained, which will be used on subsequent runs instead of your username/password."
Anyways, thanks for creating this project. It helps with scrobbling in combination with ncspot
!
Can you help me to create a script to blacklist some artists? I don't know but maybe this one can be a nice built-in feature.
Thanks for this - it's a lifesaver. However, I'm encountering a strange and intermittent issue: occasionally, rescrobbled will scrobble the same song multiple times. An example from the logs:
Jul 22 09:30:37 rescrobbled[871790]: Now playing: Ty Segall - Hello, Hi ("Hello, Hi")
Jul 22 09:30:37 rescrobbled[871790]: Status updated on Last.fm successfully
Jul 22 09:30:38 rescrobbled[871790]: Track submitted to Last.fm successfully
Jul 22 09:32:34 rescrobbled[871790]: Track submitted to Last.fm successfully
Jul 22 09:34:30 rescrobbled[871790]: Track submitted to Last.fm successfully
Jul 22 09:36:27 rescrobbled[871790]: Track submitted to Last.fm successfully
Any advice on how to best troubleshoot or debug this?
I'm using MPV to stream radio from internet, and somehow the metadata from MPV shows only xesam:title with the artist's name in it.
Example:
> playerctl metadata
mpv xesam:url http://hits.j1fm.tokyo/
mpv mpris:trackid '/0'
mpv xesam:title Yuuki Aoi - Cupid Revue
mpv mpris:length 520019591
Is it possible to extract artist's name from xesam:title? Because somehow last.fm doesn't recognize the track because the artist name in it.
Hi, getting an "authentication failed" error:
Failed to authenticate with Last.fm
Caused by:
Authentication failed: Non Success status (403)
My config is simply:
lastfm-key = "bc7...b42"
lastfm-secret = "02b...591"
player-whitelist = ["mpd"]
The user and pass is correct and working, tested both on the website and other applications.
Hi, I'm trying to scrobble from behind a proxy, and have obtained a key and shared secret from last.fm.
On starting the application, I am prompted for a username and password. Entering these, sometimes the application hangs, sometimes I get the following message:
Failed to authenticate with Last.fm
Caused by:
Authentication failed: Connection Failed: Network is unreachable (os error 101)
Warning: no scrobbling services defined
Looking for an active MPRIS player...
Strace output, if it helps:
....
socket(AF_INET, SOCK_DGRAM|SOCK_CLOEXEC, IPPROTO_IP) = 3
connect(3, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("130.211.19.189")}, 16) = 0
getsockname(3, {sa_family=AF_INET, sin_port=htons(41452), sin_addr=inet_addr("172.xxx")}, [28 => 16]) = 0
close(3) = 0
socket(AF_INET6, SOCK_DGRAM|SOCK_CLOEXEC, IPPROTO_IP) = 3
connect(3, {sa_family=AF_INET6, sin6_port=htons(0), sin6_flowinfo=htonl(0), inet_pton(AF_INET6, "2600:1901:0:2fd6::", &sin6_addr), sin6_scope_id=0}, 28) = -1 ENETUNREACH (Network is unreachable)
close(3) = 0
socket(AF_INET, SOCK_STREAM|SOCK_CLOEXEC, IPPROTO_IP) = 3
connect(3, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("130.211.19.189")}, 16) = -1 EHOSTUNREACH (No route to host)
close(3) = 0
socket(AF_INET6, SOCK_STREAM|SOCK_CLOEXEC, IPPROTO_IP) = 3
connect(3, {sa_family=AF_INET6, sin6_port=htons(443), sin6_flowinfo=htonl(0), inet_pton(AF_INET6, "2600:1901:0:2fd6::", &sin6_addr), sin6_scope_id=0}, 28) = -1 ENETUNREACH (Network is unreachable)
close(3) = 0
write(2, "Failed to authenticate with Last"..., 35Failed to authenticate with Last.fm) = 35
write(2, "\n\nCaused by:", 12
....
Unfortunately I can't test off-proxy due to my network setup.
Any help would be appreciated. Thank you.
Hi,
rescrobbled unfortunately stopped working because Ubuntu moved from libssl1 to libssl3.
I'm now getting the following error:
./rescrobbled: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory
Should rescrobbled not switch as well?
Version: 0.6.1
OS: Ubuntu 22.10
Hey, honestly this is a life saver and I really just have one genuine issue with the scrobbler and it is the fact that I can't make it submit the scrobbles at the end of the songs. If anything that's the only thing, right now when it scrobbles midway the times are way off from when I started playing a song that lasts 4 minute started playing 6 minutes ago once submitted which is impossible. (Songs only been playing for 2 minutes!)
Honestly is there any way to just make the min-play-time the end of the current songs length for each song? It is genuinely the only thing that makes this annoying to use outside of that it is pretty much perfect.
Obviously this is the best solution for me so even if the times are incorrect, it's still useful and I will keep using it regardless. But, it would be nice if there was a way to just have the scrobbles submitted at the end of the playtime instead.
Do you know of a script that allows you to feed in ARTIST and SongInfo and have it love that track on lastfm? Everyone I've tried either didn't compile, needed libraries no longer work, or the closest I got was a perl script but it uses the old auth format that lastfm doesn't support anymore. I just need something I can run via keyboard shortcuts.
0.1.0.r12.5bd7919
I'm not sure what the correct fix for this is (might be a spotifyd
or playerctl
problem, really), but here's what I can see happening, using spotifyd 0.2.24
and playerctl 2.1.1
:
$ playerctl --list-all
spotifyd
With the following rescrobbled whitelist, spotifyd is not detected:
player-whitelist = ["spotify", "ncspot", "mopidy", "spotifyd"]
So I removed the whitelist and the rescrobbled log offered:
2020-04-05 13:15:22.923451435 Found active player Spotifyd
So I've made the whitelist:
player-whitelist = ["spotify", "ncspot", "mopidy", "Spotifyd"]
Which works fine. But I'd like whatever playerctl --list-all
reports to work as a whitelist entry. I don't know if that means using case-insensitive matching here, or if the case is inappropriately handled by either playerctl
or spotifyd
. If I specify Spotifyd
as the player to playerctl
, it does not find it.
Thanks again for this great tool!
I use KDE's Elisa player to play my music and rescrobbled to scrobble my local music to last.fm, but every time i pause and then play a song, it'll scrobble the track again.
Hello! When I first run the rescrobbled executable I get this error. Should rescrobbled just create the config file if it doesn't exist yet?
Thanks for the project, just started using it and it's working great so far!
I noticed that when the configuration file is autogenerated it has default (in my case 644
) permissions, which are readable by everyone. Since this file will likely contain authentication secrets, it would be great if it were created with 600
permissions so it's only readable by the user that runs rescrobbled.
Hi, I'm having trouble scrobbling.
I logged in with username and password as well as put my key and secret into the config file.
Anything obvious I'm doing wrong? Seems like I'm connecting to last.fm fine but just can't scrobble.
Application output:
Authenticated with Last.fm successfully!
Looking for an active MPRIS player...
Found active player Spot
----
Now playing: Porter Robinson - Divinity (Worlds)
Failed to update status on Last.fm
Any help would be greatly appreciated :)
Edit (Adding OS Details):
Fedora 35 x86_64
Installed via crates.io
Cache scrobbles when the user is offline (with a config option to enable/disable this behavior).
Based on the documentation, and me waiting for the next release for the white-list feature before using rescrobbled, it appears it's mandatory to use Last.fm, even though people might only be interested in ListenBrainz submissions.
Would it be possible to remove this requirement and allow for only a ListenBrainz account?
Build and run tests, probably using GitHub Actions.
EDIT: I wrote a very customizable python scrobbler, scrobblez
:
https://github.com/YodaEmbedding/scrobblez
Services such as Spotify and Tidal include irrelevant suffixes within their metadata. For example:
Hallowed Be Thy Name - 2015 Remaster
Hallowed Be Thy Name (2015 Remaster)
It makes sense to remove the trailing suffixes since:
A similar issue was resolved by web-scrobbler: web-scrobbler/web-scrobbler#880. They use the metadata-filter
library, available on npm, which provides some useful regexes. See here:
/**
* Filter rules to remove "Remastered..."-like strings from a text.
*/
export const REMASTERED_FILTER_RULES: FilterRule[] = [
// Here Comes The Sun - Remastered
{ source: /-\sRemastered$/, target: '' },
// Hey Jude - Remastered 2015
{ source: /-\sRemastered\s\d+$/, target: '' },
// Let It Be (Remastered 2009)
// Red Rain (Remaster 2012)
{ source: /\(Remaster(ed)?\s\d+\)$/, target: '' },
// Pigs On The Wing (Part One) [2011 - Remaster]
{ source: /\[\d+\s-\sRemaster\]$/, target: '' },
// Comfortably Numb (2011 - Remaster)
// Dancing Days (2012 Remaster)
{ source: /\(\d+(\s-)?\sRemaster\)$/, target: '' },
// Outside The Wall - 2011 - Remaster
// China Grove - 2006 Remaster
{ source: /-\s\d+(\s-)?\sRemaster$/, target: '' },
// Learning To Fly - 2001 Digital Remaster
{ source: /-\s\d+\s.+?\sRemaster$/, target: '' },
// Your Possible Pasts - 2011 Remastered Version
{ source: /-\s\d+\sRemastered Version$/, target: '' },
// Roll Over Beethoven (Live / Remastered)
{ source: /\(Live\s\/\sRemastered\)$/i, target: '' },
// Ticket To Ride - Live / Remastered
{ source: /-\sLive\s\/\sRemastered$/, target: '' },
// Mothership (Remastered)
// How The West Was Won [Remastered]
{ source: /[([]Remastered[)\]]$/, target: '' },
// A Well Respected Man (2014 Remastered Version)
// A Well Respected Man [2014 Remastered Version]
{ source: /[([]\d{4} Re[Mm]astered Version[)\]]$/, target: '' },
// She Was Hot (2009 Re-Mastered Digital Version)
// She Was Hot (2009 Remastered Digital Version)
{ source: /[([]\d{4} Re-?[Mm]astered Digital Version[)\]]$/, target: '' },
];
They also provide regex filters for other unnecessary text such as Live
, Explicit
, feat.
, and Album|Stereo|Mono|Deluxe|...
. Personally, Remastered
is the most critical, though.
I often have both cmus and ncspot running, but obviously only one is playing, and rescrobbled doesn't scrobble when one of the players is stopped
● rescrobbled.service - An MPRIS scrobbler
Loaded: loaded (/usr/lib/systemd/user/rescrobbled.service; disabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2021-11-24 17:05:11 CST; 1min 5s ago
Docs: https://github.com/InputUsername/rescrobbled
Process: 1467 ExecStart=/home/tev/.cargo/bin/rescrobbled (code=exited, status=1/FAILURE)
Main PID: 1467 (code=exited, status=1/FAILURE)
Nov 24 17:05:11 tev-GL62-6QF systemd[3087]: Started An MPRIS scrobbler.
Nov 24 17:05:11 tev-GL62-6QF rescrobbled[1467]: Username: Password: Failed to authenticate with Last.fm: Invalid authentication credential
Nov 24 17:05:11 tev-GL62-6QF systemd[3087]: rescrobbled.service: Main process exited, code=exited, status=1/FAILURE
Nov 24 17:05:11 tev-GL62-6QF systemd[3087]: rescrobbled.service: Failed with result 'exit-code'.
...skipping...
For some reason the notification for entering my Last.fm credentials never pops up when running the program in terminal. I'm on elementary 5.1 Hera
Does MPRIS expose Genre? If so it'd be nice to be able to filter on genre,
For now this project won't play well with custom scrobble servers, such as Maloja, that support ListenBrainz API.
Unfortunately, listenbrainz_rust
got the API URI hardcoded.
It's a bit of a pain to manually run the executable each time I want my music to scrobble from cmus. Is there a way to launch rescrobbled in the background as soon my computer boots, so that everything I listened to gets scrobbled by default?
I tried creating and using the systemd unit file but it didn't seem to have any effect (i.e. my tracks were't scrobbling when I checked my last.fm page). They did start scrobbling as soon as I manually launched rescrobbled from cli though, even though I had already done systemctl --user start rescrobbled.service
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.