diff options
author | Skip Montanaro <skip@pobox.com> | 2007-08-28 23:22:52 (GMT) |
---|---|---|
committer | Skip Montanaro <skip@pobox.com> | 2007-08-28 23:22:52 (GMT) |
commit | 1a413136843f17ede1d3f87f9bab23a07748312c (patch) | |
tree | 0385cbd7f00a571b53e1cfbef1ac2763cd33ee6f /Lib/robotparser.py | |
parent | bf138333ce006c0b3bc49ddd4379312171ef2aae (diff) | |
download | cpython-1a413136843f17ede1d3f87f9bab23a07748312c.zip cpython-1a413136843f17ede1d3f87f9bab23a07748312c.tar.gz cpython-1a413136843f17ede1d3f87f9bab23a07748312c.tar.bz2 |
fixes 813986
Diffstat (limited to 'Lib/robotparser.py')
-rw-r--r-- | Lib/robotparser.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/robotparser.py b/Lib/robotparser.py index 0a2ede1..52ab348 100644 --- a/Lib/robotparser.py +++ b/Lib/robotparser.py @@ -230,6 +230,11 @@ class URLopener(urllib.FancyURLopener): urllib.FancyURLopener.__init__(self, *args) self.errcode = 200 + def prompt_user_passwd(self, host, realm): + ## If robots.txt file is accessible only with a password, + ## we act as if the file wasn't there. + return None, None + def http_error_default(self, url, fp, errcode, errmsg, headers): self.errcode = errcode return urllib.FancyURLopener.http_error_default(self, url, fp, errcode, |