I am having difficulty using wget on jupyter notebook. I have installed this package using the following code: %conda install wget
I receive an error when I import the wget package, even after I have restarted the kernel after installation.
It is a non-interactive commandline tool, so it may easily be called from scripts, cron jobs, terminals without X-Windows support, etc
It isn’t a Python package. (Or at least not the one you installed so far.) One way to learn which are Python and aren’t is if you could install it via pip and it is at pypi, the Python Package Index, like numpy or pandas then it is a Python package and you may be able to use import. If you search wget at PyPi there you do get a wget listed, but this isn’t what you installed via conda. And you’ll note it isn’t well maintained as it hasn’t been updated since 2015 if you look at releases. You’ll note the one that got installed via conda is two years old and so much more recent than that one at PyPi.
Type the following in a Jupyter cell to get the help manual for this command line utility.
!wget --help
It is easy to use in your Jupyer notebook. Just put an exclamation in front of any wget command example you see. The exclamation point at the front of a typical command line command lets you run something you’d normally run in terminal in a Jupyter cell.
I don’t recommand this but I just verified it will work…
If you insist on using the poorly maintained wget you could import via import wget, the first run the following within your notebook:
%pip install wget
Most people when referencing wget will mean the current version of the command line utility you installed via %conda install wget.
Hi
Again thank you so much for your time and efforts. I am learning a lot from you and I am grateful of it. I am coming into another error when I type, !wget --help
The error I have is the following below: zsh:1: command not found: wget