Giter Site home page Giter Site logo

lastfm_downloader's Introduction

A tool to create a CSV of all your last.fm scrobbles ever

https://mathieuhendey.com/2020/10/download-all-your-historical-last.fm-data/

The last.fm only lets you generate reports up to a year back, this tool will let you download all your scrobbles in a CSV format with the artist, song, and the timestamp.

From here you can do cool things like plot your top 20 artists on a graph using plot.py. Make sure you've run downloader.py first, or you won't have any data to plot!

scrobbles plot

Or see how many times you've listened to a specific song:

rg "little wing" data/lastfm_scrobbles.csv| wc -l
      33

Read the source code for downloader.py, it has some information about setting up your credentials.

N.B. this can take a long time. The script prints out an estimated time remaining, but for a large last.fm history (e.g. 280,000 scrobbles) you're going to be looking at about an hour.

lastfm_downloader's People

Contributors

mathieuhendey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

lastfm_downloader's Issues

Thegy

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like
A clear and concise description of what you want to happen.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Stopped working?

Describe the bug
Downloader only downloads a very small subset of my scrobbles

To Reproduce
Install dependencies and run downloader.py

Expected behavior
Downloader downloads all my scrobbles.

Desktop (please complete the following information):

  • OS: OSX Big Sur

Additional context
I suspect this is NOT a problem with the script but a change in Lastfm's API. I tried to download my scrobbles but I'm only getting 203 results from 444k scrobbles. This has happened with other tools, but thought I'd ask here in case you might know the reason. Maybe I'm missing something? Do I need a Last.fm pro account?

Maybe update plot to new library versions?

Describe the bug
The main program works great for my 44,000ish scrobbles. Unfortunately my libs are too new for plot.py to work. Still cool to be able to grep and find out basic info.

Desktop (please complete the following information):

  • OS: Xubuntu 20.04.4

Error on running it
Traceback (most recent call last): File "plot.py", line 53, in <module> plot = get_plot(arranged_dataframe) File "plot.py", line 39, in get_plot dataframe.plot(x="artist", y="scrobbles", kind="bar") File "/home/william/.local/lib/python3.8/site-packages/pandas/plotting/_core.py", line 794, in __call__ return plot_backend.plot(data, kind=kind, **kwargs) File "/home/william/.local/lib/python3.8/site-packages/pandas/plotting/_matplotlib/__init__.py", line 62, in plot plot_obj.generate() File "/home/william/.local/lib/python3.8/site-packages/pandas/plotting/_matplotlib/core.py", line 279, in generate self._compute_plot_data() File "/home/william/.local/lib/python3.8/site-packages/pandas/plotting/_matplotlib/core.py", line 403, in _compute_plot_data numeric_data = data.select_dtypes( File "/home/william/.local/lib/python3.8/site-packages/pandas/core/frame.py", line 3442, in select_dtypes include_these = Series(not bool(include), index=self.columns) File "/home/william/.local/lib/python3.8/site-packages/pandas/core/series.py", line 314, in __init__ data = sanitize_array(data, index, dtype, copy, raise_cast_failure=True) File "/home/william/.local/lib/python3.8/site-packages/pandas/core/internals/construction.py", line 712, in sanitize_array subarr = construct_1d_arraylike_from_scalar(value, len(index), dtype) File "/home/william/.local/lib/python3.8/site-packages/pandas/core/dtypes/cast.py", line 1233, in construct_1d_arraylike_from_scalar subarr = np.empty(length, dtype=dtype) TypeError: Cannot interpret '<attribute 'dtype' of 'numpy.generic' objects>' as a data type

Got

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.