Thanks to visit codestin.com
Credit goes to docs.python.org


11.5.9 HTTPBasicAuthHandler Objects

http_error_401( req, fp, code, msg, hdrs)
Retry the request with authentication information, if available.

See About this document... for information on suggesting changes.