ai_co_discuss 0.4.38 → 0.4.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/runner/panel_updater.mjs +3 -1
- package/web/modern.js +1 -1
package/package.json
CHANGED
package/runner/panel_updater.mjs
CHANGED
|
@@ -52,7 +52,9 @@ async function main() {
|
|
|
52
52
|
for (let waited = 0; waited < EXIT_WAIT_MS && alive(Number(values.pid)); waited += POLL_MS) await sleep(POLL_MS);
|
|
53
53
|
let failure = null;
|
|
54
54
|
for (let attempt = 1; attempt <= INSTALL_ATTEMPTS; attempt += 1) {
|
|
55
|
-
|
|
55
|
+
// --prefer-online: the version was just read from the registry, while npm's cached package list may predate it
|
|
56
|
+
// (a fresh release fails with "notarget" until the cache expires).
|
|
57
|
+
try { await npm(['install', '--global', '--prefer-online', `${NPM_PACKAGE}@${job.version}`], values.data); failure = null; break; }
|
|
56
58
|
catch (error) { failure = error; if (attempt < INSTALL_ATTEMPTS) await sleep(RETRY_MS); }
|
|
57
59
|
}
|
|
58
60
|
save(failure ? { status: 'install_failed', steps: [...job.steps, `安装失败:${failure.message}`] }
|