Skip to content

feat: Add Smart Playlist Sync to download only new/updated tracks #2521

@khushipy

Description

@khushipy

Requested Feature

Feature Request: Smart Playlist Sync

Description

Add functionality to download only new or modified tracks from a playlist since the last download, rather than re-downloading the entire playlist.

Problem

Currently, when updating a local copy of a playlist, users must either:

  1. Re-download the entire playlist (wasting time and bandwidth)
  2. Manually track which tracks are new (time-consuming and error-prone)

Possible implementation

Proposed Solution

  1. Track Playlist State:

    • Store a checksum or timestamp of the playlist's current state
    • Save this information in a local database or metadata file
  2. Incremental Downloads:

    • When downloading a playlist, first check its current state against the stored state
    • Only download tracks that are new or have been modified since the last download
  3. CLI Options:

    # Basic usage (automatically detects changes)
    spotdl sync [https://open.spotify.com/playlist/](https://open.spotify.com/playlist/)...
    
    # Force full re-download
    spotdl sync --force [https://open.spotify.com/playlist/](https://open.spotify.com/playlist/)...
    

The Smart Playlist Sync feature tracks changes in Spotify playlists by maintaining a local state file with playlist hashes. When syncing, it compares the current playlist state with the stored hash, downloading only new or modified tracks to save bandwidth and time. The implementation includes a new 'spotdl sync' command with options for custom output formats and force updates, while ensuring efficient state management and error handling. This feature is particularly useful for frequently updated or collaborative playlists, especially for users with limited bandwidth.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions