获取完整的代理 URL
(self)
| 397 | |
| 398 | @property |
| 399 | def proxy_url(self) -> str: |
| 400 | """获取完整的代理 URL""" |
| 401 | if self.type == "http": |
| 402 | scheme = "http" |
| 403 | elif self.type == "socks5": |
| 404 | scheme = "socks5" |
| 405 | else: |
| 406 | scheme = self.type |
| 407 | |
| 408 | auth = "" |
| 409 | if self.username and self.password: |
| 410 | auth = f"{self.username}:{self.password}@" |
| 411 | |
| 412 | return f"{scheme}://{auth}{self.host}:{self.port}" |
nothing calls this directly
no outgoing calls
no test coverage detected