Skip to content

Commit

Permalink
Merge pull request #858 from Guovin/dev
Browse files Browse the repository at this point in the history
Release: v1.6.0
  • Loading branch information
Guovin authored Jan 22, 2025
2 parents 9622a65 + bbbb188 commit 6b2030f
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 19 deletions.
39 changes: 39 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,44 @@
# 更新日志(Changelog)

## v1.6.0

### 2025/1/22

- ✨ 新增支持`本地源`
- ✨ 使用新的代理地址`https://ghproxy.cc`
- ✨ 新增支持Docker修改定时任务时间,环境变量:`UPDATE_CRON1`, `UPDATE_CRON2`#440
- ✨ 新增同域名重复执行测速次数配置`sort_duplicate_limit`
- ✨ 新增`广东联通`RTP
- 🐛 修复补偿模式结果输出问题(#813
- 🐛 修复无域名后缀、空格接口匹配问题(#832#837
- 🐛 修复无结果状态文件写入报错(#841
- 🐛 修复GUI无法保存测速延迟设置
- 🐛 修复Docker版本文件丢失(#800
- 🪄 `open_use_old_result`更名为`open_history`
- 🪄 优化对接口中`%`符号的转义处理(#853
- 🪄 优化以接口Host去重(#846
- 🪄 支持协议类型偏好`ipv_type_prefer`可设置为空,可实现全部类型按速率排序输出结果

<details>
<summary>English</summary>

- ✨ Added support for `local sources`
- ✨ Using new proxy address `https://ghproxy.cc`
- ✨ Added support for modifying Docker scheduled task time, environment variables: `UPDATE_CRON1`, `UPDATE_CRON2` (#440)
- ✨ Added configuration for the number of speed tests for the same domain `sort_duplicate_limit`
- ✨ Added `Guangdong Unicom` RTP
- 🐛 Fixed compensation mode result output issue (#813)
- 🐛 Fixed issue with interface matching without domain suffix and spaces (#832, #837)
- 🐛 Fixed error writing to file in no result state (#841)
- 🐛 Fixed GUI unable to save speed test delay settings
- 🐛 Fixed Docker version file loss issue (#800)
- 🪄 `open_use_old_result` renamed to `open_history`
- 🪄 Optimized escaping of `%` symbol in interfaces (#853)
- 🪄 Optimized deduplication by interface host (#846)
- 🪄 Supported setting `ipv_type_prefer` to empty, allowing all types to be sorted by speed for output results

</details>

## v1.5.9

### 2025/1/8
Expand Down
13 changes: 6 additions & 7 deletions tkinter_ui/prefer.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,12 @@ def init_ui(self, root=None):
self.prefer_ipv_type_combo = ttk.Combobox(frame_prefer_ipv_type)
self.prefer_ipv_type_combo.pack(side=tk.LEFT, padx=4, pady=8)
self.prefer_ipv_type_combo["values"] = ("IPv4", "IPv6", "自动")
ipv_type_prefer = config.ipv_type_prefer[0]
if ipv_type_prefer == "ipv4":
self.prefer_ipv_type_combo.current(0)
elif ipv_type_prefer == "ipv6":
self.prefer_ipv_type_combo.current(1)
elif ipv_type_prefer in ["自动", "auto"]:
self.prefer_ipv_type_combo.current(2)
ipv_type_prefer = config.ipv_type_prefer
if ipv_type_prefer:
first_ipv_type_prefer = ipv_type_prefer[0]
prefer_map = {"ipv4": 0, "ipv6": 1, "自动": 2, "auto": 2}
if first_ipv_type_prefer in prefer_map:
self.prefer_ipv_type_combo.current(prefer_map[first_ipv_type_prefer])
self.prefer_ipv_type_combo.bind(
"<<ComboboxSelected>>", self.update_ipv_type_prefer
)
Expand Down
9 changes: 5 additions & 4 deletions utils/channel.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,11 @@ def get_channel_data_from_file(channels, file, whitelist, open_local=config.open
if name in whitelist:
for whitelist_url in whitelist[name]:
category_dict[name].append((whitelist_url, None, None, "whitelist"))
if open_local and url:
data = format_channel_data(url, "local")
if data not in category_dict[name]:
category_dict[name].append(data)
if open_local:
if url:
data = format_channel_data(url, "local")
if data not in category_dict[name]:
category_dict[name].append(data)
if local_data and name in local_data:
for local_url in local_data[name]:
local_channel_data = format_channel_data(local_url, "local")
Expand Down
14 changes: 8 additions & 6 deletions utils/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,17 @@ def ipv_type_prefer(self):

@property
def ipv4_num(self):
return self.config.getint("Settings", "ipv4_num", fallback=5) if self.config.get(
"Settings", "ipv_type_prefer", fallback=""
) else ""
try:
return self.config.getint("Settings", "ipv4_num", fallback=5)
except:
return ""

@property
def ipv6_num(self):
return self.config.getint("Settings", "ipv6_num", fallback=5) if self.config.get(
"Settings", "ipv_type_prefer", fallback=""
) else ""
try:
return self.config.getint("Settings", "ipv6_num", fallback=5)
except:
return ""

@property
def ipv6_support(self):
Expand Down
2 changes: 1 addition & 1 deletion utils/speed.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ async def get_speed_m3u8(url: str, filter_resolution: bool = config.open_filter_
info = {'speed': None, 'delay': None, 'resolution': None}
location = None
try:
url = quote(url, safe=':/?$&=@[]').partition('$')[0]
url = quote(url, safe=':/?$&=@[]%').partition('$')[0]
async with ClientSession(connector=TCPConnector(ssl=False), trust_env=True) as session:
headers = await get_m3u8_headers(url, session)
location = headers.get('Location')
Expand Down
2 changes: 1 addition & 1 deletion version.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"version": "1.5.9",
"version": "1.6.0",
"name": "IPTV-API"
}

0 comments on commit 6b2030f

Please sign in to comment.