greg icon indicating copy to clipboard operation
greg copied to clipboard

bs4.FeatureNotFound: Couldn't find a tree builder with the features you requested: lxml

Open reubano opened this issue 8 years ago • 2 comments

$ greg download 10-15
Traceback (most recent call last):
  File "/Users/reubano/Library/Python/3.6/bin/greg", line 11, in <module>
    sys.exit(main())
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/greg/parser.py", line 138, in main
    function(vars(args))
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/greg/commands.py", line 247, in download
    feed.download_entry(entry)
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/greg/classes.py", line 324, in download_entry
    sanitizedsummary)
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/greg/classes.py", line 362, in __init__
    feed.podcast.feed.subtitle)
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/greg/aux_functions.py", line 109, in html_to_text
    beautify = BeautifulSoup(data, "lxml")
  File "/Users/reubano/Library/Python/3.6/lib/python/site-packages/bs4/__init__.py", line 165, in __init__
    % ",".join(features))
bs4.FeatureNotFound: Couldn't find a tree builder with the features you requested: lxml. Do you need to install a parser library?

reubano avatar Jul 25 '17 05:07 reubano

solved with pip install --user lxml... but, that shouldn't be needed.

reubano avatar Jul 25 '17 05:07 reubano

By default, BS4 will use the HTML parser included in Python's standard library, but it also supports third-party Python parsers, such as lxml parser and html5lib parser. In order to use the third-party Python parsers, you need to install them, since they are not the built-in part of your installation. You can find more details on the bs4 document listed below. https://www.crummy.com/software/BeautifulSoup/bs4/doc/#installing-a-parser

Lucas-Wong-Eng avatar Aug 15 '19 11:08 Lucas-Wong-Eng