Repository navigation
docs: add a playlist-to-CSV recipe - #163
Open
musabustun wants to merge 1 commit into
Open
musabustun wants to merge 1 commit into
musabustun wants to merge 1 commit into
Conversation
Dumping a playlist to a spreadsheet is a common ask with no existing recipe in the docs. Adds a ~15-line snippet using only the public API and the stdlib csv module, following the same SpotifyClient pattern as the other guides. Verified: the exact snippet in the doc runs against a real playlist (Spotify's own "Today's Top Hits", already used as the example ID elsewhere in these docs) and produces correct rows, including the tier-1-only album field falling back to "" instead of raising when absent. `mkdocs build --strict` passes with the new page in the nav. Closes AliAkhtari78#144 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Closes #144. Adds a short recipe (
docs/guides/playlist-to-csv.md) showing how to dump a playlist's tracks to a CSV file — a common ask with no existing doc coverage.SpotifyClientAPI and the stdlibcsvmodule.37i9dQZF1DXcBWIGoYBM5M, Spotify's own "Today's Top Hits") already used elsewhere in these docs, for consistency.track.albumbeingNone(a tier-1-only field perentities.md) by falling back to""instead of raising, and links to the existing docs explaining whyplaylist.tracksholdsPlaylistTrackwrappers rather than bareTracks.mkdocs.yml(right after "Entities", since it directly extends the playlists section there).Testing
Nonealbum field).uv run mkdocs build --strict— passes with the new page included, no broken links or warnings from it.pre-commit run --files docs/guides/playlist-to-csv.md mkdocs.yml— codespell, trailing-whitespace, end-of-file-fixer all pass. (check-yamlfails onmkdocs.yml, but that's pre-existing — it fails identically onmasterbefore this change, due to a custom Python-object YAML tag mkdocs-material's emoji extension uses that the generic pre-commit YAML parser doesn't understand.)No library code changed.
🤖 Generated with Claude Code