MCPcopy Index your code
hub / github.com/python/cpython / request_rate

Method request_rate

Lib/urllib/robotparser.py:210–218  ·  view source on GitHub ↗
(self, useragent)

Source from the content-addressed store, hash-verified

208 return None
209
210 def request_rate(self, useragent):
211 if not self.mtime():
212 return None
213 for entry in self.entries:
214 if entry.applies_to(useragent):
215 return entry.req_rate
216 if self.default_entry:
217 return self.default_entry.req_rate
218 return None
219
220 def site_maps(self):
221 if not self.sitemaps:

Callers 3

test_read_404Method · 0.95
test_request_rateMethod · 0.80
test_basicMethod · 0.80

Calls 2

mtimeMethod · 0.95
applies_toMethod · 0.45

Tested by 3

test_read_404Method · 0.76
test_request_rateMethod · 0.64
test_basicMethod · 0.64