Skip to content

IMDB format change #10

@ellisdoro

Description

@ellisdoro

When I run, I get the following error:

docker run python-imdb
Traceback (most recent call last): File "//./main.py", line 46, in <module> main() File "//./main.py", line 33, in main idx = random.randrange(0, n_movies) File "/usr/local/lib/python3.9/random.py", line 316, in randrange raise ValueError("empty range for randrange() (%d, %d, %d)" % (istart, istop, width)) ValueError: empty range for randrange() (0, 0, 0)

I can resolve the error by changing the URL from https://www.imdb.com/chart/top/ to a version archived from the wayback machine from March 2022: https://web.archive.org/web/20220314214330/https://www.imdb.com/chart/top, so it seems as though the error is from a change in how imdb formats its movie lists.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions