A team of long-lived bots for DeepSeek Harness, with main bots, bot-to-bot messages and group chats.
Offer a newer release after a completed update
shadow-of-light123515f1619e839
diff --git a/ds-bot/src/host/update.js b/ds-bot/src/host/update.jsindex eb23a898..14e72be5 100644--- a/ds-bot/src/host/update.js+++ b/ds-bot/src/host/update.js@@ -215,6 +215,9 @@ export function install(rt) {}status.latest = found.versiontarget = newer(found.version, status.current) ? found : null+ // The note that reported the last update is a one-time message; a newer+ // release found later in the same run still offers itself.+ if (target !== null && status.phase === 'updated') status.phase = 'idle'}/** Ask where the package came from for its newest version; a fresh check ignores the last answer. */diff --git a/ds-bot/test/update.test.js b/ds-bot/test/update.test.jsindex 127c6e32..537e3915 100644--- a/ds-bot/test/update.test.js+++ b/ds-bot/test/update.test.js@@ -356,6 +356,21 @@ test('a reinstall refused by an application state also puts the old version backrmSync(home, { recursive: true, force: true, maxRetries: 5 })})+test('a newer release is offered in the run that reported the last update', async () => {+ const home = newHome()+ writeFileSync(join(home, 'update.json'), JSON.stringify({ from: '0.2.0', to: PKG.version, spec: `${PKG.name}@${PKG.version}`, startedAt: new Date().toISOString() }))+ const { rt } = start({+ home,+ source: `${PKG.name}@^${PKG.version}`,+ answers: { [`https://registry.npmjs.org/${PKG.name}/latest`]: { version: '9.0.0' } },+ })+ assert.equal(rt.updateView().phase, 'updated')+ const view = await rt.updateCheck({ fresh: true })+ assert.equal(view.available, true)+ assert.equal(view.phase, 'idle')+ rmSync(home, { recursive: true, force: true, maxRetries: 5 })+})+test('the note for the version now running shows the update once and is consumed', async () => {const home = newHome()writeFileSync(join(home, 'update.json'), JSON.stringify({ from: '0.2.0', to: PKG.version, spec: `${PKG.name}@${PKG.version}`, startedAt: new Date().toISOString() }))