I'm new to programming.
There may be deficiencies or deficiencies in the question. In that case, please forgive me as it will be added as appropriate.
I installed the library in the anaconda environment, but I can't import it.
The device used is MacBookPro 13inch, Mid 2012, and the version is catalina 10.15.1.
The installed library is "beautifulsoup4". The version is 4.8.1.
The terminal login shell is zsh.
The following is an error message that occurred when executed with python in an anaconda environment.
Traceback (most recent call last): File "/Users/******/Desktop/******/******/******.py", line 10, in<module> import beautifulsoup4 ModuleNotFoundError: No module named 'beautifulsoup4'
Under the terminal, the installation is completed as follows,
It seemed that it was installed properly in the "conda list" (the installation was confirmed in the environment of anaconda as well).
% conda list beautifulsoup4 4.8.1 py37_0 % conda install beautifulsoup4 Collecting package metadata (current_repodata.json): done Solving environment: done # All requested packages already installed.
There is no confusion between pip and conda, so although it is an amateur's judgment, it seems that the installation destination is not different.
Those who have been installed with pip "from bs4 import Beautifulsoup",
Or though it was imported as "from beautifulsoup4 import Beautifulsoup",
As far as I tried
ImportError: cannot import name 'Beautifulsoup' from 'bs4' (/Users/******/anaconda3/lib/python3.7/site-packages/bs4/__init__.py)
After all, import was not possible.
Also, I've looked at some similar questions like "Can't import library",
As far as I'm concerned, most of the cases are due to confusion of installation locations. In my case it was not helpful.
Sorry for your inconvenience, but please answer.
Please point out if there are any deficiencies.
Answer # 1
from bs4 import Beautifulsoup
from bs4 import BeautifulSoup
- python 3x - library cannot be installed due to ssl error in python pip
- could not import the lzma module your installed python is incomplete about attempting to use lzma
- python - unable to import packages installed in virtual environment with anaconda
- python - the library installed by pip cannot be imported no module named'selenium'
- python - i get an import error on an installed module
- tell me about python (how to use python import)
- python - mysqlclient cannot be installed on centos7
- python 3x - xg boost cannot be installed from anaconda prompt
- i want to call a python library from java
- python - i want to get the publisher name from the book name with the national diet library search api, but it does not hit
- unable to install python library from github to google colab
- python - about installation of library civlfeat
- cgi using python does not recognize the mysqldb library
- python - tensorflow installed in virtual environment cannot be imported
- eliminating pandas install and import in python pyenv export ldflags
- i want to add processing to the python library
- python - import of pygame
- python - i want to import a csv file locally
- css - the text will come under the menu installed on the left, so i would like to ask you how to solve it
- python does not import scikit-learn
- How do I correctly fix broken /stopped working Python modules?
- python : I get an Attribute Error with cx_Freeze. : Module'setuptools._distutils.command' has no attribute'install'
- python : How do I do a rough text check?
- I want to convert a Python script to app /exe format.
- python : How to import dynamic library correctly?
- The console fails to log out to the installed python, python is output from the anaconda environment
- python : Separating point boundaries in matplotlib