question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

AttributeError: 'list' object has no attribute 'lower'

See original GitHub issue

I seem to consistently get the following error, when running Subliminal against my movies or series, using pretty much just a standard run (subliminal download -l en -l da /path/to).

Here is the output:

Downloading subtitles  [#####################---------------]   59%  0d 02:48:08  Two and a Half Men - S04E02 - Who's Vod Kanockers - 720p WEB-DL.mkv
Traceback (most recent call last):
  File "/volume1/@appstore/py3k/usr/local/bin/subliminal", line 11, in <module>
    sys.exit(subliminal())
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/core.py", line 722, in __call__
    return self.main(*args, **kwargs)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/core.py", line 697, in main
    rv = self.invoke(ctx)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/core.py", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/core.py", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/core.py", line 535, in invoke
    return callback(*args, **kwargs)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/click/decorators.py", line 27, in new_func
    return f(get_current_context().obj, *args, **kwargs)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/cli.py", line 403, in download
    hearing_impaired=hearing_impaired, only_one=single)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/core.py", line 211, in download_best_subtitles
    for s in subtitles], key=operator.itemgetter(1), reverse=True)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/core.py", line 211, in <listcomp>
    for s in subtitles], key=operator.itemgetter(1), reverse=True)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/score.py", line 106, in compute_score
    matches = subtitle.get_matches(video)
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/providers/opensubtitles.py", line 78, in get_matches
    matches |= guess_matches(video, guessit(self.movie_release_name, {'type': 'episode'}))
  File "/volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages/subliminal/subtitle.py", line 235, in guess_matches
    if video.format and 'format' in guess and not isinstance(guess['format'], list) and guess['format'].lower() == video.format.lower():
AttributeError: 'list' object has no attribute 'lower'

Seems to be related to having two formats attached to it. The best I have been able to google myself to is: https://github.com/pymedusa/Medusa/issues/1033, which fixed the issue by changing code in their software and not in subliminal itself.

I have attached a debug with one of the files that I can reproduce it with without fail.

debug.txt

Very surprised no one else have run into this issue.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:9
  • Comments:10 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
CWempecommented, Jul 24, 2018

Thanks.

I build my own docker image based on the feature/video_format branch.
https://github.com/Diaoul/subliminal/tree/feature/video_format

Seems to work. 😄

If anybody is interessted: https://hub.docker.com/r/cwempe/subliminal/

Read more comments on GitHub >

github_iconTop Results From Across the Web

AttributeError: 'list' object has no attribute 'lower' gensim
you were trying to apply .lower() to data, which is a list. .lower() can only be applied to strings.
Read more >
AttributeError: 'list' object has no attribute 'lower' | bobbyhadz
The Python "AttributeError: 'list' object has no attribute 'lower'" occurs when we call the lower() method on a list instead of a string....
Read more >
AttributeError: 'list' object has no attribute 'lower' - Kaggle
Hi, I've been working on NLP but I keep receiving: AttributeError: 'list' object has no attribute 'lower' Does anyone know why? here's my...
Read more >
AttributeError: 'list' object has no attribute 'lower' - Python Help
Hi everyone, When I try to buy a con on binance with my bot it sometimes gives me this error; AttributeError: 'list' object...
Read more >
'list' object has no attribute 'lower' TfidfVectorizer
If the 'text' is in a list format, the lower function does not work for a list. It works for a string as...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found