fix: update deps for opencode 2.0.4
CI / verify (pull_request) Successful in 10s

This commit is contained in:
2026-09-16 09:46:01 +02:00
parent 20f6087340
commit 1c48fab124
8 changed files with 146 additions and 111 deletions
+12 -9
View File
@@ -62,17 +62,20 @@ export default Plugin.define({
status: async ({ sessionID }) => (await quota.status(sessionID)) ?? null,
});
await quota.init();
// Subscribe before the first read: configuration can publish its catalog while
// Subscribe before the first read: configuration can publish its models while
// asynchronous setup is running.
const updates = (async () => {
for await (const event of context.event.subscribe({ signal: controller.signal })) {
if (
event.location &&
(event.location.directory !== context.location.directory ||
event.location.workspaceID !== context.location.workspaceID)
)
continue;
if (event.type === "catalog.updated") {
if (event.location) {
const workspaceID =
"workspaceID" in event.location ? event.location.workspaceID : undefined;
if (
event.location.directory !== context.location.directory ||
workspaceID !== context.location.workspaceID
)
continue;
}
if (event.type === "model.updated") {
models = await discover(context, selected.provider);
await context.agent.reload();
} else if (event.type === "agent.updated") {
@@ -105,7 +108,7 @@ export default Plugin.define({
}
})().catch((error) => {
if (!controller.signal.aborted)
console.error("stanp-opencode catalog update failed", error);
console.error("stanp-opencode model update failed", error);
});
models = await discover(context, selected.provider);
const { data: initialAgents } = await context.agent.list();