Comment

Comment by jll29

  % python main.py https://www.paulgraham.com/avg.html
  Traceback (most recent call last):
  File "/Users/bill/web2pdf/main.py", line 7, in <module>
    from readability import Document
  ImportError: cannot import name 'Document' from 'readability' 
  (/Users/bill/.local/share/virtualenvs/web2pdf- 
 gXeVRXKg/lib/python3.9/site-packages/readability/__init__.py)
But according to your Pipfile.lock, the readability module needed is 0.3.1:

  "readability": {
            "hashes": [
              "sha256:f9030df8bc31aad45baffa9a2d9ce1fdd8051833e5b5bda3027df32fdec00fad"
            ],
            "index": "pypi",
            "version": "==0.3.1"
        },
Version 0.3.1 of the module "readability" exists, but does not appear to have a class "Document".
parent jll29 2 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton