-
Notifications
You must be signed in to change notification settings - Fork 19
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
feat(source): Stale/orphan scrobble and timestamp improvments #256
base: master
Are you sure you want to change the base?
Conversation
…obble on resume Clearing pre-stale listening range prevents any future resume (player becomes non-stale) from using old listening range to scrobble. Represents a physical "break" between listening sessions for the same song
Makes logs easier to read when looking for stale source/player
973efde
to
6c30135
Compare
📦 A new release has been made for this pull request.To play around with this PR, pull an image:
Images are available for x86_64 and ARM64.
|
@Fratt please try out this PR. You can specify stale after X seconds like this in [
{
"name": "MySpotify",
"data": {
// ...
"staleAfter": 60, // seconds after which Player becomes stale from no activity
"orphanedAfter": 360 // seconds after which Player becomes orphaned from no activity (removed after 2x interval)
}
}
] Though I would suggest trying it without these, first. I made a change that should prevent "resumed" plays from scrobbling again if the previous "paused" (before stale) play was scrobbled. There was a bug that let the "paused" listen time count towards the "resumed" (post-stale) listen time that has now been fixed. Also, can you remind me what platform you are using spotify on when you see it goes stale after pausing? From my own experience -- if on web/desktop and the application remains open the Player never goes stale even if paused for a long time. I haven't tested what this is like on mobile but I imagine that might be where you see it becoming stale. |
Thanks a lot! I'll try I know for a fact that it happened on mobile, indeed. But I cannot say for sure that it never happend on Desktop. (I listen 90% of the time on my phone, 10% of the time on my computer) |
I've been trying it for 2 days now, without any changes to my I will now try with
Thanks a lot! |
The default values are
The "no activity" mentioned in my previous comment means that the Source (spotify) is no longer returning any data for the unique player ID it was monitoring. This is not the same as the Player being in the same state (paused) for a long time -- it's literally "the data returned from the spotify API for Stale and Orphaned are two different levels of "what should MS do when player has no activity for X seconds"
You'd probably only want to set
would be 8 hours in seconds. But I would also like to address the double scrobble if this really is a bug, or find out if your idea of how scrobbling should work is just different from MS. From the above explanation, [1] should be working but I don't think it fits your scenario since likely your Player is being orphaned/removed. For [2] you should only see a "double scrobble" if the track you resumed still had enough time left to meet the scrobble threshold of 4 minutes. For the tracks you've seen double scrobbled, is this the case? Put plainly:
|
I will take the time to answer your points properly soon. In the meantime, I added last evening
But it seems to cause problems : It does double scrobbling even when I take a break of only 5 minutes while listening to a song, which is way worst than before :-( Any idea why? I'll rollback the config for now |
Checklist before requesting a review
Type of change
Please delete options that are not relevant.
Describe your changes