mirror of
https://github.com/moeacgx/Telegram-Panel.git
synced 2026-09-03 07:17:51 +08:00
release: 发布 v1.31.54
## 本次版本主要更新 ### 修复问题 - 账号导入恢复创建一对一 WARP,导入时可为账号创建独立 WARP 连接。 - 批量加群、订阅、启用 Bot 遇到 Telegram 瞬时连接取消时会重建客户端重试,降低 A task was canceled 失败。 - 账号持续活跃任务支持 Bot 私聊目标,可向 @xxxbot、t.me/xxxbot?start=... 和 tg://resolve?domain=xxxbot 发送文字词典内容。 - 修正 Release Linux 测试中 WARP 环境差异断言,避免不同 CI 平台因未启用 WARP 与非 Linux 环境返回顺序不同而误判。 ## 验证 - dotnet build TelegramPanel.sln -c Release --no-restore - dotnet test tests/TelegramPanel.Web.Tests/TelegramPanel.Web.Tests.csproj -c Release --no-build - pnpm --dir frontend test - pnpm --dir frontend run build - mkdocs build --strict
This commit is contained in:
@@ -9,10 +9,10 @@
|
||||
<!-- 主版本: 重大变更/不兼容更新 -->
|
||||
<!-- 次版本: 新功能/兼容性更新 -->
|
||||
<!-- 修订号: Bug修复/小改进 -->
|
||||
<Version>1.31.53</Version>
|
||||
<AssemblyVersion>1.31.53.0</AssemblyVersion>
|
||||
<FileVersion>1.31.53.0</FileVersion>
|
||||
<InformationalVersion>1.31.53</InformationalVersion>
|
||||
<Version>1.31.54</Version>
|
||||
<AssemblyVersion>1.31.54.0</AssemblyVersion>
|
||||
<FileVersion>1.31.54.0</FileVersion>
|
||||
<InformationalVersion>1.31.54</InformationalVersion>
|
||||
<!-- Release 包、version.txt 与 tag 必须完全一致,禁止 SDK 自动追加 +GitSha。 -->
|
||||
<IncludeSourceRevisionInInformationalVersion>false</IncludeSourceRevisionInInformationalVersion>
|
||||
|
||||
|
||||
@@ -192,7 +192,7 @@ proxyText: http://user-a:password-a@proxy-a.example.com:8080
|
||||
返回最近 20 条失败明细。字段包括 `time_utc`、`account_id`、`target_type`、
|
||||
`target` 和 `reason`。自 v1.31.48 起,`user_chat_active` 会在
|
||||
`config.recent_failures` 返回最多 100 条账号活跃失败明细,字段包括 `time_utc`、
|
||||
`account_id`、`account`、`target` 和 `reason`;自 v1.31.53 起,`user_chat_active`
|
||||
`account_id`、`account`、`target` 和 `reason`;自 v1.31.54 起,`user_chat_active`
|
||||
目标支持群组、频道和 Bot 私聊(`@xxxbot`、`t.me/xxxbot?start=...`、
|
||||
`tg://resolve?domain=xxxbot`),可用于给外部 Bot 发送文字词典内容。`user_join_subscribe`
|
||||
会在 `config.failures` 返回最多 200 条失败明细,字段包括 `accountId`、`target` 和
|
||||
@@ -201,7 +201,7 @@ proxyText: http://user-a:password-a@proxy-a.example.com:8080
|
||||
该字段为空表示没有失败或运行的是尚未支持失败明细的旧版本。
|
||||
|
||||
失败原因来自当次执行,最长 500 字符。接口调用方不得把其中内容当作稳定错误码;需要自动化
|
||||
判断时应优先匹配 Telegram/RPC 的明确错误标识。回滚到 v1.31.52 或更早版本不会解析 Bot 私聊活跃目标,
|
||||
判断时应优先匹配 Telegram/RPC 的明确错误标识。回滚到 v1.31.53 或更早版本不会解析 Bot 私聊活跃目标,
|
||||
也不会继续写入新增重试后的失败描述。
|
||||
|
||||
`auto_change_login_email` 任务使用 `config.items` 返回最近账号级结果,字段包括 `time_utc`、
|
||||
|
||||
@@ -389,7 +389,7 @@ public sealed class ImportProxyFirstConnectionTests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public async Task 创建一对一WARP导入在不支持环境会在首次Telegram验证前拒绝且不创建容器记录()
|
||||
public async Task 创建一对一WARP导入在环境未就绪时会在首次Telegram验证前拒绝且不创建容器记录()
|
||||
{
|
||||
await using var fixture = await ImportFixture.CreateAsync(OutboundProxyProtocols.Http);
|
||||
|
||||
@@ -400,7 +400,7 @@ public sealed class ImportProxyFirstConnectionTests
|
||||
proxyBinding: new AccountProxyBindingInput("warp_per_account"));
|
||||
|
||||
Assert.False(result.Success);
|
||||
Assert.Contains("WARP 仅支持在 Linux Docker 环境中运行", result.Error);
|
||||
Assert.True(IsWarpUnavailableError(result.Error), result.Error);
|
||||
Assert.Equal(0, fixture.Importer.ImportCount);
|
||||
Assert.Empty(await fixture.Db.Accounts.AsNoTracking().ToListAsync());
|
||||
Assert.Empty(await fixture.Db.OutboundProxies.AsNoTracking()
|
||||
@@ -852,6 +852,13 @@ public sealed class ImportProxyFirstConnectionTests
|
||||
client.MTProxyUrl);
|
||||
}
|
||||
|
||||
private static bool IsWarpUnavailableError(string? error)
|
||||
{
|
||||
return !string.IsNullOrWhiteSpace(error)
|
||||
&& (error.Contains("WARP 仅支持在 Linux Docker 环境中运行", StringComparison.Ordinal)
|
||||
|| error.Contains("WARP 未启用,请设置 Proxy:Warp:Enabled=true", StringComparison.Ordinal));
|
||||
}
|
||||
|
||||
private static Client CreateClient()
|
||||
{
|
||||
var sessionPath = Path.Combine(
|
||||
|
||||
Reference in New Issue
Block a user