From c0d41c9567cbfd0954cc10bcbe9a50ab7334e331 Mon Sep 17 00:00:00 2001 From: j_hao104 Date: Mon, 8 Jan 2024 10:18:13 +0800 Subject: [PATCH] [update] :chicken: 2.4.2 --- README.md | 24 ++++++++++++------------ docs/changelog.rst | 3 ++- fetcher/proxyFetcher.py | 20 +++++++------------- 3 files changed, 21 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index f48bad803..0c970a345 100644 --- a/README.md +++ b/README.md @@ -205,19 +205,19 @@ PROXY_FETCHER = [ 目前实现的采集免费代理网站有(排名不分先后, 下面仅是对其发布的免费代理情况, 付费代理测评可以参考[这里](https://zhuanlan.zhihu.com/p/33576641)): - | 代理名称 | 状态 | 更新速度 | 可用率 | 地址 | 代码 | - | --------- | ---- | -------- | ------ | ----- |------------------------------------------------| - | 站大爷 | ✔ | ★ | ** | [地址](https://www.zdaye.com/) | [`freeProxy01`](/fetcher/proxyFetcher.py#L28) | - | 66代理 | ✔ | ★ | * | [地址](http://www.66ip.cn/) | [`freeProxy02`](/fetcher/proxyFetcher.py#L50) | - | 开心代理 | ✔ | ★ | * | [地址](http://www.kxdaili.com/) | [`freeProxy03`](/fetcher/proxyFetcher.py#L63) | + | 代理名称 | 状态 | 更新速度 | 可用率 | 地址 | 代码 | + |---------------| ---- | -------- | ------ | ----- |------------------------------------------------| + | 站大爷 | ✔ | ★ | ** | [地址](https://www.zdaye.com/) | [`freeProxy01`](/fetcher/proxyFetcher.py#L28) | + | 66代理 | ✔ | ★ | * | [地址](http://www.66ip.cn/) | [`freeProxy02`](/fetcher/proxyFetcher.py#L50) | + | 开心代理 | ✔ | ★ | * | [地址](http://www.kxdaili.com/) | [`freeProxy03`](/fetcher/proxyFetcher.py#L63) | | FreeProxyList | ✔ | ★ | * | [地址](https://www.freeproxylists.net/zh/) | [`freeProxy04`](/fetcher/proxyFetcher.py#L74) | - | 快代理 | ✔ | ★ | * | [地址](https://www.kuaidaili.com/) | [`freeProxy05`](/fetcher/proxyFetcher.py#L92) | - | FateZero | ✔ | ★★ | * | [地址](http://proxylist.fatezero.org) | [`freeProxy06`](/fetcher/proxyFetcher.py#L111) | - | 云代理 | ✔ | ★ | * | [地址](http://www.ip3366.net/) | [`freeProxy07`](/fetcher/proxyFetcher.py#L124) | - | 小幻代理 | ✔ | ★★ | * | [地址](https://ip.ihuan.me/) | [`freeProxy08`](/fetcher/proxyFetcher.py#L134) | - | 免费代理库 | ✔ | ☆ | * | [地址](http://ip.jiangxianli.com/) | [`freeProxy09`](/fetcher/proxyFetcher.py#L144) | - | 89代理 | ✔ | ☆ | * | [地址](https://www.89ip.cn/) | [`freeProxy10`](/fetcher/proxyFetcher.py#L155) | - | 稻壳代理 | ✔ | ★★ | *** | [地址](https://www.docip.ne) | [`freeProxy11`](/fetcher/proxyFetcher.py#L165) | + | 快代理 | ✔ | ★ | * | [地址](https://www.kuaidaili.com/) | [`freeProxy05`](/fetcher/proxyFetcher.py#L92) | + | 冰凌代理 | ✔ | ★★★ | * | [地址](https://www.binglx.cn/) | [`freeProxy06`](/fetcher/proxyFetcher.py#L111) | + | 云代理 | ✔ | ★ | * | [地址](http://www.ip3366.net/) | [`freeProxy07`](/fetcher/proxyFetcher.py#L123) | + | 小幻代理 | ✔ | ★★ | * | [地址](https://ip.ihuan.me/) | [`freeProxy08`](/fetcher/proxyFetcher.py#L133) | + | 免费代理库 | ✔ | ☆ | * | [地址](http://ip.jiangxianli.com/) | [`freeProxy09`](/fetcher/proxyFetcher.py#L143) | + | 89代理 | ✔ | ☆ | * | [地址](https://www.89ip.cn/) | [`freeProxy10`](/fetcher/proxyFetcher.py#L154) | + | 稻壳代理 | ✔ | ★★ | *** | [地址](https://www.docip.ne) | [`freeProxy11`](/fetcher/proxyFetcher.py#L164) | 如果还有其他好的免费代理网站, 可以在提交在[issues](https://github.com/jhao104/proxy_pool/issues/71), 下次更新时会考虑在项目中支持。 diff --git a/docs/changelog.rst b/docs/changelog.rst index fb4336d58..e3889882c 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -3,11 +3,12 @@ ChangeLog ========== -develop +2.4.2 (2024-01-18) ------------------ 1. 代理格式检查支持需认证的代理格式 `username:password@ip:port` ; (2023-03-10) 2. 新增代理源 **稻壳代理**; (2023-05-15) +3. 新增代理源 **冰凌代理**; (2023-01-18) 2.4.1 (2022-07-17) ------------------ diff --git a/fetcher/proxyFetcher.py b/fetcher/proxyFetcher.py index 1ed43cbad..cfc37f928 100644 --- a/fetcher/proxyFetcher.py +++ b/fetcher/proxyFetcher.py @@ -109,14 +109,13 @@ def freeProxy05(page_count=1): @staticmethod def freeProxy06(): - """ FateZero http://proxylist.fatezero.org/ """ - url = "http://proxylist.fatezero.org/proxy.list" + """ 冰凌代理 https://www.binglx.cn """ + url = "https://www.binglx.cn/?page=1" try: - resp_text = WebRequest().get(url).text - for each in resp_text.split("\n"): - json_info = json.loads(each) - if json_info.get("country") == "CN": - yield "%s:%s" % (json_info.get("host", ""), json_info.get("port", "")) + tree = WebRequest().get(url).tree + proxy_list = tree.xpath('.//table//tr') + for tr in proxy_list[1:]: + yield ':'.join(tr.xpath('./td/text()')[0:2]) except Exception as e: print(e) @@ -236,12 +235,7 @@ def freeProxy11(): if __name__ == '__main__': p = ProxyFetcher() - for _ in p.freeProxy11(): + for _ in p.freeProxy06(): print(_) # http://nntime.com/proxy-list-01.htm - - -# freeProxy04 -# freeProxy07 -# freeProxy08