mirror of
https://github.com/Googolplexed0/zotify.git
synced 2026-04-25 06:15:55 +03:00
[GH-ISSUE #141] [Bug Report] Slow Bulk Track/Disc Total Fetching #126
Labels
No labels
bug
considering
discussion
documentation
enhancement
enhancement
good first issue
help wanted
pull-request
question
stale
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/zotify#126
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @RGPZ on GitHub (Jan 6, 2026).
Original GitHub issue: https://github.com/Googolplexed0/zotify/issues/141
Originally assigned to: @Googolplexed0 on GitHub.
Zotify Version
v0.11.15
Bug Description
When trying to run zotify after performing the latest update, scrapping my old credentials save, updating my app redirect URL to allow me to sign into Zotify and get new credentials which I now have, Zotify hangs at "[●∙∙] Fetching bulk track/disc total information..." everytime and doesn't properly progress after that.
Error Traceback / Logs
`DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=accesspoint HTTP/1.1" 200 None
INFO:Librespot:Session:Created new session! device_id: 8159402511c0707c95da3b358ad64da3bbb7b172, ap: ap-gew4.spotify.com:80
INFO:Librespot:Session:Connection successfully!
INFO:Librespot:Session:Session.Receiver started
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=spclient HTTP/1.1" 200 None
INFO:Librespot:Session:Skipping 02
INFO:Librespot:Session:Received license_version: 0
INFO:Librespot:Session:Received country_code: NZ
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
DEBUG:Librespot:Session:Parsed product info: {'type': 'premium', 'ab-ad-player-targeting': '1', 'ab-watch-now': '0', 'ab_recently_played_feature_time_filter_threshold': 'com.spotify.gaia=30,driving-mode=120,spotify%3Ainternal%3Astartpage=30', 'ad-formats-preroll-video': '0', 'ad-session-persistence': '1', 'ads': '0', 'app-developer': '0', 'arsenal_country': '1', 'audio-preview-url-template': 'https://p.scdn.co/mp3-preview/{id}', 'audiobook-onboarding-completed': '0', 'capping-bar-threshold': '3601', 'catalogue': 'premium', 'client-deprecated': '1', 'collection': '1', 'created_by_partner': None, 'employee-free-opt-in': '0', 'enable-annotations': '2', 'enable-annotations-read': '0', 'enable-crossfade': '1', 'explicit-content': '1', 'financial-product': 'pr:premium,tc:0,rt:v2_NZ_default_prepaid-premium-6-month-6m_77.94_NZD_default', 'head-file-caching': '1', 'head-files': '1', 'head-files-url': 'https://heads-fa-tls13.spotifycdn.com/head/{file_id}', 'high-bitrate': '1', 'image-url': 'https://i.scdn.co/image/{file_id}', 'incognito_mode_timeout': '21600', 'is_email_verified': '1', 'key-caching-max-count': '10000', 'key-caching-max-offline-seconds': '1800', 'key-memory-cache-mode': '1:15,300', 'libspotify': '1', 'license-agreements': None, 'loudness-levels': '1:-5.0,0.0,3.0:-2.0', 'metadata-link-lookup-modes': '0', 'mobile': '1', 'name': 'Spotify Premium', 'nft-disabled': '1', 'offline': '1', 'on-demand': '1', 'on-demand-trial-in-progress': '0', 'payment-state': None, 'payments-initial-campaign': 'prepaid', 'payments-locked-state': '0', 'player-license': 'premium', 'player-license-v2': 'premium', 'playlist-annotations-markup': '0', 'preferred-locale': 'en', 'prefetch-keys': '1', 'prefetch-strategy': '2', 'prefetch-window-max': '2', 'product-expiry': '2026-06-16T23:54:11Z', 'publish-activity': '0', 'publish-playlist': '1', 'radio': '1', 'remote-control': '6', 'restrict-playlist-collaboration': '0', 'send-email': '0', 'shows-collection': '1', 'shows-collection-jam': '0', 'shuffle': '0', 'sidebar-navigation-enabled': '0', 'storage-size-config': '10240,90,500,3', 'streaming': '1', 'streaming-rules': None, 'subscription-enddate': '2026-06-16T23:54:11Z', 'ugc-abuse-report': '1', 'ugc-abuse-report-url': 'https://support.spotify.com/abuse/?uri={uri}', 'unrestricted': '1', 'video-cdn-sampling': '100', 'video-device-blacklisted': '0', 'video-manifest-url': 'https://spclient.wg.spotify.com/manifests/v6/{type}/sources/{source_id}/options/supports_drm', 'widevine-license-url': 'https://spclient.wg.spotify.com/widevine-license/v1/video/license'}
INFO:Librespot:Session:Skipping 1f
INFO:Librespot:Session:Skipping 69
DEBUG:Librespot:MercuryClient:Handling packet, cmd: 0xb5, seq: 3454315894069526528, flags: b'\x01', parts: 1
DEBUG:Librespot:MercuryClient:Couldn't dispatch Mercury event seq: 3454315894069526528, uri: hm://pusher/v1/connections/ODE1OTQwMjUxMWMwNzA3Yzk1ZGEzYjM1OGFkNjRkYTNiYmI3YjE3MitBUCt0Y3A6Ly8wYWIxNTAxNC5pcC5nZXc0LnNwb3RpZnkubmV0OjUwMTQrN0EzMEEzNzI3MDc1OTA4RDRBQkQwNjYxOTIwQjg4RDAwNjlDNTkzNDU1M0Q3QkE3QTlCNDM0QkVFRUExRjc4Qg%3D%3D, code: 200, payload: b''
DEBUG:Librespot:Session:Received 0x10: 39392527d9aa476435c2e342ae8bdbd57871abbb
INFO:Librespot:Session:Skipping unknown command cmd: 0x75, payload: b'\x00\x00\x01'
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=dealer HTTP/1.1" 200 None
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): login5.spotify.com:443
DEBUG:urllib3.connectionpool:https://login5.spotify.com:443 "POST /v3/login HTTP/1.1" 200 None
INFO:Librespot:TokenProvider:Login5 authentication successful, got access token
DEBUG:Librespot:TokenProvider:Using Login5 access token for scopes: ['playlist-read']
INFO:Librespot:Session:Authenticated as 31t4x5nmd4gkcbkeqalqiehxupcy!
DEBUG:zotify.debug:
Session Initialized Successfully
DEBUG:zotify.debug:
User Subscription Type: PREMIUM
DEBUG:zotify.debug:
Request Parsed as 1 URL
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): api.spotify.com:443
DEBUG:urllib3.connectionpool:https://api.spotify.com:443 "GET /v1/tracks/2nuDirYeA0wsYcFMgC7L8E?market=from_token HTTP/1.1" 200 None
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): api.spotify.com:443
DEBUG:urllib3.connectionpool:https://api.spotify.com:443 "GET /v1/albums?market=from_token&ids=457jZPSKtrWepu8RKsHG1a HTTP/1.1" 200 None`
Config File
{ "DEBUG": "True", "ROOT_PATH": "", "SAVE_CREDENTIALS": "True", "CREDENTIALS_LOCATION": "", "OUTPUT": "", "OUTPUT_SINGLE": "{artist}/{album}/{artist}_{song_name}", "OUTPUT_ALBUM": "{artist}/{album}/{album_num}_{artist}_{song_name}", "OUTPUT_PLAYLIST_EXT": "{playlist}/{playlist_num}_{artist}_{song_name}", "OUTPUT_LIKED_SONGS": "Liked Songs/{artist}_{song_name}", "ROOT_PODCAST_PATH": "", "SPLIT_ALBUM_DISCS": "False", "MAX_FILENAME_LENGTH": "0", "OPTIMIZED_DOWNLOADING": "True", "BULK_WAIT_TIME": "30", "DOWNLOAD_REAL_TIME": "True", "TEMP_DOWNLOAD_DIR": "", "DOWNLOAD_PARENT_ALBUM": "False", "NO_COMPILATION_ALBUMS": "False", "NO_VARIOUS_ARTISTS": "False", "NO_ARTIST_APPEARS_ON": "False", "DISCOG_BY_ALBUM_ARTIST": "False", "REGEX_ENABLED": "False", "REGEX_TRACK_SKIP": "", "REGEX_EPISODE_SKIP": "", "REGEX_ALBUM_SKIP": "", "DOWNLOAD_FORMAT": "mp3", "DOWNLOAD_QUALITY": "auto", "TRANSCODE_BITRATE": "auto", "CUSTOM_FFMEPG_ARGS": "", "SONG_ARCHIVE_LOCATION": "", "DISABLE_SONG_ARCHIVE": "False", "DISABLE_DIRECTORY_ARCHIVES": "False", "SKIP_EXISTING": "True", "SKIP_PREVIOUSLY_DOWNLOADED": "True", "EXPORT_M3U8": "False", "M3U8_LOCATION": "", "M3U8_REL_PATHS": "True", "LIKED_SONGS_ARCHIVE_M3U8": "True", "LYRICS_TO_METADATA": "True", "LYRICS_TO_FILE": "True", "LYRICS_LOCATION": "", "OUTPUT_LYRICS": "{artist}_{song_name}", "ALWAYS_CHECK_LYRICS": "False", "LYRICS_MD_HEADER": "False", "BYPASS_MD_API": "False", "LANGUAGE": "en", "MD_DISC_TRACK_TOTALS": "True", "MD_SAVE_GENRES": "False", "MD_ALLGENRES": "False", "MD_GENREDELIMITER": ",", "MD_ARTISTDELIMITER": ", ", "SEARCH_QUERY_SIZE": "10", "STRICT_LIBRARY_VERIFY": "True", "ALBUM_ART_JPG_FILE": "False", "RETRY_ATTEMPTS": "1", "CHUNK_SIZE": "20000", "REDIRECT_ADDRESS": "127.0.0.1", "PRINT_SPLASH": "False", "PRINT_PROGRESS_INFO": "True", "PRINT_SKIPS": "True", "PRINT_DOWNLOADS": "False", "PRINT_DOWNLOAD_PROGRESS": "True", "PRINT_URL_PROGRESS": "True", "PRINT_ALBUM_PROGRESS": "True", "PRINT_ARTIST_PROGRESS": "True", "PRINT_PLAYLIST_PROGRESS": "True", "PRINT_WARNINGS": "True", "PRINT_ERRORS": "True", "PRINT_API_ERRORS": "True", "STANDARD_INTERFACE": "False", "FFMPEG_LOG_LEVEL": "error" }I didn't want to open the 429 error since this shouldn't have any connection with it since my app was active before this situation and Zotify was working perfectly fine until I got the 429 error today which I fixed through the thread, or at least I thought I had anyway, the DEBUG file doesn't seem to write anything more than what it's written out currently.
@RGPZ commented on GitHub (Jan 6, 2026):
Update it does download media, but it takes ages to do so. I'm wonder if anyone else is experiencing this throughout their update or if I'm just singled out in this?
@Googolplexed0 commented on GitHub (Jan 13, 2026):
No, it's not just you, unfortunately this feature has always been extremely slow and memory heavy (even on the efficient-api branch). Every single API request creates many new Content objects, and since the bulk disk/track has to request tons of metadata, it gets exponentially slower as it goes.
I've been working on a total rewrite for a few weeks to try and improve this and many other fundamental design flaws. I think you (all) will be impressed. Should be public soon.
@Googolplexed0 commented on GitHub (Jan 20, 2026):
@RGPZ see if the new-hierarchy branch noticeably increases the speed of large Queries (after all the bugs are fixed).