Open jmsierra opened 2 years ago
Files identified in the description:
If these files are incorrect, please update the component name
section of the description or use the !component
bot command.
cc @oboukili click here for bot help
BeautifulSoup4 is a different library from BeautifulSoup. The module requires the latter, you seem to have installed the former.
It definitely does make sense to support both BS3 and BS4 though :)
Yes, I think BS4 is a new and disruptive version of BeautifulSoup. BS3 is no longer available in Ubuntu20 at least under python 3.8 and it asks you to install BS4 instead:
# pip3 install beautifulsoup
Collecting beautifulsoup
Using cached BeautifulSoup-3.2.2.tar.gz (32 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [7 lines of output]
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/tmp/pip-install-w9axyja9/beautifulsoup_88953322c3844e60bb79f27ef1c1efaa/setup.py", line 3
"You're trying to run a very old release of Beautiful Soup under Python 3. This will not work."<>"Please use Beautiful Soup 4, available through the pip package 'beautifulsoup4'."
^
SyntaxError: invalid syntax
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Thank you so much for your support!
Files identified in the description:
If these files are incorrect, please update the component name
section of the description or use the !component
bot command.
Please update the apache2_mod_proxy to import BeautifulSoup from bs4
Version 3 is deprecated. See: https://www.crummy.com/software/BeautifulSoup/bs4/doc/#porting-code-to-bs4
Summary
It seems that new beautifulsoup library version 4 changes the way the library is imported:
causing errors even if pip3 library beautifulsoup4 is installed when calling module community.general.apache2_mod_proxy, which tries to import it as:
Many thanks!
Issue Type
Bug Report
Component Name
community.general.apache2_mod_proxy
Ansible Version
Community.general Version
Configuration
OS / Environment
Ansible machine: Ubuntu 20 WSL Target machine: Ubuntu 20.04 Minimal
Steps to Reproduce
Installed beautiful soup 4 manually on dc1-frontend machine:
Launch ansible module:
Expected Results
Expected for the target machine (ansible_host) to be drained from apache2 load balancer.
Actual Results
Code of Conduct