Update IPTV搜索引擎采集.py

This commit is contained in:
frxz751113
2024-09-17 08:50:03 +08:00
committed by GitHub
parent e327c3d04b
commit 77685d0e89
+1 -1
View File
@@ -102,7 +102,7 @@ def gen_files(valid_ips, province, isp):
with open(txt_filename, 'a', encoding='utf-8') as new_file: with open(txt_filename, 'a', encoding='utf-8') as new_file:
new_file.write(f'{province}{isp},#genre#\n') new_file.write(f'{province}{isp},#genre#\n')
for url in valid_ips: for url in valid_ips:
if index < 10: if index < 15:
# 确保 url 是一个完整的 URL 字符串,并且以 'http://' 开头 # 确保 url 是一个完整的 URL 字符串,并且以 'http://' 开头
base_url = "rtp://" base_url = "rtp://"
if not url.startswith("http://"): if not url.startswith("http://"):