@ouro.bot/cli 0.1.0-alpha.707 → 0.1.0-alpha.708
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 +6 -0
- package/dist/rsvp/cli.js +11 -3
- package/dist/rsvp/cutover.js +4 -2
- package/package.json +1 -1
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.708",
|
|
6
|
+
"changes": [
|
|
7
|
+
"Prefer cached runtime credentials for native RSVP refresh and smoke runs, falling back to vault refresh only on cold start."
|
|
8
|
+
]
|
|
9
|
+
},
|
|
4
10
|
{
|
|
5
11
|
"version": "0.1.0-alpha.707",
|
|
6
12
|
"changes": [
|
package/dist/rsvp/cli.js
CHANGED
|
@@ -197,6 +197,14 @@ function resolveLatestSnapshot(agentRoot) {
|
|
|
197
197
|
function machineIdForCli() {
|
|
198
198
|
return (0, machine_identity_1.loadOrCreateMachineIdentity)().machineId;
|
|
199
199
|
}
|
|
200
|
+
async function resolveRsvpRuntimeCredentialConfig(agent) {
|
|
201
|
+
const cached = (0, runtime_credentials_1.readRuntimeCredentialConfig)(agent);
|
|
202
|
+
return cached.ok ? cached : (0, runtime_credentials_1.refreshRuntimeCredentialConfig)(agent, { preserveCachedOnFailure: true });
|
|
203
|
+
}
|
|
204
|
+
async function resolveRsvpMachineRuntimeCredentialConfig(agent) {
|
|
205
|
+
const cached = (0, runtime_credentials_1.readMachineRuntimeCredentialConfig)(agent);
|
|
206
|
+
return cached.ok ? cached : (0, runtime_credentials_1.refreshMachineRuntimeCredentialConfig)(agent, machineIdForCli(), { preserveCachedOnFailure: true });
|
|
207
|
+
}
|
|
200
208
|
function blueBubblesChatFor(config) {
|
|
201
209
|
const sendTarget = config.bluebubblesRoute.chatIdentifier
|
|
202
210
|
? { kind: "chat_identifier", value: config.bluebubblesRoute.chatIdentifier }
|
|
@@ -515,8 +523,8 @@ async function executeRefresh(command, deps) {
|
|
|
515
523
|
result: configResult,
|
|
516
524
|
});
|
|
517
525
|
}
|
|
518
|
-
const runtimeConfig = await (
|
|
519
|
-
const machineRuntimeConfig = await (
|
|
526
|
+
const runtimeConfig = await resolveRsvpRuntimeCredentialConfig(command.agent);
|
|
527
|
+
const machineRuntimeConfig = await resolveRsvpMachineRuntimeCredentialConfig(command.agent);
|
|
520
528
|
const readiness = (0, config_1.validateRsvpReadiness)({
|
|
521
529
|
agent: command.agent,
|
|
522
530
|
agentRoot,
|
|
@@ -703,7 +711,7 @@ async function executeSmoke(command, deps) {
|
|
|
703
711
|
const sendAllowed = wantsLiveSend;
|
|
704
712
|
let delivery;
|
|
705
713
|
if (sendAllowed) {
|
|
706
|
-
const bluebubbles = rsvpBlueBubblesClientConfig(configResult.config, await (
|
|
714
|
+
const bluebubbles = rsvpBlueBubblesClientConfig(configResult.config, await resolveRsvpMachineRuntimeCredentialConfig(command.agent));
|
|
707
715
|
const sent = await (0, client_1.createBlueBubblesClient)(bluebubbles.config, bluebubbles.channelConfig).sendText({
|
|
708
716
|
chat: blueBubblesChatFor(configResult.config),
|
|
709
717
|
text: answer.text,
|
package/dist/rsvp/cutover.js
CHANGED
|
@@ -158,8 +158,10 @@ async function defaultNativeBlueBubblesCredentialHealth(input, deps) {
|
|
|
158
158
|
if (!input.agent) {
|
|
159
159
|
return { ok: false, detail: "native BlueBubbles credential check requires an agent" };
|
|
160
160
|
}
|
|
161
|
-
const
|
|
162
|
-
const runtimeConfig =
|
|
161
|
+
const cachedRuntimeConfig = (0, runtime_credentials_1.readMachineRuntimeCredentialConfig)(input.agent);
|
|
162
|
+
const runtimeConfig = cachedRuntimeConfig.ok
|
|
163
|
+
? cachedRuntimeConfig
|
|
164
|
+
: await (0, runtime_credentials_1.refreshMachineRuntimeCredentialConfig)(input.agent, (0, machine_identity_1.loadOrCreateMachineIdentity)({ homeDir: deps.homeDir() }).machineId, { preserveCachedOnFailure: true });
|
|
163
165
|
if (!runtimeConfig.ok) {
|
|
164
166
|
return { ok: false, detail: "machine runtime/config unavailable" };
|
|
165
167
|
}
|