Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SpotifyBackup
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Robert Goldmann
SpotifyBackup
Compare revisions
0b52658d137d514b43b5673de0a4337bec4dccb4 to 4105135032a91ed1002a27477934724d639d8a86
Compare revisions
Changes are shown as if the
source
revision was being merged into the
target
revision.
Learn more about comparing revisions.
Source
deadlocker8/SpotifyBackup
Select target project
No results found
4105135032a91ed1002a27477934724d639d8a86
Select Git revision
Loading items
Swap
Target
deadlocker8/SpotifyBackup
Select target project
deadlocker8/SpotifyBackup
1 result
0b52658d137d514b43b5673de0a4337bec4dccb4
Select Git revision
Loading items
Show changes
Only incoming changes from source
Include changes to target since source was created
Compare
Commits on Source (2)
SpotifyAutoPlaylistCreator: handle deletion of more than 100 songs
· 387a4e1c
Robert Goldmann
authored
10 months ago
387a4e1c
v1.12.2
· 41051350
Robert Goldmann
authored
10 months ago
41051350
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
SpotifyAutoPlaylistCreator.py
+3
-2
3 additions, 2 deletions
SpotifyAutoPlaylistCreator.py
pyproject.toml
+1
-1
1 addition, 1 deletion
pyproject.toml
version.json
+2
-2
2 additions, 2 deletions
version.json
with
6 additions
and
5 deletions
SpotifyAutoPlaylistCreator.py
View file @
41051350
...
...
@@ -91,7 +91,7 @@ class SpotifyAutoPlaylistCreator:
LOGGER
.
info
(
f
'
>>> Adding tracks to destination playlist
"
{
destinationPlaylist
[
"
name
"
]
}
"
...
'
)
randomTrackUris
=
self
.
__extract_track_uris
(
randomTracks
)
for
batch
in
self
.
__chunk_list
(
randomTrackUris
,
10
0
):
for
batch
in
self
.
__chunk_list
(
randomTrackUris
,
5
0
):
self
.
_spotify
.
playlist_add_items
(
self
.
_destinationPlaylistInfo
[
'
id
'
],
batch
)
@staticmethod
...
...
@@ -122,7 +122,8 @@ class SpotifyAutoPlaylistCreator:
f
'
playlist
"
{
destinationPlaylist
[
"
name
"
]
}
"
...
'
)
existingTracksUris
=
self
.
__extract_track_uris
(
existingTracks
)
if
existingTracksUris
:
self
.
_spotify
.
playlist_remove_all_occurrences_of_items
(
self
.
_destinationPlaylistInfo
[
'
id
'
],
existingTracksUris
)
for
batch
in
self
.
__chunk_list
(
existingTracksUris
,
100
):
self
.
_spotify
.
playlist_remove_all_occurrences_of_items
(
self
.
_destinationPlaylistInfo
[
'
id
'
],
batch
)
def
__get_playlist
(
self
,
username
:
str
,
playlistID
:
str
)
->
Dict
:
LOGGER
.
info
(
f
'
>>> Fetching playlist with ID:
{
playlistID
}
by
{
username
}
...
'
)
...
...
This diff is collapsed.
Click to expand it.
pyproject.toml
View file @
41051350
[tool.poetry]
name
=
"SpotifyBackup"
version
=
"1.12.
1
"
version
=
"1.12.
2
"
description
=
"Simple script for backing up public playlists from Spotify."
authors
=
[
"deadlocker8"
]
...
...
This diff is collapsed.
Click to expand it.
version.json
View file @
41051350
{
"version"
:
{
"name"
:
"v1.12.
1
"
,
"code"
:
1
6
,
"name"
:
"v1.12.
2
"
,
"code"
:
1
7
,
"date"
:
"30.08.24"
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.