diff --git a/src/resources/extensions/get-secrets-from-user.ts b/src/resources/extensions/get-secrets-from-user.ts index 8452c8fbd..08e68e55e 100644 --- a/src/resources/extensions/get-secrets-from-user.ts +++ b/src/resources/extensions/get-secrets-from-user.ts @@ -286,12 +286,12 @@ export async function showSecretsSummary( const existingSet = new Set(existingKeys); - await (ctx.ui.custom as Function)((tui: any, theme: Theme, _kb: any, done: () => void) => { + await ctx.ui.custom((tui: any, theme: Theme, _kb: any, done: (r: null) => void) => { let cachedLines: string[] | undefined; function handleInput(_data: string) { - // Any key dismisses - done(); + // Any key dismisses — pass null to satisfy the typed done() callback + done(null); } function render(width: number): string[] { diff --git a/src/resources/extensions/gsd/auto.ts b/src/resources/extensions/gsd/auto.ts index a5d312c4b..befc69e8c 100644 --- a/src/resources/extensions/gsd/auto.ts +++ b/src/resources/extensions/gsd/auto.ts @@ -506,14 +506,18 @@ export async function startAuto( const manifestStatus = await getManifestStatus(base, mid); if (manifestStatus && manifestStatus.pending.length > 0) { const result = await collectSecretsFromManifest(base, mid, ctx); - ctx.ui.notify( - `Secrets collected: ${result.applied.length} applied, ${result.skipped.length} skipped, ${result.existingSkipped.length} already set.`, - "info", - ); + if (result && result.applied && result.skipped && result.existingSkipped) { + ctx.ui.notify( + `Secrets collected: ${result.applied.length} applied, ${result.skipped.length} skipped, ${result.existingSkipped.length} already set.`, + "info", + ); + } else { + ctx.ui.notify("Secrets collection skipped.", "info"); + } } } catch (err) { ctx.ui.notify( - `Secrets collection error: ${err instanceof Error ? err.message : String(err)}`, + `Secrets collection error: ${err instanceof Error ? err.message : String(err)}. Continuing with next task.`, "warning", ); } @@ -1304,14 +1308,18 @@ async function dispatchNextUnit( const manifestStatus = await getManifestStatus(basePath, mid); if (manifestStatus && manifestStatus.pending.length > 0) { const result = await collectSecretsFromManifest(basePath, mid, ctx); - ctx.ui.notify( - `Secrets collected: ${result.applied.length} applied, ${result.skipped.length} skipped, ${result.existingSkipped.length} already set.`, - "info", - ); + if (result && result.applied && result.skipped && result.existingSkipped) { + ctx.ui.notify( + `Secrets collected: ${result.applied.length} applied, ${result.skipped.length} skipped, ${result.existingSkipped.length} already set.`, + "info", + ); + } else { + ctx.ui.notify("Secrets collection skipped.", "info"); + } } } catch (err) { ctx.ui.notify( - `Secrets collection error: ${err instanceof Error ? err.message : String(err)}`, + `Secrets collection error: ${err instanceof Error ? err.message : String(err)}. Continuing with next task.`, "warning", ); }