The problem probably happened during installation. Beautiful Soup is
distributed as Python 2 code, and a Python 3 system is responsible for
converting it to Python 3 code upon installation.
In this case, the original line was:
from .import _htmlparser
And the second period was probably erroneously added during Python 3
conversion. It's possible that some versions of the conversion script
will make this mistake and some will not.
There should be a space between "." and "import", which I've added.
Try this line and see if it works for you:
from . import _htmlparser
Leonard