I am new to python (I’m using python3) and I am trying to use urllib2 to learn to make web crawler. I can’t seem to find it anywhere. I can import urllib, but urllib2 is not in the same directory as urllib and I receive an error in terminal when I try to import urllib2.
From my understanding, urllib2 is supposed to be part of pythons standard library. Where can I find it? Is there somewhere I can just download it separately and place it into the same directory as urllib?
Python 3 refactored
urllibandurllib2into a new package calledurllibwith submodules.Use
urllib.requestandurllib.errorinstead.