FoxxMD / multi-scrobbler

Scrobble plays from multiple sources to multiple clients
https://foxxmd.github.io/multi-scrobbler
MIT License
299 stars 14 forks source link

Multi-scrobbler only submits the last 20 cached scrobbles to Maloja using Last.fm as a source #153

Open maluvola opened 1 month ago

maluvola commented 1 month ago
FoxxMD commented 1 month ago

Hello

This is by design. multi-scrobbler is not an application for importing your historical scrobbles from LastFM. If you'd like to import all of your scrobbles from LastFM please follow the directions in the Maloja documentation under How To Use -> Data.

multi-scrobbler is designed to be run continuously so it can monitor scrobbles in real time. The 20 scrobble value is in place to help "fill in the gaps" in the event it crashes or is stopped for some reason -- the cache is used to get any missed scrobbles during that down time. If this use case, getting that last 20 scrobbles, is not adequate for you please describe where it is failing and I may be able to address it.

Additionally, since you are running MS natively, you can adjust this value yourself to get more "cached" scrobbles, if you would like:

maluvola commented 1 month ago

Thank you. The reason I want to increase the number of cached scrobbles is that I don't keep the server on at all times, and I like to have it mirrored with Last.fm. This way, scrobbles can be submitted to Maloja after I listen to music on my phone.

FoxxMD commented 1 month ago

Then increasing the limits I mentioned should accomplish your goal. Be aware that Last.FM will return a maximum of 200 scrobbles so that's as high as the limit in LastfmSource.ts can go. You should make sure to start multi-scrobbler before you have scrobbled that many tracks since last using it.

FoxxMD commented 1 month ago

@maluvola please try pulling the develop branch. It has these changes in it:

ex lastfm.json

[
  {
    "name": "mylfm",
    "enable": true,
    "configureAs": "source",
    "data": {
    },
    "options": {
      "scrobbleBacklogCount": 100
    }
  }
]

ex maloja.json

[
  {
    "name": "default",
    "enable": true,
    "data": {
    },
    "options": {
      "refreshInitialCount": 20,
    }
  }
]

I believe this should address your issue?

maluvola commented 1 month ago

Yes, it should. Does your previous answer work as well? I made the changes but haven't listened to more than a dozen tracks yet.

FoxxMD commented 1 month ago

Yes my previous answer will still work. The new solution in develop is a configuration-based version of my previous answer. I'd suggest switching to that, eventually, so that you can continue to pull updates to MS without having to resolve file changes. I will drop a comment here when the solution is included in a full release (probably next week).