Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: 在Armhf架构的Linux设备上运行,无法连接至腾讯登录服务器 Invalid count to read, count: -4 fail #444

Open
4 tasks done
EillesWan opened this issue Jul 16, 2024 · 5 comments
Labels
bug? Maybe it's a bug

Comments

@EillesWan
Copy link

EillesWan commented Jul 16, 2024

请确保您已阅读以上注意事项,并勾选下方的确认框。

  • 我已经仔细阅读上述内容
  • 我已经使用 最新构建 测试过,问题依旧存在。
  • 我已经在 Issue Tracker 中找过我要提出的问题,没有找到相同问题的ISSUE。
  • 我已知晓并同意,此处仅用于汇报程序中存在的问题。若这个 Issue 是关于其他非程序本身问题,则我的 Issue 可能会被无条件自动关闭或/并锁定。(其它疑问请考虑加入TG群询问或在discussions中提问)

Lagrange项目

OneBot

所使用/依赖的Lagrange项目对应的commit

f219082(日前最新Release)

运行环境

Linux

运行架构

arm

连接方式

反向 WebSocket

重现步骤

于Actions中Build内下载,使用上述设备运行:Linux on Armhf(32位)
无论是否使用扫码登陆/密码登录,皆无法改变该错误。

期望的结果是什么?

正常登录,或出现扫码登录选项之类。

实际的结果是什么?

重复出现以下日志报错。

简单的复现代码/链接(可选)

No response

Trace 级别日志记录(可选)

info: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [INFORMATION]: Reconnect to http://114.221.149.227:8080/
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]: Socket Error: Invalid count to read, count: -4
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]:    at Lagrange.Core.Utility.Binary.BinaryPacket.ReadBytes(Int32 count)
         at Lagrange.Core.Internal.Packets.SsoPacker.Parse(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.PacketContext.DispatchPacket(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.SocketContext.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.CallbackClientListener.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.ClientListener.ReceiveLoop(SocketSession session, CancellationToken token)
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]: Socket Disconnected, Scheduling Reconnect
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]: Socket Error: Invalid count to read, count: -4
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]:    at Lagrange.Core.Utility.Binary.BinaryPacket.ReadBytes(Int32 count)
         at Lagrange.Core.Internal.Packets.SsoPacker.Parse(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.PacketContext.DispatchPacket(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.SocketContext.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.CallbackClientListener.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.ClientListener.ReceiveLoop(SocketSession session, CancellationToken token)
fail: Lagrange.Core.BotContext[0]
      [2024-07-17 05:52:29] [SocketContext] [FATAL]: Socket Disconnected, Scheduling Reconnect
(后重复)

补充说明(可选)

设备:Surface RT
芯片:NVIDIA Tegra 3(Armhf架构)
内存:2GB
操作系统:RaspiOS-Bookworm (2023.10.10发行版)

此错误类似 #247@Executor-Cheng 的评论,但与该issue下其他人的状况均不甚相符。以上错误出现的时间阶段较早。

@EillesWan EillesWan added the bug? Maybe it's a bug label Jul 16, 2024
@EillesWan
Copy link
Author

现在那个 Socket Error: Invalid count to read, count: 后面的数字变得不一定是 -4 了。……

@Linwenxuan04
Copy link
Contributor

可能已经修复 请尝试

@EillesWan
Copy link
Author

并未,出现疑似新的问题,开启Trace级日志后输出如下:

info: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [INFORMATION]: Reconnect to http://36.155.205.230:8080/
trce: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [ServiceContext] [DEBUG]: Outgoing SSOFrame: trpc.qq_new_tech.status_svc.StatusService.Register
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]: Socket Error: Not enough data to read, remaining: 131 required: 5062604
trce: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [DEBUG]: Data: 000000a70000000c02a000000005308d334403494d04e2337782158892828abb424185684765c8171614f89f7d4775e61c1f515063e7573bb8edf9d1f81e676039c2be6b1e34454e2e2ac74ad39c22d45720befcf83ff801d3e599425e3a66ac9b9e225ff5498f262bcb1a512ea88a6e91aabdcb112ee8aaed5b357a6a366da35b049214c9281fcea132c55ba4f78c64b7261aaae2ab1b0484056f87f61be80e8abc642178d55c
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]: Socket Disconnected, Scheduling Reconnect
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]:    at Lagrange.Core.Utility.Binary.BinaryPacket.ReadBytes(Prefix flag)
         at Lagrange.Core.Internal.Packets.SsoPacker.Parse(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.PacketContext.DispatchPacket(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.SocketContext.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.CallbackClientListener.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.ClientListener.ReceiveLoop(SocketSession session, CancellationToken token)
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]: Socket Disconnected, Scheduling Reconnect
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]:    at Lagrange.Core.Utility.Binary.BinaryPacket.ReadBytes(Prefix flag)
         at Lagrange.Core.Internal.Packets.SsoPacker.Parse(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.PacketContext.DispatchPacket(BinaryPacket packet)
         at Lagrange.Core.Internal.Context.SocketContext.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.CallbackClientListener.OnRecvPacket(ReadOnlySpan`1 packet)
         at Lagrange.Core.Internal.Network.ClientListener.ReceiveLoop(SocketSession session, CancellationToken token)
fail: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:42] [SocketContext] [FATAL]: Socket Error: Not enough data to read, remaining: 131 required: 5062604
trce: Lagrange.Core.BotContext[0]
      [2024-08-14 11:56:47] [ServiceContext] [DEBUG]: Outgoing SSOFrame: Heartbeat.Alive
(后除了Data不一样外皆重复,且Ctrl+C无法停止运行)

使用的build所属commit为7f67ae9

运行环境未变,补充DotNet版本信息:
版本: 8.0.7
架构:ARM
COMMIT:2aade6beb0
RID:linux-arm

运行时包含:
Microsoft.AspNetCore.App 8.0.7
Microsoft.NETCore.App 8.0.7

Copy link
Contributor

新版本可能修复

@EillesWan
Copy link
Author

并未,同上评论之错误,且拉格兰执行后无法透过 Ctrl+C 关闭

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug? Maybe it's a bug
Projects
None yet
Development

No branches or pull requests

3 participants