feat: extend golden time to 11:00 (10:30+ still possible per user feedback)

isGoldenTime() now covers 9:30-11:00 (was 9:30-10:10) so late-morning
restock windows are treated as rush mode: no page refresh, no MAX_RL
cap on 555 retries. Bump userscript to v8.19 and add CHANGELOG entry.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
OLmatter
2026-06-15 19:33:55 +08:00
co-authored by Claude Opus 4.7
parent 514d0b330e
commit e07ec9e181
3 changed files with 13 additions and 8 deletions
+5
View File
@@ -1,5 +1,10 @@
# 修复历史
## 2026-06-15
- 发布用户脚本 v8.19:黄金时间从 9:30-10:10 延长到 9:30-11:00,覆盖中午还在补货的窗口(用户反馈 10:30 之后仍有成功下单)。
- 黄金时间内的 `MAX_RL` 无上限重试逻辑同步覆盖 9:30-11:00 全段。
## 2026-06-06
- 修复 Win11 用户启动后端时报 `ModuleNotFoundError: No module named 'PIL'` 的问题。
+4 -4
View File
@@ -1,7 +1,7 @@
// ==UserScript==
// @name 智谱 GLM Coding Plan 抢购助手 + 本地 OCR 自动验证码
// @namespace http://tampermonkey.net/
// @version 8.18
// @version 8.19
// @description GLM Coding Rush / 智谱 GLM Coding Plan 抢购助手,一键抢购油猴脚本 / Tampermonkey userscript,配合本地 CPU/GPU OCR 自动识别中文点选验证码并点击,支持多窗口并发、限流重试和支付页安全保护
// @author mumumi
// @include https://*bigmodel.cn/glm-coding*
@@ -611,14 +611,14 @@
return 0;
}
function isRealBizId(id) { return id && !id.startsWith('debug-'); }
// ── v8.0: 黄金时间判断(9:30-10:10)──────────────────────────────────────
// ── v8.19: 黄金时间判断(9:30-11:00)────────────────────────────────────
function isGoldenTime() {
const now = new Date();
const h = now.getHours();
const m = now.getMinutes();
const time = h * 60 + m;
const start = 9 * 60 + 30; // 9:30
const end = 10 * 60 + 10; // 10:10
const end = 11 * 60 + 0; // 11:00
return time >= start && time <= end;
}
// ── DOM 访问 ──────────────────────────────────────────────────────────────
@@ -963,7 +963,7 @@
sweepRestocks.sort((a, b) => a.msUntil - b.msUntil);
const nearest = sweepRestocks[0];
const sleep = calcSleepMs(nearest.msUntil);
// ── v8.0: 黄金时间(9:30-10:10)禁止刷新页面 ──────────────────────────
// ── v8.19: 黄金时间(9:30-11:00)禁止刷新页面 ─────────────────────────
if (isGoldenTime()) {
setBar(`🔥 黄金时间!补货倒计时 <b>${fmt(nearest.msUntil)}</b>,禁止刷新,高频监控!`, '#ff4d4f');
qIdx = 0; sweepRestocks = []; sweepBusyCount = 0; return;
@@ -1,7 +1,7 @@
// ==UserScript==
// @name 智谱 GLM Coding Plan 抢购助手 + 本地 OCR 自动验证码
// @namespace http://tampermonkey.net/
// @version 8.18
// @version 8.19
// @description GLM Coding Rush / 智谱 GLM Coding Plan 抢购助手,一键抢购油猴脚本 / Tampermonkey userscript,配合本地 CPU/GPU OCR 自动识别中文点选验证码并点击,支持多窗口并发、限流重试和支付页安全保护
// @author mumumi
// @include https://*bigmodel.cn/glm-coding*
@@ -611,14 +611,14 @@
return 0;
}
function isRealBizId(id) { return id && !id.startsWith('debug-'); }
// ── v8.0: 黄金时间判断(9:30-10:10)──────────────────────────────────────
// ── v8.19: 黄金时间判断(9:30-11:00)────────────────────────────────────
function isGoldenTime() {
const now = new Date();
const h = now.getHours();
const m = now.getMinutes();
const time = h * 60 + m;
const start = 9 * 60 + 30; // 9:30
const end = 10 * 60 + 10; // 10:10
const end = 11 * 60 + 0; // 11:00
return time >= start && time <= end;
}
// ── DOM 访问 ──────────────────────────────────────────────────────────────
@@ -963,7 +963,7 @@
sweepRestocks.sort((a, b) => a.msUntil - b.msUntil);
const nearest = sweepRestocks[0];
const sleep = calcSleepMs(nearest.msUntil);
// ── v8.0: 黄金时间(9:30-10:10)禁止刷新页面 ──────────────────────────
// ── v8.19: 黄金时间(9:30-11:00)禁止刷新页面 ─────────────────────────
if (isGoldenTime()) {
setBar(`🔥 黄金时间!补货倒计时 <b>${fmt(nearest.msUntil)}</b>,禁止刷新,高频监控!`, '#ff4d4f');
qIdx = 0; sweepRestocks = []; sweepBusyCount = 0; return;