v0.4.0:窗口调度/限流分类/可观测性,抢购改每账号独立循环,移除 CLI 只保留 GUI

This commit is contained in:
yml2213
2026-10-16 18:14:30 +08:00
parent 29aed15e4e
commit 8b3b14654f
20 changed files with 2309 additions and 664 deletions
+4 -1
View File
@@ -204,6 +204,9 @@ func (c *HTTPClient) CallRPC(ctx context.Context, service, method string, reqStr
if httpResp.StatusCode < 200 || httpResp.StatusCode >= 300 {
return nil, fmt.Errorf("http status %d: %s", httpResp.StatusCode, string(respBody[:min(len(respBody), 200)]))
}
// debug 级打印原始帧前缀:协议异常(缺少 tRsp)时这是唯一的现场证据。
c.logf("[HTTP] 响应 %s.%s status=%d %dB head=%s",
service, method, httpResp.StatusCode, len(respBody), wup.HexHead(respBody, rawFrameHeadBytes))
var resp wup.Response
if err := resp.Decode(respBody); err != nil {
@@ -215,7 +218,7 @@ func (c *HTTPClient) CallRPC(ctx context.Context, service, method string, reqStr
return nil, err
}
if !ok {
return nil, fmt.Errorf("%s.%s 响应缺少 tRsp/tResp", service, method)
return nil, protocolResponseError(service, method, &resp)
}
}
return &resp, nil