fix(adopt): 后台预升级加闲置门控并修采纳徽标定位与取消确认
This commit is contained in:
@@ -8981,6 +8981,8 @@ class Handler(SimpleHTTPRequestHandler):
|
||||
if not self._allowed_origin():
|
||||
return self._json({"error": "forbidden"}, 403)
|
||||
u = urllib.parse.urlparse(self.path)
|
||||
if u.path.startswith("/api/") and "/license" not in u.path:
|
||||
adopt_api.ACTIVITY["ts"] = time.time() # 决策 341 补记二:交互哨(排除授权轮询)——后台预升级见 60 秒内有请求就让路
|
||||
p, q = u.path, urllib.parse.parse_qs(u.query)
|
||||
_g = license_gate.intercept("GET", p) # 授权门禁:未激活/过期只放授权页与 /api/license/*
|
||||
if _g is not None:
|
||||
@@ -9281,6 +9283,8 @@ class Handler(SimpleHTTPRequestHandler):
|
||||
if not self._allowed_origin():
|
||||
return self._json({"error": "forbidden"}, 403)
|
||||
u = urllib.parse.urlparse(self.path)
|
||||
if u.path.startswith("/api/") and "/license" not in u.path:
|
||||
adopt_api.ACTIVITY["ts"] = time.time() # 决策 341 补记二:交互哨(同 do_GET,排除授权轮询)
|
||||
ln = int(self.headers.get("Content-Length") or 0)
|
||||
if ln > 280 * 1024 * 1024: # 上限:二进制直传 200MB + 旧 base64 协议膨胀余量
|
||||
return self._json({"error": "请求体过大"}, 413)
|
||||
|
||||
Reference in New Issue
Block a user