(self, url: str | bytes, user_agent: str | bytes)
| 101 | return cls(robotstxt_body, spider) |
| 102 | |
| 103 | def allowed(self, url: str | bytes, user_agent: str | bytes) -> bool: |
| 104 | user_agent = to_unicode(user_agent) |
| 105 | url = to_unicode(url) |
| 106 | return cast("bool", self.rp.is_allowed(user_agent, url)) |
| 107 | |
| 108 | |
| 109 | class ProtegoRobotParser(RobotParser): |
nothing calls this directly
no test coverage detected