You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/usr/lib/python2.7/pdb.py", line 1314, in main
pdb._runscript(mainpyfile)
File "/usr/lib/python2.7/pdb.py", line 1233, in _runscript
self.run(statement)
File "/usr/lib/python2.7/bdb.py", line 400, in run
exec cmd in globals, locals
File "<string>", line 1, in <module>
File "cli.py", line 3, in <module>
import sys, cmd, argparse, getpass
File "/usr/lib/python2.7/cmd.py", line 142, in cmdloop
stop = self.onecmd(line)
File "/usr/lib/python2.7/cmd.py", line 221, in onecmd
return func(arg)
File "cli.py", line 27, in method
return func(** { key: vars(args)[key] for key in vars(args) if key != 'action' })
File "cli.py", line 110, in folder_scan
FolderManager.scan(folder.id, s)
File "managers/folder.py", line 94, in scan
scanner.scan(folder)
File "scanner.py", line 28, in scan
self.__scan_file(os.path.join(root, f), folder)
File "scanner.py", line 77, in __scan_file
tr.album = self.__find_album(self.__try_read_tag(tag, 'artist'), self.__try_read_tag(tag, 'album'))
File "scanner.py", line 83, in __find_album
ar = self.__find_artist(artist)
File "scanner.py", line 94, in __find_artist
ar = filter(lambda a: a.name.lower() == artist.lower(), self.__artists)
File "scanner.py", line 94, in <lambda>
ar = filter(lambda a: a.name.lower() == artist.lower(), self.__artists)
AttributeError: 'NoneType' object has no attribute 'lower'
This happens because artist is None in this context, because back in __scan_file, self.__try_read_tag(tag, 'artist') returns None. (I guess I have a broken MP3 file without an artist tag...) Adding a default, i.e. changing to self.__try_read_tag(tag, 'artist', '') seems to help, but I don't know what the right solution is.
BTW: I'm really psyched to have found something I can run on my Sheevaplug that doesn't require something as heavy as Java!
The text was updated successfully, but these errors were encountered:
This happens because
artist
isNone
in this context, because back in__scan_file
,self.__try_read_tag(tag, 'artist')
returnsNone
. (I guess I have a broken MP3 file without an artist tag...) Adding a default, i.e. changing toself.__try_read_tag(tag, 'artist', '')
seems to help, but I don't know what the right solution is.BTW: I'm really psyched to have found something I can run on my Sheevaplug that doesn't require something as heavy as Java!
The text was updated successfully, but these errors were encountered: