Posts: 25
Threads: 11
Joined: Jun 2017
Nov-16-2019, 11:56 PM
(This post was last modified: Nov-17-2019, 08:30 AM by buran.)
Hi all,
I seem to have a similar situation trying to import beautifulsoup4. I've installed beautifulsoup4 using pip in a command prompt. All good. However, I try to use my IDLE and import but, "module not fould" error.
It seems as though I may have 2 installations of python. One install is the one I configured for my environment variables, and I think the other one installed when I installed Visual Studio. So, do I uninstall Visual Studio and hope that the modules will work with my IDLE? Or maybe uninstall both?
OS: WIN10, PYTHON3.7.2 AND 3.7.4
Thanks for any help
"Human history becomes more and more a race between education and catastrophe." - H. G. Wells (1866-1946)
Posts: 212
Threads: 25
Joined: Aug 2019
Nov-17-2019, 08:23 AM
(This post was last modified: Nov-17-2019, 08:49 AM by newbieAuggie2019.)
(Nov-16-2019, 11:56 PM)deep_logic Wrote: Hi all,
I seem to have a similar situation trying to import beautifulsoup4. I've installed beautifulsoup4 using pip in a command prompt. All good. However, I try to use my IDLE and import but, "module not found" error.
It seems as though I may have 2 installations of python. One install is the one I configured for my environment variables, and I think the other one installed when I installed Visual Studio. So, do I uninstall Visual Studio and hope that the modules will work with my IDLE? Or maybe uninstall both?
OS: WIN10, PYTHON3.7.2 AND 3.7.4
Thanks for any help Hi!
I think python versions 3.7.2 and 3.7.4 are similar, so I would just keep the 3.7.4, but it is my opinion. Then I would install again beautifulsoup4 in it, if it isn't already there. You can afterwards, check with the program I included in point 3) of my post #4 on this thread:
https://python-forum.io/Thread-Windows-c...d-packages
All the best,
newbieAuggie2019
"That's been one of my mantras - focus and simplicity. Simple can be harder than complex: You have to work hard to get your thinking clean to make it simple. But it's worth it in the end because once you get there, you can move mountains."
Steve Jobs
Posts: 8,151
Threads: 160
Joined: Sep 2016
(Nov-16-2019, 11:56 PM)deep_logic Wrote: I've installed beautifulsoup4 using pip in a command prompt. (Nov-16-2019, 11:56 PM)deep_logic Wrote: PYTHON3.7.2 AND 3.7.4 you installed in one python distribution and trying to use it from the other.
To avoid confusion - I would uninstall both python version and make clean install.
And VS Code is preferable, IDLE is poor IDE
Posts: 7,312
Threads: 123
Joined: Sep 2016
(Nov-17-2019, 08:29 AM)buran Wrote: So, do I uninstall Visual Studio and hope that the modules will work with my IDLE? Or maybe uninstall both? Visual Studio comes with own version of Python,how Windows see Python is trough Environment Variables Path .
Here you can fix so have a main version that work from command line.
Visual Studio is not the same as VS Code which is better option for Python.
Here a couple of links you can look at.
Python 3.7 and pip installation under Windows
VS Code from start
Posts: 8,151
Threads: 160
Joined: Sep 2016
I overlooked that it's Visual Studio and not VS Code
Posts: 25
Threads: 11
Joined: Jun 2017
Ok, I didn't realize that there is yet another version of Visual Studio. So, VS Code is better for python?
Do I need to go to python's site and re-download python? Or do I let VS Code install it's own python?
Thanks for the help.
"Human history becomes more and more a race between education and catastrophe." - H. G. Wells (1866-1946)
Posts: 7,312
Threads: 123
Joined: Sep 2016
(Nov-17-2019, 08:46 PM)deep_logic Wrote: So, VS Code is better for python? Yes is't more geared against Python.
(Nov-17-2019, 08:46 PM)deep_logic Wrote: Do I need to go to python's site and re-download python? Or do I let VS Code install it's own python? VS Code dos not comes with Python,so use one from python.org(use 3.7 for now as there has some pip install problem with 3.8 on Windows).
Look at links i posted all is explain there in details.
You most have python and pip works likes from cmd/ cmder
E:\div_code
python -V
Python 3.7.3
E:\div_code
λ pip -V
pip 19.3.1 from c:\python37\lib\site-packages\pip (python 3.7) When this work install VS Code.
Posts: 25
Threads: 11
Joined: Jun 2017
So, @ buran and @ snippsat - thanks for your help.
I have uninstalled all python(s), with a caveat. @ buran, you alluded to the environment variable path is different than what is in my cmd line and what is in VS Code.
I reinstalled VS Code with the extensions that @ snippsat has suggested. However, I would like to use beautifulsoup to do some webscraping. This is just to teach myself (I'm a bad teacher  )
Since VS Code has python installed (in my case not the python in my environment variable path), how do you install more modules and packages? Am I missing something? Does VS Code not allow more modules?
I attached the A)environment variable window B)the version of python I'm using in VS Code. Obviously they aren't matching up.
How do I "point" my python interpreter to the python3.8 that I used for installing beautifulsoup4?
Thanks for your patience and hope I didn't make this too broad of a discussion.
Attached Files
Thumbnail(s)
"Human history becomes more and more a race between education and catastrophe." - H. G. Wells (1866-1946)
Posts: 7,312
Threads: 123
Joined: Sep 2016
Nov-26-2019, 04:40 PM
(This post was last modified: Nov-26-2019, 04:40 PM by snippsat.)
(Nov-26-2019, 03:50 PM)deep_logic Wrote: how do you install more modules and packages? Am I missing something? Does VS Code not allow more modules? You do it all from command line with pip ,do not mix it VS Code before all work from command line.
If you do pip -V from cmd what do get?
deep_logic Wrote:How do I "point" my python interpreter to the python3.8 that I used for installing beautifulsoup4? Look at this again VS Code from start.
Here a screen shot of my VS Code setup,what Python interpreter used is down in left corner(click to see option).
Posts: 8,151
Threads: 160
Joined: Sep 2016
Nov-26-2019, 04:43 PM
(This post was last modified: Nov-26-2019, 04:43 PM by buran.)
Also,, looking at the second image, isn't there also Anaconda installation? there is .conada\envs\ebv\python.exe
|