Flexget / Flexget

The official FlexGet repository
http://www.flexget.com
MIT License
1.74k stars 473 forks source link

Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower' #2180

Closed sjau closed 6 years ago

sjau commented 6 years ago

Expected behaviour:

Flexget crashes with following error:

2018-07-27 06:16 CRITICAL manager       premiers        An unexpected crash has occurred. Writing crash report to /home/hyper/.flexget/crash_report.2018.07.27.061626117173.log. Please verify you are runni
ng the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at http://flexget.com/wiki/Plugins/version_checker. You are currently using version 2.14.5               
2018-07-27 06:36 ERROR    lazy_lookup   premiers        Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower'                                                                   
2018-07-27 06:36 CRITICAL manager       premiers        An unexpected crash has occurred. Writing crash report to /home/hyper/.flexget/crash_report.2018.07.27.063628242775.log. Please verify you are runni
ng the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at http://flexget.com/wiki/Plugins/version_checker. You are currently using version 2.14.5               
2018-07-27 06:56 ERROR    lazy_lookup   premiers        Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower'                                                                   
2018-07-27 06:56 CRITICAL manager       premiers        An unexpected crash has occurred. Writing crash report to /home/hyper/.flexget/crash_report.2018.07.27.065627837081.log. Please verify you are runni
ng the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at http://flexget.com/wiki/Plugins/version_checker. You are currently using version 2.14.5               
2018-07-27 07:16 ERROR    lazy_lookup   premiers        Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower'                                                                   
2018-07-27 07:16 CRITICAL manager       premiers        An unexpected crash has occurred. Writing crash report to /home/hyper/.flexget/crash_report.2018.07.27.071628359681.log. Please verify you are runni
ng the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at http://flexget.com/wiki/Plugins/version_checker. You are currently using version 2.14.5               
2018-07-27 07:36 ERROR    lazy_lookup   premiers        Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower'                                                                   
2018-07-27 07:36 CRITICAL manager       premiers        An unexpected crash has occurred. Writing crash report to /home/hyper/.flexget/crash_report.2018.07.27.073631604577.log. Please verify you are runni
ng the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at http://flexget.com/wiki/Plugins/version_checker. You are currently using version 2.14.5               
2018-07-27 07:56 ERROR    lazy_lookup   premiers        Unhandled error in lazy lookup plugin: 'NoneType' object has no attribute 'lower'                                                                   
Traceback (most recent call last):                                                                                                                                                                          
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/utils/lazy_dict.py", line 37, in __getitem__                                                         
    func(self.store)                                                                                                                                                                                        
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/plugins/metainfo/thetvdb_lookup.py", line 125, in lazy_series_lookup                                 
    return self.series_lookup(entry, language, self.series_map)                                                                                                                                             
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/utils/database.py", line 34, in wrapper                                                              
    return func(*args, **kwargs)                                                                                                                                                                            
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/plugins/metainfo/thetvdb_lookup.py", line 117, in series_lookup                                      
    session=session                                                                                                                                                                                         
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/utils/database.py", line 31, in wrapper                                                              
    return func(*args, **kwargs)                                                                                                                                                                            
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/plugins/internal/api_tvdb.py", line 533, in lookup_series                                            
    _update_search_strings(series, session, search=name)                                                                                                                                                    
  File "/nix/store/q8jw12gsj2r1pjrly266yg07drbvj3v9-FlexGet-2.14.5/lib/python2.7/site-packages/flexget/plugins/internal/api_tvdb.py", line 480, in _update_search_strings                                   
    add = [series.name.lower()] + aliases + searches                                                                                                                                                        
AttributeError: 'NoneType' object has no attribute 'lower' 

This seems to be a recurring issue:

https://github.com/Flexget/Flexget/issues/1971

Config:

templates:
  global:
    cookies: ~/.flexget/cookies.sqlite
    regexp:
      reject:
        - french
        - german
        - dutch
        - ipod
        - workprint
        - WORKPRINT
        - "comic.con"

  tv_common:
    inputs:
      - rss: xxx
      - rss: yyy
      - rss: zzz
    verify_ssl_certificates: no
    download: ~/rtorrent/Watch/
    exists_series:
      - ~/rtorrent/Completed/
      - ~/rtorrent/Downloads/
      - ~/rtorrent/Watch/

  movies:
    inputs:
      - rss: xxx
      - rss: yyy
      - rss: zzz
    verify_ssl_certificates: no
    content_size:
      max: 2400
    download: ~/rtorrent/Movies_Watch/
    exists_movie:
      - ~/rtorrent/Movies
      - ~/rtorrent/Downloads
      - ~/rtorrent/Movies_Watch
    quality: 
      - <=1080p hdrip+
    proper_movies: no
    list_match:
      from:
        - movie_list: movies

tasks:
  tv_feeds_lq:
    template: tv_common
    series:
      settings:
        group 1:
          propers: no
    content_size:
      max: 800
      strict: no
    include: series.yml

  tv_feeds_hq:
    template: tv_common
    series:
      settings:
        group 1:
          propers: no
    content_size:
      max: 1500
      strict: no
    delay: 2 hours
    include: series.yml

  premiers:
    template: tv_common
    series_premiere:
      propers: no
      allow_seasonless: yes
    content_size:
      max: 1500  
      strict: no
    thetvdb_lookup: yes
    require_field:
      - tvdb_genres
      - tvdb_network
    regexp:
      reject:
        - documentary: {from: tvdb_genres}
        - talk show: {from: tvdb_genres}
        - game show: {from: tvdb_genres}
        - reality: {from: tvdb_genres}
        - news: {from: tvdb_genres}
        - food: {from: tvdb_genres}
        - travel: {from: tvdb_genres}
        - reality: {from: tvdb_genres}
        - "home and garden": {from: tvdb_genres}
        - science channel: {from: tvdb_network}

  movie_feeds:
    template: movies

schedules:
  - tasks: [tv_feeds_lq, tv_feeds_hq, premiers]
    interval:
      minutes: 20
  - tasks: movie_feeds
    interval:
      minutes: 60

Additional information:

2.15.4

2.7

Nix expression

yes

NixOS Unstalbe Small

liiight commented 6 years ago

Can you run with --debug please?

sjau commented 6 years ago

Updated to 2.14.9 - errors are gone.