Skip to main content

A playlist generator for creating local playlists using Spotify curated playlists

Project description

Spotipylist

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

Currently under active development.

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
  • rapidfuzz 1.7.1

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.

This is one reason for using the rapidfuzz library over fuzzywuzzy as fuzzywuzzy is licensed under GPL-2.0, which would require Spotipylist to adopt GPL-2.0 as well.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spotipylist-0.1.3.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

spotipylist-0.1.3-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file spotipylist-0.1.3.tar.gz.

File metadata

  • Download URL: spotipylist-0.1.3.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.4

File hashes

Hashes for spotipylist-0.1.3.tar.gz
Algorithm Hash digest
SHA256 4532497689c75e5b260a809950202dc5fae515594e1e55f592282297b56412c7
MD5 19ee23907a31bd5b13398518eccdd0cc
BLAKE2b-256 1d082c9ace3cd9bf3363eb976cec6dafe6e5d3eae5bf389dc309c20850b6d9e1

See more details on using hashes here.

Provenance

File details

Details for the file spotipylist-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: spotipylist-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.4

File hashes

Hashes for spotipylist-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 981f98cee576c05269704611d1624a2a38f595262cf2942c0f11d3f5e5238820
MD5 a60a5f080188cc871cfcda0b8c808ada
BLAKE2b-256 b5a5f7a440e33dcef0203bcb58eb61dd94ad877d7d4539302d85f9bcbc38219a

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page