tvnamer
tvnamer copied to clipboard
KeyError: u'seasonnumber'
Existing filename is correct: [Taka] Naruto Shippuuden - 262 - War Begins [4B93BD6A].mp4
####################
Traceback (most recent call last):
File "/usr/bin/tvnamer-2.7", line 9, in <module>
load_entry_point('tvnamer==2.2.1', 'console_scripts', 'tvnamer')()
File "/usr/lib64/python2.7/site-packages/tvnamer/main.py", line 416, in main
tvnamer(paths = sorted(args))
File "/usr/lib64/python2.7/site-packages/tvnamer/main.py", line 323, in tvnamer
processFile(tvdb_instance, episode)
File "/usr/lib64/python2.7/site-packages/tvnamer/main.py", line 243, in processFile
newPath = getMoveDestination(episode)
File "/usr/lib64/python2.7/site-packages/tvnamer/main.py", line 75, in getMoveDestination
'originalfilename': episode.originalfilename,
KeyError: u'seasonnumber'
I think this is caused by this bug - certain episode types don't get all episode data - the Anime-episode-info class doesn't currently get season number
I'll try and fix this soon..
dot dot dot
temporary (ugly) fix: https://github.com/averissimo/tvnamer/commit/6581d66cb0c3876aec8c0c768f0b2794b4569b21
basically it defaults the season number to 0 for these cases