Skip to main content

Spotipylist

A playlist generator for creating local playlists using Spotify's curated playlists

Table of Contents

General Info

This project is my final project for CS50x (Harvard University's Intro to Computer Science hosted on edX.org)

The main purpose is to make creating playlists from my personal music library faster, easier, and better by using the track lists of many of the fantastic playlists that are already hosted on Spotify.

Video Demo: https://youtu.be/hiCw-1UxLPs

Dependencies

Spotipylist uses the following:

  • Python 3.6 or later
  • spotipy 2.19.0 or later
  • rapidfuzz 1.7.1 or later

Setup

Spotipylist is installable using pip:

pip install spotipylist

OR

python3 -m pip install spotipylist

Currently, your music library must be arranged the in the following format:

  • Folder structure:

    <music_library>/<artist>/[<album>/]
    
  • Filenames

    <track_number> - <track_name>.mp3
    

    where track_number is 2 digits (e.g. 01 for track number 1)

This is mostly a personal choice as that's how my music library is structured. I have considered other options, such as adding support for ID3 tags, and probably will add one or more in future releases.

Usage

  1. Set the following environment variables:

    • SPOTIPY_CLIENT_ID
    • SPOTIPY_CLIENT_SECRET
    • SPOTIPYLIST_MUSIC_LIBRARY

    To set SPOTIPY_CLIENT_ID and SPOTIPY_CLIENT_SECRET, first create a new app on https://developers.spotify.com, then use the client_id and client_secret given there.

    Set SPOTIPYLIST_MUSIC_LIBRARY with the absolute path to your local music library.

  2. Because you installed from PyPi, you can run spotipylist in your terminal with

    spotipylist
    
  3. You will be prompted for the Spotify playlist ID you want to copy.

  4. When prompted, input the name you would like to give to your new playlist.

    • New playlist will be saved in your music library as <playlist_name>.m3u, overwriting any playlist of the same name.
  5. Finally, if your music library does not contain some of the songs in the Spotify playlist, the name and artist of each of those tracks will be saved to missing_tracks.txt in your music library. You'll be prompted with the following message:

    • Some songs from this playlist were not found in your library. See missing_tracks.txt for details.

License

Spotipylist is licensed under the MIT license.

Release files for spotipylist 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spotipylist 0.2.1
File Size Uploaded
spotipylist-0.2.1.tar.gz 6.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for spotipylist 0.2.1
File Interpreter ABI Platform
spotipylist-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 13.7 kB

Release files / spotipylist-0.2.1.tar.gz

Download URL spotipylist-0.2.1.tar.gz
Size 6.2 kB
Tags Source
SHA-256 checksum
How to use checksums
8bd36146443a377ebf1c318771bcf6ea9b1256528995bed84aa2a20113fea00e
BLAKE2b-256 checksum
How to use checksums
7d6a49f4a3fe928d7262a81510ff36d3fa904e336693f44c4303c45e1ed6fbff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.7

Release files / spotipylist-0.2.1-py3-none-any.whl

Download URL spotipylist-0.2.1-py3-none-any.whl
Size 7.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5cb10f45e14cc47a34c079454c094eba2c4061801bf6669996826b598aaec5c9
BLAKE2b-256 checksum
How to use checksums
065c95283d43505a578ac5bccb5dd92dc5ce0f05d997dc21653b929d90bf76c5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.7

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

0.2.0

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page