Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError during remove-library #6

Closed
apastel opened this issue Nov 4, 2020 · 0 comments
Closed

TypeError during remove-library #6

apastel opened this issue Nov 4, 2020 · 0 comments

Comments

@apastel
Copy link
Owner

apastel commented Nov 4, 2020

A user who is not me reported the following error on Reddit when using remove-library:

[2020-11-02 00:23:35] Retrieving all library albums...
[2020-11-02 00:23:35] Retrieved 0 albums from your library.
[2020-11-02 00:23:35] Retrieving all singles...
[2020-11-02 00:25:21] Retrieved 7037 singles from your library.
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.9/bin/ytmusic-deleter", line 8, in <module>
sys.exit(cli())
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/click/core.py", line 829, in __call__
return self.main(*args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/click/core.py", line 782, in main
rv = self.invoke(ctx)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/click/core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/click/core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/ytmusic_deleter/cli.py", line 182, in remove_library
filtered_songs = list({v["album"]["id"]: v for v in library_songs}.values())
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/ytmusic_deleter/cli.py", line 182, in <dictcomp>
filtered_songs = list({v["album"]["id"]: v for v in library_songs}.values())
TypeError: 'NoneType' object is not subscriptable

So far I'm unable to replicate the issue whether my library has songs/singles in it or not.

@apastel apastel closed this as completed Jan 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant