@ouro.bot/cli 0.1.0-alpha.1116 → 0.1.0-alpha.1117
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/changelog.json
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_note": "This changelog is maintained as part of the PR/version-bump workflow. Agent-curated, not auto-generated. Agents read this file directly via read_file to understand what changed between versions.",
|
|
3
3
|
"versions": [
|
|
4
|
+
{
|
|
5
|
+
"version": "0.1.0-alpha.1117",
|
|
6
|
+
"changes": [
|
|
7
|
+
"Wakes from a wake runner are delivered immediately by default: the Copilot app puts the message into the session at its next turn boundary. They used to be queued behind the session's current run, and a drain that works for hours without going idle received news about new issues hours late, including about issues that had since closed. A runner entry can set `delivery` to `\"enqueue\"` to keep the old behavior."
|
|
8
|
+
]
|
|
9
|
+
},
|
|
4
10
|
{
|
|
5
11
|
"version": "0.1.0-alpha.1116",
|
|
6
12
|
"changes": [
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<?xml version="1.0"?>
|
|
2
2
|
<Container version="2">
|
|
3
3
|
<Name>ouro-butler</Name>
|
|
4
|
-
<Repository>ghcr.io/ourostack/ouroboros-butler:0.1.0-alpha.
|
|
4
|
+
<Repository>ghcr.io/ourostack/ouroboros-butler:0.1.0-alpha.1117</Repository>
|
|
5
5
|
<Registry>https://github.com/ourostack/ouroboros/pkgs/container/ouroboros-butler</Registry>
|
|
6
6
|
<Network>host</Network>
|
|
7
7
|
<Shell>sh</Shell>
|
package/dist/heart/identity.js
CHANGED
|
@@ -190,7 +190,7 @@ function normalizeWakeRunners(rawSense, configFile) {
|
|
|
190
190
|
const names = new Set();
|
|
191
191
|
result.wakeRunners = wakeRunners.map((entry, index) => {
|
|
192
192
|
const item = (entry && typeof entry === "object" ? entry : {});
|
|
193
|
-
const { name, command, everySeconds, session } = item;
|
|
193
|
+
const { name, command, everySeconds, session, delivery } = item;
|
|
194
194
|
if (typeof name !== "string" || !name.trim())
|
|
195
195
|
fail(`wakeRunners[${index}].name must be a non-empty name`);
|
|
196
196
|
if (!Array.isArray(command) || command.length === 0 || command.some(part => typeof part !== "string" || !part))
|
|
@@ -199,6 +199,8 @@ function normalizeWakeRunners(rawSense, configFile) {
|
|
|
199
199
|
fail(`wakeRunners[${index}].everySeconds must be a whole number of seconds, 10 or more`);
|
|
200
200
|
if (session !== undefined && (typeof session !== "string" || !session.trim()))
|
|
201
201
|
fail(`wakeRunners[${index}].session must be a Copilot app session id`);
|
|
202
|
+
if (delivery !== undefined && delivery !== "immediate" && delivery !== "enqueue")
|
|
203
|
+
fail(`wakeRunners[${index}].delivery must be "immediate" or "enqueue"`);
|
|
202
204
|
const key = name.trim();
|
|
203
205
|
if (names.has(key))
|
|
204
206
|
fail(`wakeRunners[${index}].name ${key} is listed twice`);
|
|
@@ -208,6 +210,7 @@ function normalizeWakeRunners(rawSense, configFile) {
|
|
|
208
210
|
command: command,
|
|
209
211
|
...(everySeconds !== undefined ? { everySeconds: everySeconds } : {}),
|
|
210
212
|
...(session !== undefined ? { session: session.trim() } : {}),
|
|
213
|
+
...(delivery !== undefined ? { delivery: delivery } : {}),
|
|
211
214
|
};
|
|
212
215
|
});
|
|
213
216
|
}
|
|
@@ -52,6 +52,10 @@ const wake_runner_state_1 = require("./wake-runner-state");
|
|
|
52
52
|
* is sent to its session (`session` is optional when the runner names one). `done` is the argv that reports the wake's
|
|
53
53
|
* delivery: it runs after a successful send, and with `--error <reason>` added after a failed one, so the command can keep
|
|
54
54
|
* the wake pending until it lands. `status` lines show under the app-sessions row of `ouro status`.
|
|
55
|
+
*
|
|
56
|
+
* A wake is delivered "immediate" by default: the app admits it at the session's next turn boundary. A session that works for
|
|
57
|
+
* hours in one run never goes idle, so a message queued behind that run ("enqueue") waits until the run ends, however old the
|
|
58
|
+
* news in it. A runner can ask for "enqueue" when a wake should never interrupt.
|
|
55
59
|
*/
|
|
56
60
|
exports.WAKE_RUNNER_DEFAULT_SECONDS = 300;
|
|
57
61
|
exports.WAKE_RUNNER_TIMEOUT_MS = 2 * 60_000;
|
|
@@ -96,8 +100,8 @@ const runCommand = (argv, timeoutMs) => new Promise(resolve => {
|
|
|
96
100
|
});
|
|
97
101
|
});
|
|
98
102
|
exports.runCommand = runCommand;
|
|
99
|
-
const sendWake = (client) => async (session, message) => {
|
|
100
|
-
const result = await (0, client_1.sendToAppSession)(session, message, { ...client, delivery
|
|
103
|
+
const sendWake = (client) => async (session, message, delivery) => {
|
|
104
|
+
const result = await (0, client_1.sendToAppSession)(session, message, { ...client, delivery });
|
|
101
105
|
return { ok: result.ok, error: result.error };
|
|
102
106
|
};
|
|
103
107
|
exports.sendWake = sendWake;
|
|
@@ -121,7 +125,7 @@ async function runWakeRunner(runner, deps) {
|
|
|
121
125
|
for (const wake of output.wakes) {
|
|
122
126
|
const session = wake.session ?? runner.session;
|
|
123
127
|
const sent = session
|
|
124
|
-
? await deps.send(session, wake.message).catch((error) => ({ ok: false, error: error.message }))
|
|
128
|
+
? await deps.send(session, wake.message, runner.delivery ?? "immediate").catch((error) => ({ ok: false, error: error.message }))
|
|
125
129
|
: { ok: false, error: "the wake names no session and the runner has none" };
|
|
126
130
|
const reason = sent.ok ? null : sent.error ?? "the app refused the message";
|
|
127
131
|
if (!reason)
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ouro.bot/cli",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.1117",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@ouro.bot/cli",
|
|
9
|
-
"version": "0.1.0-alpha.
|
|
9
|
+
"version": "0.1.0-alpha.1117",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@anthropic-ai/sdk": "^0.78.0",
|
|
12
12
|
"@ouro.bot/friends": "0.1.0-alpha.18",
|