Last.fm plugin not submitting scrobbles when track has finished
Before posting
Please follow the steps below and check the boxes with [x] once you did the step.
- [x] I checked the issue tracker for similar issues
- [x] I checked the changelog if the issue is already resolved
- [ ] I tried the latest Clementine build from here
System information
Please provide information about your system and the version of Clementine used.
- Operating System: Arch Linux
- Clementine version: 1.4 rc2
Expected behaviour / actual behaviour
It submits the data showing that I'm currently scrobbling a track but when the track elapses, it does not appear to have been submitted that it was completed
Steps to reproduce the problem (only for bugs)
listen to a track with the lastfm plugin running
I have the same problem.
I CONFIRM!!! Very sad thing!!! Should I rollback to some earlier version?
upd: I downgraded from 350 to 250, didn't help. It may be an issue on Last.fm side, though I see tracks submitted earlier from another player (mobile).
upd2: downgraded from 250 to 170 (1.4-). Still no luck. This is very frustrating because I have probably to use another player until the issue is solved. Very sad because Clementine is the best one.
upd3: well, Amarok is no more, Exaile is uninstallable, so I took Ubuntu's Rhythmbox. It worked. So, this is clearly a Clementine's issue, waiting for fix!!!
Hello ssrublev. Do you know any player for kde?
Confirmed here as well.
Hello ssrublev. Do you know any player for kde?
Hello! I don't really distinguish them by DE, I used to think that any software may be run in any DE... When I rarely start KDE I tend to use Clementine...
The things look now more strange. The report I wrote yesterday was from Ubuntu MATE (latest version). That was at PC I use rarely. Now I am at my main PC with my main OS Fedora Linux (also latest non-beta version 5.8.16-200.fc32.x86_64).
On 5.8.16-200.fc32.x86_64 Fedora Linux clementine.x86_64 1.4.0rc1-2.344.gad354276b.fc32 scrobbles to Last.fm properly! Has to be something with OS, probably.
I found a quickfix
Run
sudo mkdir ~/.local/share/Last.fm
Works then by the looks of it, gonna look for something more permanent
(edit) the issue seems to lie with Liblastfm but I dunno
creating Last.fm dir didn't work for me :( Still see tracks in "scrobbling now" state, and then they disappear without being scrobbled.
creating Last.fm dir didn't work for me :( Still see tracks in "scrobbling now" state, and then they disappear without being scrobbled.
@eignatenkov Did you create the Last.fm directory using the exact command danielh2942 provided? With sudo included? If you did, I think I know why it's not working for you. When you type the command danielh2942 suggested using sudo, it will create the directory, but give ownership of the directory to root. I don't believe Clementine can access directories owned by root. You can see who has ownership of the directory by running this command:
ls -ld ~/.local/share/Last.fm
If it shows this:
drwxr-xr-x 2 root root
Then that means the directory is indeed owned by root and can't be accessed by Clementine. You can fix this by removing the directory and then create it again using danielh2942's command, but this time without sudo. First remove the directory:
sudo rm -r ~/.local/share/Last.fm
Then create it again, this time without sudo:
mkdir ~/.local/share/Last.fm
You can verify the directory has the correct permissions by running the ls command again:
ls -ld ~/.local/share/Last.fm
It should look something like this:
drwxr-xr-x 2 your-username your-username
With "your-username" of course being your actual user's name. If the permissions are correct, you should be able to scrobble from Clementine now. I can confirm that this fix is still working. I've scrobbled around 14 tracks so far and haven't run into any issues. Hope it works for you! :)
yep, it worked, thank you very much.
OH YES!!! Worked for me also and I again can use this great software (Clementine). Thanks so much!
@nichii124 success!!! thank youuu!! this had been bugging me for awhile.
Can confirm that this issue still exists as of 1.4.0rc1-510-g3f34b332c (Ubuntu 20.10 64-bit). apt purge and reinstall makes no difference, neither does deleting ~/.config/Clementine/.
@nichii124's solution works as a temporary workaround.
Related https://support.last.fm/t/clementine-tracks-appear-as-scrobbling-now-but-no-longer-get-scrobbled/37451/4
@danielh2942
Can you edit the command you provided to mkdir ~/.local/share/Last.fm without sudo? Otherwise it won't work for any sane setup where the user doesn't have sudo write access and that might confuse some users who come here to find the workaround.
@danielh2942 Can you edit the command you provided to
mkdir ~/.local/share/Last.fmwithoutsudo? Otherwise it won't work for any sane setup where the user doesn't have sudo write access and that might confuse some users who come here to find the workaround.
Yeah
Confirmed. As of today (2021.04.26) creating ~/.local/share/Last.fm as your user (not as sudo or root) does indeed create a successful scrobble on last.fm. Clementine v1.4 rc2 on Manjaro. Hate Manjaro but too lazy to install pure arch.
Just to add my +1 and say that a) the issue still persists on latest Manjaro/Clementine - i've used Clementine on various distros over the years without a hitch - and b) the workaround works so i'm a happy man :-)
I can confirm that creating ~/.local/share/Last.fm fixes the problem with scrobbling for me with 1.4.0~rc1+git347-gfc4cb6fc7+dfsg-1build1 on Ubuntu 21.04.
Can also confirm, creating ~/.local/share/Last.fm fixed it on Clementine 1.4.0rc1+495+g10bf5dc17-3` as packaged by Arch. Maybe to close this issue, Clementine should just create that directory if it does not exist once scrobbling is enabled?
Works great, thanks! :+1:
Hopefully, we can close this, if the internal don't think need some PR.
~/.local/share/Last.fm will work for me. I will confirm from manjaro and clementine 14.0.rc2 some played songs are listed on my last.fm account. But I do an additional step, which is to re-login my last fm account. I think the clear indication is the UI show love button instead of a star. :)
to close this what was stated by @ioistired should remove this bug, but when is the codebase doing the logging?
Remember when closing this, there are kinda duplicate issue #3994 which was opened by our issue importer. I am already reading, and that's is basically an older version of this thread but already confirmed as a bug. So please when closing do both, CMIIW.
Anyone knows how to solve this issue in windows 10? I have read that I need to create a Last.fm directory but I have no idea where I need to create it on Windows.
EDIT: Forgot to mention, I am using Clementine 1.4.0rc1-737-g69fd49b97 with a "data" folder on it, making it portable that way.
Other Edit: I managed to make this to work for me. In order to have Clementine scrobble tracks on Windows you need to create a folder at: %HOMEPATH%\AppData\Local\Last.fm ... if you are using a Portable version of Clementine, you need to create that folder none the less, because it is what liblastfm uses.
for a bit more information, see: https://github.com/lastfm/liblastfm/blob/master/src/misc.cpp#L58
Workaround not working on Ubuntu 20.04.2 :(
ls -ld ~/.local/share/Last.fm
returns
drwxrwxr-x
Not sure where to go from here.
Workaround not working on Ubuntu 20.04.2 :(
ls -ld ~/.local/share/Last.fmreturns
drwxrwxr-xNot sure where to go from here.
maybe try
sudo chmod -R 777 ~/.local/share/Last.fm/
Anyone knows how to solve this issue in windows 10? I have read that I need to create a Last.fm directory but I have no idea where I need to create it on Windows.
EDIT: Forgot to mention, I am using Clementine 1.4.0rc1-737-g69fd49b97 with a "data" folder on it, making it portable that way.
Other Edit: I managed to make this to work for me. In order to have Clementine scrobble tracks on Windows you need to create a folder at: %HOMEPATH%\AppData\Local\Last.fm ... if you are using a Portable version of Clementine, you need to create that folder none the less, because it is what liblastfm uses.
for a bit more information, see: https://github.com/lastfm/liblastfm/blob/master/src/misc.cpp#L58
Thank you very much for this! It worked for me also.
Confirming that this problem still exists in the Windows build of 1.4.0rc1-814-g2b340da79 (running under Windows 11) and that the workaround above also works. Even if this is an issue with the plugin, perhaps Clementine could check for the missing directory when the plugin is enabled and create it if it's missing?
I.e., as in this code?
for a bit more information, see: https://github.com/lastfm/liblastfm/blob/master/src/misc.cpp#L58
I faced the problem after upgrading to Ubuntu 22.04. Workaround with ~/.local/share/Last.fm worked for me.
It really have been fixed here https://github.com/lastfm/liblastfm/blob/2ce2bfe1879227af8ffafddb82b218faff813db9/src/misc.cpp#L85, but the fix is not included in package liblastfm5-1 (1.0.9-1.2). Manual update to liblastfm 1.1.0-4 solves the issue.
The workaround suggested earlier didn't work for me, the directory is already there (and it even has a file called <last_fm_username>_subs_cache.xml).
The folder was created automatically and the permissions look ok. I installed Clementine using the latest (release candidate) .deb file for the bullseye distribution.
Oh hi, same issue here. I've only just noticed, new build of linux mint (21) with Clementine newly installed... used to work fine, but also: it scrobbles "Now Playing", but then something goes wrong and it doesn't commit... 😿
I'll take a look through the suggestions here and try find solution Thanks everyone for your ideas
creating Last.fm dir didn't work for me :( Still see tracks in "scrobbling now" state, and then they disappear without being scrobbled.
@eignatenkov Did you create the Last.fm directory using the exact command danielh2942 provided? With sudo included? If you did, I think I know why it's not working for you. When you type the command danielh2942 suggested using sudo, it will create the directory, but give ownership of the directory to root. I don't believe Clementine can access directories owned by root. You can see who has ownership of the directory by running this command:
ls -ld ~/.local/share/Last.fmIf it shows this:
drwxr-xr-x 2 root rootThen that means the directory is indeed owned by root and can't be accessed by Clementine. You can fix this by removing the directory and then create it again using danielh2942's command, but this time without sudo. First remove the directory:
sudo rm -r ~/.local/share/Last.fmThen create it again, this time without sudo:
mkdir ~/.local/share/Last.fmYou can verify the directory has the correct permissions by running the
lscommand again:ls -ld ~/.local/share/Last.fmIt should look something like this:
drwxr-xr-x 2 your-username your-usernameWith "your-username" of course being your actual user's name. If the permissions are correct, you should be able to scrobble from Clementine now. I can confirm that this fix is still working. I've scrobbled around 14 tracks so far and haven't run into any issues. Hope it works for you! :)
I confirm that the problem still persists and the only solution found is the one presented above by @nichii124
*Clementine Version 1.4 rc2 (Ubuntu)
Ubuntu 22.04, fresh install with 1.4 rc2 and the issue still presents, and the fix presented by @nichii124 fixed the problem.