@pikku/cli 0.12.69 → 0.12.70

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.
Files changed (88) hide show
  1. package/cli.schema.json +1 -1
  2. package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +1 -1
  3. package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +1 -1
  4. package/dist/.pikku/channel/pikku-channel-types.gen.js +1 -1
  5. package/dist/.pikku/cli/pikku-cli-channel.js +1 -1
  6. package/dist/.pikku/cli/pikku-cli-client.gen.d.ts +1 -1
  7. package/dist/.pikku/cli/pikku-cli-client.gen.js +1 -1
  8. package/dist/.pikku/cli/pikku-cli-contracts-meta.gen.d.ts +1 -1
  9. package/dist/.pikku/cli/pikku-cli-contracts-meta.gen.js +1 -1
  10. package/dist/.pikku/cli/pikku-cli-types.gen.d.ts +1 -1
  11. package/dist/.pikku/cli/pikku-cli-types.gen.js +1 -1
  12. package/dist/.pikku/cli/pikku-cli-wirings-meta.gen.js +1 -1
  13. package/dist/.pikku/cli/pikku-cli-wirings-meta.gen.json +16 -0
  14. package/dist/.pikku/cli/pikku-cli-wirings.gen.d.ts +1 -1
  15. package/dist/.pikku/cli/pikku-cli-wirings.gen.js +1 -1
  16. package/dist/.pikku/cli/pikku-cli.gen.d.ts +1 -1
  17. package/dist/.pikku/cli/pikku-cli.gen.js +1 -1
  18. package/dist/.pikku/console/pikku-node-types.gen.d.ts +1 -1
  19. package/dist/.pikku/function/pikku-function-types.gen.d.ts +1 -1
  20. package/dist/.pikku/function/pikku-function-types.gen.js +1 -1
  21. package/dist/.pikku/function/pikku-functions-meta.gen.js +1 -1
  22. package/dist/.pikku/function/pikku-functions-meta.gen.json +7 -7
  23. package/dist/.pikku/function/pikku-functions.gen.js +1 -1
  24. package/dist/.pikku/http/pikku-http-types.gen.d.ts +1 -1
  25. package/dist/.pikku/http/pikku-http-types.gen.js +1 -1
  26. package/dist/.pikku/http/pikku-http-wirings-meta.gen.js +1 -1
  27. package/dist/.pikku/http/pikku-http-wirings.gen.d.ts +1 -1
  28. package/dist/.pikku/http/pikku-http-wirings.gen.js +1 -1
  29. package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +1 -1
  30. package/dist/.pikku/mcp/pikku-mcp-types.gen.js +1 -1
  31. package/dist/.pikku/pikku-bootstrap.gen.d.ts +1 -1
  32. package/dist/.pikku/pikku-bootstrap.gen.js +1 -1
  33. package/dist/.pikku/pikku-meta-service.gen.d.ts +1 -1
  34. package/dist/.pikku/pikku-meta-service.gen.js +1 -1
  35. package/dist/.pikku/pikku-services.gen.d.ts +4 -2
  36. package/dist/.pikku/pikku-services.gen.js +2 -0
  37. package/dist/.pikku/pikku-types.gen.d.ts +1 -1
  38. package/dist/.pikku/pikku-types.gen.js +1 -1
  39. package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +1 -1
  40. package/dist/.pikku/queue/pikku-queue-types.gen.js +1 -1
  41. package/dist/.pikku/queue/pikku-queue-workers-wirings-meta.gen.js +1 -1
  42. package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.d.ts +1 -1
  43. package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.js +1 -1
  44. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +1 -1
  45. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +1 -1
  46. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +1 -1
  47. package/dist/.pikku/schemas/register.gen.js +1 -1
  48. package/dist/.pikku/schemas/schemas/DevInput.schema.json +1 -1
  49. package/dist/.pikku/schemas/schemas/PikkuCLIConfig.schema.json +1 -1
  50. package/dist/.pikku/schemas/schemas/ScenarioRunInput.schema.json +1 -1
  51. package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +1 -1
  52. package/dist/.pikku/secrets/pikku-secret-types.gen.js +1 -1
  53. package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +1 -1
  54. package/dist/.pikku/secrets/pikku-secrets.gen.js +1 -1
  55. package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +1 -1
  56. package/dist/.pikku/trigger/pikku-trigger-types.gen.js +1 -1
  57. package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +1 -1
  58. package/dist/.pikku/variables/pikku-variable-types.gen.js +1 -1
  59. package/dist/.pikku/variables/pikku-variables.gen.d.ts +1 -1
  60. package/dist/.pikku/variables/pikku-variables.gen.js +1 -1
  61. package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +1 -1
  62. package/dist/.pikku/workflow/pikku-workflow-types.gen.js +1 -1
  63. package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +1 -1
  64. package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +1 -1
  65. package/dist/bin/pikku-bin.mjs +2 -2
  66. package/dist/src/cli.wiring.js +16 -0
  67. package/dist/src/functions/commands/all.js +14 -1
  68. package/dist/src/functions/commands/bun-coverage-loader.d.ts +11 -0
  69. package/dist/src/functions/commands/bun-coverage-loader.js +42 -0
  70. package/dist/src/functions/commands/dev.d.ts +6 -0
  71. package/dist/src/functions/commands/dev.js +19 -4
  72. package/dist/src/functions/commands/scenario.d.ts +3 -0
  73. package/dist/src/functions/commands/scenario.js +52 -11
  74. package/dist/src/functions/commands/serve.js +4 -1
  75. package/dist/src/functions/commands/start-coverage.d.ts +13 -0
  76. package/dist/src/functions/commands/start-coverage.js +26 -0
  77. package/dist/src/functions/commands/watch.js +2 -1
  78. package/dist/src/functions/wirings/workflow/serialize-scenario-actors.d.ts +0 -6
  79. package/dist/src/functions/wirings/workflow/serialize-scenario-actors.js +1 -15
  80. package/dist/src/services.js +14 -1
  81. package/dist/src/utils/file-writer.d.ts +1 -0
  82. package/dist/src/utils/file-writer.js +9 -0
  83. package/dist/src/utils/meta-diff.d.ts +32 -0
  84. package/dist/src/utils/meta-diff.js +144 -0
  85. package/dist/src/utils/serialize-schemas.js +1 -1
  86. package/dist/src/utils/strip-verbose-meta.js +3 -0
  87. package/dist/tsconfig.tsbuildinfo +1 -1
  88. package/package.json +5 -3
@@ -102,7 +102,10 @@ export const serve = pikkuSessionlessFunc({
102
102
  ...inMemoryServices,
103
103
  getInspectorState,
104
104
  });
105
- const resolvedServices = { ...singletonServices, getInspectorState };
105
+ const resolvedServices = {
106
+ ...singletonServices,
107
+ getInspectorState,
108
+ };
106
109
  pikkuState(null, 'package', 'singletonServices', resolvedServices);
107
110
  resolvedServices.workflowService?.wireQueueWorkers?.();
108
111
  const { serverLifecycleFactory } = inspectorState.filesAndMethods;
@@ -0,0 +1,13 @@
1
+ import { type CoverageService } from '@pikku/core/services';
2
+ interface CoverageLogger {
3
+ info(message: string): void;
4
+ warn(message: string): void;
5
+ }
6
+ /**
7
+ * Starts the coverage backend for `pikku dev --coverage`: V8 precise coverage
8
+ * on Node, istanbul load-time instrumentation on Bun. Must run before the
9
+ * user bootstrap is imported so the Bun loader plugin sees every module.
10
+ * Returns undefined (with a warning) when no backend is available.
11
+ */
12
+ export declare function startCoverageService(logger: CoverageLogger, rootDir: string): Promise<CoverageService | undefined>;
13
+ export {};
@@ -0,0 +1,26 @@
1
+ import { V8CoverageService, IstanbulCoverageService, } from '@pikku/core/services';
2
+ import { registerBunCoverageLoader } from './bun-coverage-loader.js';
3
+ const isBunRuntime = () => typeof globalThis.Bun !== 'undefined';
4
+ /**
5
+ * Starts the coverage backend for `pikku dev --coverage`: V8 precise coverage
6
+ * on Node, istanbul load-time instrumentation on Bun. Must run before the
7
+ * user bootstrap is imported so the Bun loader plugin sees every module.
8
+ * Returns undefined (with a warning) when no backend is available.
9
+ */
10
+ export async function startCoverageService(logger, rootDir) {
11
+ if (isBunRuntime()) {
12
+ await registerBunCoverageLoader({ rootDir });
13
+ logger.info('Istanbul coverage enabled (Bun) — snapshot via console:takeLiveCoverage, reset via console:resetLiveCoverage');
14
+ return new IstanbulCoverageService();
15
+ }
16
+ const coverageService = new V8CoverageService();
17
+ try {
18
+ await coverageService.start();
19
+ logger.info('V8 precise coverage enabled — snapshot via console:takeLiveCoverage, reset via console:resetLiveCoverage');
20
+ return coverageService;
21
+ }
22
+ catch (e) {
23
+ logger.warn(`V8 precise coverage is not supported on this runtime — continuing without coverage: ${e instanceof Error ? e.message : e}`);
24
+ return undefined;
25
+ }
26
+ }
@@ -3,7 +3,7 @@ import chokidar from 'chokidar';
3
3
  import { pikkuDevReloader } from '@pikku/core/dev';
4
4
  export const watch = pikkuSessionlessFunc({
5
5
  remote: true,
6
- func: async ({ logger, config }, { hmr }, { rpc }) => {
6
+ func: async ({ logger, config, invalidateInspectorState }, { hmr }, { rpc }) => {
7
7
  const watchDirectories = [
8
8
  ...new Set([config.emailTemplatesDir, ...config.srcDirectories].filter(Boolean)),
9
9
  ];
@@ -29,6 +29,7 @@ export const watch = pikkuSessionlessFunc({
29
29
  const handle = async () => {
30
30
  try {
31
31
  const start = Date.now();
32
+ invalidateInspectorState();
32
33
  await rpc.invoke('all');
33
34
  logger.info({
34
35
  message: `✓ Generated in ${Date.now() - start}ms`,
@@ -1,8 +1,2 @@
1
1
  import type { PikkuCLIConfig } from '../../../../types/config.js';
2
- /**
3
- * Generate the typed scenario actor registry from pikku.config.json's
4
- * `scenarios.actors`. Apps wire the result as the `actors` singleton service:
5
- *
6
- * actors: createScenarioActors({ apiUrl, secret })
7
- */
8
2
  export declare const serializeScenarioActors: (actors: NonNullable<NonNullable<PikkuCLIConfig["scenarios"]>["actors"]>, agentMapImportPath: string) => string;
@@ -1,14 +1,5 @@
1
- /**
2
- * Generate the typed scenario actor registry from pikku.config.json's
3
- * `scenarios.actors`. Apps wire the result as the `actors` singleton service:
4
- *
5
- * actors: createScenarioActors({ apiUrl, secret })
6
- */
7
1
  export const serializeScenarioActors = (actors, agentMapImportPath) => {
8
- return `/**
9
- * Scenario actors declared in pikku.config.json (\`scenarios.actors\`).
10
- * Any scenario can impersonate any actor.
11
- */
2
+ return `/** Scenario actors declared in pikku.config.json (\`scenarios.actors\`) */
12
3
  import {
13
4
  createHttpScenarioActors,
14
5
  type HttpScenarioActorsConfig,
@@ -21,17 +12,12 @@ export const scenarioActorConfigs = ${JSON.stringify(actors, null, 2)} as const
21
12
 
22
13
  export type ScenarioActorName = keyof typeof scenarioActorConfigs
23
14
 
24
- /** \`actor.converse({ agent })\` is constrained to the project's agent names. */
25
15
  export type AgentName = keyof AgentMap & string
26
16
  export type TypedScenarioActors = Record<
27
17
  ScenarioActorName,
28
18
  ScenarioActor<AgentName>
29
19
  >
30
20
 
31
- /**
32
- * Build the injected \`actors\` service: one lazy HTTP actor per registry
33
- * entry, signing in via the Better Auth actor plugin on first invoke.
34
- */
35
21
  export const createScenarioActors = (
36
22
  options: Omit<HttpScenarioActorsConfig, 'actors'>
37
23
  ): TypedScenarioActors =>
@@ -10,6 +10,7 @@ import { CLILoggerForwarder } from './services/cli-logger-forwarder.service.js';
10
10
  import { existsSync } from 'fs';
11
11
  import { readFile, writeFile } from 'fs/promises';
12
12
  import { loadManifest } from './utils/contract-versions.js';
13
+ import { getTsWriteGeneration } from './utils/file-writer.js';
13
14
  import { join } from 'path';
14
15
  import { NodeBundler } from './deploy/bundler/node-bundler.js';
15
16
  import { BunBundler } from './deploy/bundler/bun-bundler.js';
@@ -142,6 +143,8 @@ export const createSingletonServices = async (config) => {
142
143
  // Store unfiltered state
143
144
  let unfilteredState = preloadedInspectorState;
144
145
  let unfilteredStateIsSetupOnly = false;
146
+ let inspectedTsGeneration;
147
+ let inspectorInvalidated = false;
145
148
  const getInspectorState = async (refresh = false, setupOnly = false, bootstrapMode = false) => {
146
149
  // In bootstrap mode, return a minimal "zero state" with core types
147
150
  // This allows bootstrap to run immediately without inspecting the codebase
@@ -184,7 +187,10 @@ export const createSingletonServices = async (config) => {
184
187
  // inspection (setupOnly=false) is now requested — setupOnly skips
185
188
  // visitRoutes so variables/secrets/etc. are absent from that cache.
186
189
  if (!unfilteredState ||
187
- (refresh && !preloadedInspectorState) ||
190
+ (refresh &&
191
+ !preloadedInspectorState &&
192
+ (inspectorInvalidated ||
193
+ getTsWriteGeneration() !== inspectedTsGeneration)) ||
188
194
  (unfilteredStateIsSetupOnly && !setupOnly && !preloadedInspectorState)) {
189
195
  // Run inspector WITHOUT filters to get full state
190
196
  const wiringFiles = (await Promise.all(srcDirectories.map((dir) => glob(`${path.join(rootDir, dir)}/**/*.ts`, {
@@ -223,6 +229,7 @@ export const createSingletonServices = async (config) => {
223
229
  const oldProgram = unfilteredState?.program ?? undefined;
224
230
  const inspectStart = Date.now();
225
231
  unfilteredStateIsSetupOnly = setupOnly;
232
+ const tsGenerationAtInspect = getTsWriteGeneration();
226
233
  unfilteredState = await inspect(logger, wiringFiles, {
227
234
  setupOnly,
228
235
  rootDir,
@@ -256,6 +263,8 @@ export const createSingletonServices = async (config) => {
256
263
  manifest,
257
264
  });
258
265
  logger.debug(`Inspector took ${Date.now() - inspectStart}ms`);
266
+ inspectedTsGeneration = tsGenerationAtInspect;
267
+ inspectorInvalidated = false;
259
268
  if ('diagnostics' in unfilteredState &&
260
269
  unfilteredState.diagnostics.length > 0) {
261
270
  processDiagnostics(unfilteredState.diagnostics, config.lint);
@@ -277,6 +286,9 @@ export const createSingletonServices = async (config) => {
277
286
  const filteredState = filterInspectorState(unfilteredState, filters, logger);
278
287
  return filteredState;
279
288
  };
289
+ const invalidateInspectorState = () => {
290
+ inspectorInvalidated = true;
291
+ };
280
292
  const workflowService = new InMemoryWorkflowService();
281
293
  // Resolve the runtime ONCE here, then inject runtime-specific implementations.
282
294
  // Keeping the check in this single place avoids `typeof Bun` branches leaking
@@ -289,6 +301,7 @@ export const createSingletonServices = async (config) => {
289
301
  secrets: new LocalSecretService(variables),
290
302
  audit: new NoopAuditService(),
291
303
  getInspectorState,
304
+ invalidateInspectorState,
292
305
  workflowService,
293
306
  bundler: isBun ? new BunBundler() : new NodeBundler(),
294
307
  devServerRunner: isBun ? new BunServerRunner() : new NodeServerRunner(),
@@ -1,5 +1,6 @@
1
1
  import type { CLILogger } from '../services/cli-logger.service.js';
2
2
  export declare const DO_NOT_MODIFY_COMMENT: string;
3
+ export declare const getTsWriteGeneration: () => number;
3
4
  export declare const writeFileInDir: (logger: CLILogger, path: string, content: string, { ignoreModifyComment, logWrite, }?: {
4
5
  ignoreModifyComment?: boolean;
5
6
  logWrite?: boolean;
@@ -6,6 +6,9 @@ export const DO_NOT_MODIFY_COMMENT = `/**
6
6
  * This file was generated by @pikku/cli@${getCLIVersion()}
7
7
  */
8
8
  `;
9
+ let tsWriteGeneration = 0;
10
+ const TS_FILE_REGEX = /\.[mc]?tsx?$/;
11
+ export const getTsWriteGeneration = () => tsWriteGeneration;
9
12
  export const writeFileInDir = async (logger, path, content, { ignoreModifyComment = false, logWrite = true, } = {}) => {
10
13
  if (path.includes('.json')) {
11
14
  ignoreModifyComment = true;
@@ -34,6 +37,9 @@ export const writeFileInDir = async (logger, path, content, { ignoreModifyCommen
34
37
  if (existingContent !== content) {
35
38
  await mkdir(dirname(path), { recursive: true });
36
39
  await writeFile(path, content, 'utf-8');
40
+ if (TS_FILE_REGEX.test(path)) {
41
+ tsWriteGeneration++;
42
+ }
37
43
  if (logWrite) {
38
44
  logger.debug({ message: `✓ File written to ${path}`, type: 'success' });
39
45
  }
@@ -56,6 +62,9 @@ export const removeFileInDir = async (logger, path, { logRemove = true } = {}) =
56
62
  // Check if file exists before attempting removal
57
63
  if (existsSync(path)) {
58
64
  await rm(path, { force: true });
65
+ if (TS_FILE_REGEX.test(path)) {
66
+ tsWriteGeneration++;
67
+ }
59
68
  if (logRemove) {
60
69
  logger.debug({ message: `✓ File removed at ${path}`, type: 'success' });
61
70
  }
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Structural diff of the generated `.pikku` meta between two points in time —
3
+ * used by `pikku all --diff` to report what a codegen run added/removed/changed
4
+ * (functions, wirings, workflows, emails, …). The snapshot is a plain in-memory
5
+ * copy of the meta files, so diffing is a couple of small JSON reads, not a
6
+ * second inspection pass. Only user-visible buildable surfaces are included;
7
+ * plumbing (secrets/variables/middleware/permissions) is intentionally omitted.
8
+ */
9
+ export type MetaDiffCategoryName = 'functions' | 'http' | 'workflow' | 'email' | 'scheduler' | 'queue' | 'channel' | 'trigger' | 'mcp' | 'agent';
10
+ export interface MetaDiffEntry {
11
+ id: string;
12
+ status: 'added' | 'removed' | 'modified';
13
+ }
14
+ export interface MetaDiffCategory {
15
+ added: number;
16
+ removed: number;
17
+ modified: number;
18
+ entries: MetaDiffEntry[];
19
+ }
20
+ export interface MetaDiff {
21
+ totals: {
22
+ added: number;
23
+ removed: number;
24
+ modified: number;
25
+ };
26
+ categories: Partial<Record<MetaDiffCategoryName, MetaDiffCategory>>;
27
+ }
28
+ export type MetaSnapshot = Partial<Record<MetaDiffCategoryName, Record<string, unknown>>>;
29
+ /** Read the current meta from disk into an in-memory snapshot. */
30
+ export declare function readMetaSnapshot(outDir: string): MetaSnapshot;
31
+ /** Diff two snapshots; only changed ids and non-empty categories are returned. */
32
+ export declare function computeMetaDiff(before: MetaSnapshot, after: MetaSnapshot): MetaDiff;
@@ -0,0 +1,144 @@
1
+ import { existsSync, readFileSync, readdirSync } from 'fs';
2
+ import { join } from 'path';
3
+ // Single-file categories: one JSON file whose top-level keys are the ids
4
+ // (http is nested `{ method: { route: meta } }` and flattened to `method route`).
5
+ const SINGLE_FILE = {
6
+ functions: 'function/pikku-functions-meta.gen.json',
7
+ http: 'http/pikku-http-wirings-meta.gen.json',
8
+ email: 'email/pikku-emails-meta.gen.json',
9
+ scheduler: 'scheduler/pikku-schedulers-wirings-meta.gen.json',
10
+ queue: 'queue/pikku-queue-workers-wirings-meta.gen.json',
11
+ channel: 'channel/pikku-channels-meta.gen.json',
12
+ trigger: 'trigger/pikku-trigger-meta.gen.json',
13
+ mcp: 'mcp/pikku-mcp-wirings-meta.gen.json',
14
+ agent: 'agent/pikku-agent-wirings-meta.gen.json',
15
+ };
16
+ // A few meta files wrap their real entities under a single key rather than
17
+ // keying them at the top level — unwrap to that map so ids are the entities.
18
+ const UNWRAP = {
19
+ email: 'templates',
20
+ agent: 'agentsMeta',
21
+ };
22
+ // Workflows (incl. userflows/scenarios) are written one file per workflow under
23
+ // this dir; the file basename (sans `.gen.json`) is the id, `-verbose` excluded.
24
+ const WORKFLOW_META_DIR = 'workflow/meta';
25
+ function readJson(path) {
26
+ if (!existsSync(path))
27
+ return {};
28
+ try {
29
+ const parsed = JSON.parse(readFileSync(path, 'utf-8'));
30
+ if (!parsed || typeof parsed !== 'object' || Array.isArray(parsed))
31
+ return {};
32
+ return parsed;
33
+ }
34
+ catch {
35
+ return {};
36
+ }
37
+ }
38
+ function readSingle(outDir, category, relPath) {
39
+ let raw = readJson(join(outDir, relPath));
40
+ const unwrapKey = UNWRAP[category];
41
+ if (unwrapKey) {
42
+ const inner = raw[unwrapKey];
43
+ raw = inner && typeof inner === 'object' && !Array.isArray(inner) ? inner : {};
44
+ }
45
+ if (category !== 'http')
46
+ return raw;
47
+ const flat = {};
48
+ for (const [method, routes] of Object.entries(raw)) {
49
+ if (routes && typeof routes === 'object' && !Array.isArray(routes)) {
50
+ for (const [route, meta] of Object.entries(routes)) {
51
+ flat[`${method.toUpperCase()} ${route}`] = meta;
52
+ }
53
+ }
54
+ }
55
+ return flat;
56
+ }
57
+ function readWorkflows(outDir) {
58
+ const dir = join(outDir, WORKFLOW_META_DIR);
59
+ if (!existsSync(dir))
60
+ return {};
61
+ const out = {};
62
+ for (const file of readdirSync(dir)) {
63
+ if (!file.endsWith('.gen.json') || file.endsWith('-verbose.gen.json'))
64
+ continue;
65
+ out[file.slice(0, -'.gen.json'.length)] = readJson(join(dir, file));
66
+ }
67
+ return out;
68
+ }
69
+ /** Read the current meta from disk into an in-memory snapshot. */
70
+ export function readMetaSnapshot(outDir) {
71
+ if (!outDir || !existsSync(outDir))
72
+ return {};
73
+ const snap = {};
74
+ for (const [category, relPath] of Object.entries(SINGLE_FILE)) {
75
+ snap[category] = readSingle(outDir, category, relPath);
76
+ }
77
+ snap.workflow = readWorkflows(outDir);
78
+ return snap;
79
+ }
80
+ // Volatile fields that vary by absolute path / environment but aren't a
81
+ // meaningful structural change — excluded from equality (matches StateDiffService).
82
+ const NORMALIZE_IGNORE = new Set(['sourceFile']);
83
+ function normalize(value) {
84
+ if (Array.isArray(value))
85
+ return value.map(normalize);
86
+ if (value && typeof value === 'object') {
87
+ const out = {};
88
+ for (const key of Object.keys(value).sort()) {
89
+ if (NORMALIZE_IGNORE.has(key))
90
+ continue;
91
+ out[key] = normalize(value[key]);
92
+ }
93
+ return out;
94
+ }
95
+ return value;
96
+ }
97
+ function equal(a, b) {
98
+ return JSON.stringify(normalize(a)) === JSON.stringify(normalize(b));
99
+ }
100
+ /** Diff two snapshots; only changed ids and non-empty categories are returned. */
101
+ export function computeMetaDiff(before, after) {
102
+ const categories = {};
103
+ const totals = { added: 0, removed: 0, modified: 0 };
104
+ const names = new Set([
105
+ ...Object.keys(before),
106
+ ...Object.keys(after),
107
+ ]);
108
+ for (const name of names) {
109
+ const o = before[name] ?? {};
110
+ const a = after[name] ?? {};
111
+ const ids = new Set([...Object.keys(o), ...Object.keys(a)]);
112
+ const entries = [];
113
+ let added = 0;
114
+ let removed = 0;
115
+ let modified = 0;
116
+ for (const id of ids) {
117
+ const inO = id in o;
118
+ const inA = id in a;
119
+ if (inA && !inO) {
120
+ entries.push({ id, status: 'added' });
121
+ added++;
122
+ }
123
+ else if (inO && !inA) {
124
+ entries.push({ id, status: 'removed' });
125
+ removed++;
126
+ }
127
+ else if (!equal(o[id], a[id])) {
128
+ entries.push({ id, status: 'modified' });
129
+ modified++;
130
+ }
131
+ }
132
+ if (entries.length === 0)
133
+ continue;
134
+ entries.sort((x, y) => {
135
+ const order = { added: 0, modified: 1, removed: 2 };
136
+ return order[x.status] - order[y.status] || x.id.localeCompare(y.id);
137
+ });
138
+ categories[name] = { added, removed, modified, entries };
139
+ totals.added += added;
140
+ totals.removed += removed;
141
+ totals.modified += modified;
142
+ }
143
+ return { totals, categories };
144
+ }
@@ -8,8 +8,8 @@ function toValidIdentifier(name) {
8
8
  return result;
9
9
  }
10
10
  export async function saveSchemas(logger, schemaParentDir, schemas, requiredSchemas, supportsImportAttributes, packageName) {
11
- await writeFileInDir(logger, `${schemaParentDir}/register.gen.ts`, 'export const empty = null;');
12
11
  if (requiredSchemas.size === 0) {
12
+ await writeFileInDir(logger, `${schemaParentDir}/register.gen.ts`, 'export const empty = null;');
13
13
  logger.info(`• Skipping schemas since none found.\x1b[0m`);
14
14
  return;
15
15
  }
@@ -30,6 +30,9 @@ const VERBOSE_FIELDS = new Set([
30
30
  'wires',
31
31
  'sourceFile',
32
32
  'exportedName',
33
+ 'bodySourceFile',
34
+ 'bodyStart',
35
+ 'bodyEnd',
33
36
  ]);
34
37
  /**
35
38
  * Fields that are verbose only at the node level (workflow nodes)
@@ -1 +1 @@
1
- {"root":["../bin/pikku.ts","../src/cli.wiring.ts","../src/services.ts","../src/deploy/build-pipeline.ts","../src/deploy/provider-adapter.ts","../src/deploy/server-entry.ts","../src/deploy/analyzer/analyzer.ts","../src/deploy/analyzer/index.ts","../src/deploy/analyzer/manifest.ts","../src/deploy/bundler/bun-bundler.ts","../src/deploy/bundler/bundler.interface.ts","../src/deploy/bundler/bundler.ts","../src/deploy/bundler/dep-extractor.ts","../src/deploy/bundler/index.ts","../src/deploy/bundler/node-bundler.ts","../src/deploy/bundler/types.ts","../src/deploy/codegen/index.ts","../src/deploy/codegen/per-unit-codegen.ts","../src/deploy/plan/executor.ts","../src/deploy/plan/formatter.ts","../src/deploy/plan/index.ts","../src/deploy/plan/planner.ts","../src/deploy/plan/provider.ts","../src/deploy/plan/types.ts","../src/fabric/fabric-commands.ts","../src/fabric/functions/add.function.ts","../src/fabric/functions/addon-verify.function.ts","../src/fabric/functions/db-schema.function.ts","../src/fabric/functions/deploy-list.function.ts","../src/fabric/functions/deploy-units.function.ts","../src/fabric/functions/deploy.function.ts","../src/fabric/functions/domains-add.function.ts","../src/fabric/functions/domains-list.function.ts","../src/fabric/functions/domains-remove.function.ts","../src/fabric/functions/errors.function.ts","../src/fabric/functions/init.function.ts","../src/fabric/functions/link.function.ts","../src/fabric/functions/llm-key.function.ts","../src/fabric/functions/login.function.ts","../src/fabric/functions/logs.function.ts","../src/fabric/functions/metrics.function.ts","../src/fabric/functions/publish.function.ts","../src/fabric/functions/rollback.function.ts","../src/fabric/functions/secrets-list.function.ts","../src/fabric/functions/secrets-set.function.ts","../src/fabric/functions/smoke.function.ts","../src/fabric/functions/status.function.ts","../src/fabric/functions/trace.function.ts","../src/fabric/functions/validate.function.ts","../src/fabric/lib/config.ts","../src/fabric/lib/console-url.ts","../src/fabric/lib/git.ts","../src/fabric/lib/http.ts","../src/fabric/lib/not-implemented.ts","../src/fabric/lib/output.ts","../src/fabric/lib/prompt.ts","../src/fabric/lib/stage.ts","../src/fabric/sdk/http-map.gen.d.ts","../src/fabric/sdk/pikku-fetch.gen.ts","../src/fabric/sdk/pikku-rpc.gen.ts","../src/fabric/sdk/rpc-map.gen.d.ts","../src/functions/commands/all.ts","../src/functions/commands/audit.ts","../src/functions/commands/binary.ts","../src/functions/commands/bootstrap.ts","../src/functions/commands/db-audit.ts","../src/functions/commands/db-generate.ts","../src/functions/commands/db-migrate.ts","../src/functions/commands/db-reset.ts","../src/functions/commands/db-seed.ts","../src/functions/commands/db-shared.ts","../src/functions/commands/deploy-apply.ts","../src/functions/commands/deploy-info.ts","../src/functions/commands/deploy-plan.ts","../src/functions/commands/dev-ai-runner.ts","../src/functions/commands/dev.ts","../src/functions/commands/emails-init.ts","../src/functions/commands/enable.ts","../src/functions/commands/info.ts","../src/functions/commands/load-user-project.ts","../src/functions/commands/login.ts","../src/functions/commands/meta.ts","../src/functions/commands/new-addon.ts","../src/functions/commands/new-function.ts","../src/functions/commands/new-middleware.ts","../src/functions/commands/new-permission.ts","../src/functions/commands/new-wiring.ts","../src/functions/commands/pikku-command-bootstrap.ts","../src/functions/commands/pikku-command-summary.ts","../src/functions/commands/scenario.ts","../src/functions/commands/serve-console.ts","../src/functions/commands/serve.ts","../src/functions/commands/skills.ts","../src/functions/commands/tests-coverage.ts","../src/functions/commands/tests-init.ts","../src/functions/commands/versions-check.ts","../src/functions/commands/versions-init.ts","../src/functions/commands/versions-update.ts","../src/functions/commands/watch.ts","../src/functions/commands/workspace-validate.ts","../src/functions/db/annotation-parser.ts","../src/functions/db/better-auth-schema.ts","../src/functions/db/coercion-plugin.ts","../src/functions/db/db-codegen.ts","../src/functions/db/db-introspector.ts","../src/functions/db/db-migrator.ts","../src/functions/db/local-db.ts","../src/functions/db/zod-codegen.ts","../src/functions/db/postgres/pglite-kysely.ts","../src/functions/db/postgres/postgres-introspector.ts","../src/functions/db/postgres/postgres-migrator.ts","../src/functions/db/sqlite/seed.ts","../src/functions/db/sqlite/sqlite-introspector.ts","../src/functions/db/sqlite/sqlite-kysely.ts","../src/functions/db/sqlite/sqlite-migrator.ts","../src/functions/db/sqlite/sqlite-runtime-bun.ts","../src/functions/db/sqlite/sqlite-runtime-node.ts","../src/functions/db/sqlite/sqlite-runtime.ts","../src/functions/runtimes/fetch/index.ts","../src/functions/runtimes/nextjs/pikku-command-nextjs.ts","../src/functions/runtimes/nextjs/serialize-nextjs-backend-worker-rpc-wrapper.ts","../src/functions/runtimes/nextjs/serialize-nextjs-backend-wrapper.ts","../src/functions/runtimes/nextjs/serialize-nextjs-http-wrapper.ts","../src/functions/runtimes/tanstack-start/pikku-command-tanstack-start.ts","../src/functions/runtimes/tanstack-start/serialize-tanstack-start-shim.ts","../src/functions/runtimes/websocket/pikku-command-websocket-typed.ts","../src/functions/runtimes/websocket/serialize-websocket-wrapper.ts","../src/functions/validate/workspace-validate.ts","../src/functions/wirings/ai-agent/pikku-command-ai-agent-types.ts","../src/functions/wirings/ai-agent/pikku-command-ai-agent.ts","../src/functions/wirings/ai-agent/pikku-command-public-agent.ts","../src/functions/wirings/ai-agent/serialize-agent-map.ts","../src/functions/wirings/ai-agent/serialize-ai-agent-types.ts","../src/functions/wirings/ai-agent/serialize-public-agent.ts","../src/functions/wirings/auth/pikku-command-auth.ts","../src/functions/wirings/auth/serialize-auth-gen.ts","../src/functions/wirings/auth/serialize-auth-meta.ts","../src/functions/wirings/auth/serialize-auth-types.ts","../src/functions/wirings/channels/pikku-channels.ts","../src/functions/wirings/channels/pikku-command-channel-types.ts","../src/functions/wirings/channels/pikku-command-channels-map.ts","../src/functions/wirings/channels/pikku-command-channels.ts","../src/functions/wirings/channels/serialize-channel-types.ts","../src/functions/wirings/channels/serialize-typed-channel-map.ts","../src/functions/wirings/cli/pikku-command-cli-entry.ts","../src/functions/wirings/cli/pikku-command-cli-types.ts","../src/functions/wirings/cli/pikku-command-cli.ts","../src/functions/wirings/cli/serialize-channel-cli-client.ts","../src/functions/wirings/cli/serialize-channel-cli.ts","../src/functions/wirings/cli/serialize-cli-types.ts","../src/functions/wirings/cli/serialize-local-cli-bootstrap.ts","../src/functions/wirings/console/pikku-command-console-functions.ts","../src/functions/wirings/console/pikku-command-node-types.ts","../src/functions/wirings/console/pikku-command-nodes-meta.ts","../src/functions/wirings/console/serialize-console-functions.ts","../src/functions/wirings/console/serialize-node-types.ts","../src/functions/wirings/credentials/pikku-command-credentials.ts","../src/functions/wirings/credentials/serialize-credentials-types.ts","../src/functions/wirings/emails/pikku-command-emails.ts","../src/functions/wirings/emails/serialize-emails.ts","../src/functions/wirings/functions/pikku-command-addon-types.ts","../src/functions/wirings/functions/pikku-command-function-types-split.ts","../src/functions/wirings/functions/pikku-command-function-types.ts","../src/functions/wirings/functions/pikku-command-functions.ts","../src/functions/wirings/functions/pikku-command-services.ts","../src/functions/wirings/functions/schemas.ts","../src/functions/wirings/functions/serialize-addon-refs.ts","../src/functions/wirings/functions/serialize-addon-types.ts","../src/functions/wirings/functions/serialize-function-imports.ts","../src/functions/wirings/functions/serialize-function-types.ts","../src/functions/wirings/functions/serialize-pikku-types-hub.ts","../src/functions/wirings/gateway/pikku-command-gateway.ts","../src/functions/wirings/gateway/serialize-gateway-meta.ts","../src/functions/wirings/http/pikku-command-http-map.ts","../src/functions/wirings/http/pikku-command-http-routes.ts","../src/functions/wirings/http/pikku-command-http-types.ts","../src/functions/wirings/http/pikku-command-openapi.ts","../src/functions/wirings/http/pikku-http-routes.ts","../src/functions/wirings/http/serialize-fetch-wrapper.ts","../src/functions/wirings/http/serialize-http-types.ts","../src/functions/wirings/http/serialize-typed-http-map.ts","../src/functions/wirings/mcp/pikku-command-mcp-json.ts","../src/functions/wirings/mcp/pikku-command-mcp-types.ts","../src/functions/wirings/mcp/pikku-command-mcp.ts","../src/functions/wirings/mcp/serialize-mcp-types.ts","../src/functions/wirings/middleware/pikku-command-middleware.ts","../src/functions/wirings/middleware/serialize-middleware-imports.ts","../src/functions/wirings/package/pikku-command-package-types.ts","../src/functions/wirings/package/pikku-command-package.ts","../src/functions/wirings/package/serialize-package-types.ts","../src/functions/wirings/package/serialize-package.ts","../src/functions/wirings/permissions/pikku-command-permissions.ts","../src/functions/wirings/permissions/serialize-permissions-imports.ts","../src/functions/wirings/queue/pikku-command-queue-map.ts","../src/functions/wirings/queue/pikku-command-queue-service.ts","../src/functions/wirings/queue/pikku-command-queue-types.ts","../src/functions/wirings/queue/pikku-command-queue.ts","../src/functions/wirings/queue/pikku-queue-map.ts","../src/functions/wirings/queue/pikku-queue.ts","../src/functions/wirings/queue/serialize-queue-map.ts","../src/functions/wirings/queue/serialize-queue-meta.ts","../src/functions/wirings/queue/serialize-queue-types.ts","../src/functions/wirings/queue/serialize-queue-wrapper.ts","../src/functions/wirings/realtime/pikku-command-events-scaffold.ts","../src/functions/wirings/realtime/pikku-command-realtime.ts","../src/functions/wirings/realtime/serialize-events-scaffold.ts","../src/functions/wirings/realtime/serialize-realtime-client.ts","../src/functions/wirings/rpc/pikku-command-public-rpc.ts","../src/functions/wirings/rpc/pikku-command-react-query.ts","../src/functions/wirings/rpc/pikku-command-remote-rpc.ts","../src/functions/wirings/rpc/pikku-command-rpc-client.ts","../src/functions/wirings/rpc/pikku-command-rpc-map.ts","../src/functions/wirings/rpc/pikku-command-rpc.ts","../src/functions/wirings/rpc/serialize-public-rpc.ts","../src/functions/wirings/rpc/serialize-react-query-hooks.ts","../src/functions/wirings/rpc/serialize-remote-rpc.ts","../src/functions/wirings/rpc/serialize-rpc-wrapper.ts","../src/functions/wirings/rpc/serialize-typed-rpc-map.ts","../src/functions/wirings/scheduler/pikku-command-scheduler-types.ts","../src/functions/wirings/scheduler/pikku-command-scheduler.ts","../src/functions/wirings/scheduler/serialize-scheduler-meta.ts","../src/functions/wirings/scheduler/serialize-scheduler-types.ts","../src/functions/wirings/secrets/pikku-command-secrets.ts","../src/functions/wirings/secrets/serialize-secrets-types.ts","../src/functions/wirings/triggers/pikku-command-trigger-types.ts","../src/functions/wirings/triggers/pikku-command-trigger.ts","../src/functions/wirings/triggers/serialize-trigger-meta.ts","../src/functions/wirings/triggers/serialize-trigger-types.ts","../src/functions/wirings/variables/pikku-command-variables.ts","../src/functions/wirings/variables/serialize-variables-types.ts","../src/functions/wirings/workflow/pikku-command-workflow-routes.ts","../src/functions/wirings/workflow/pikku-command-workflow.ts","../src/functions/wirings/workflow/serialize-scenario-actors.ts","../src/functions/wirings/workflow/serialize-workflow-bootstrap-map.ts","../src/functions/wirings/workflow/serialize-workflow-map.ts","../src/functions/wirings/workflow/serialize-workflow-meta.ts","../src/functions/wirings/workflow/serialize-workflow-registration.ts","../src/functions/wirings/workflow/serialize-workflow-routes.ts","../src/functions/wirings/workflow/serialize-workflow-types.ts","../src/functions/workflows/all.workflow.ts","../src/middleware/log-command-info-and-time.ts","../src/scaffold/rpc-remote.gen.ts","../src/server/bun-server-runner.ts","../src/server/dev-server-runner.interface.ts","../src/server/node-server-runner.ts","../src/services/cli-logger-forwarder.service.ts","../src/services/cli-logger.service.ts","../src/utils/assert-single-core-version.ts","../src/utils/check-required-types.ts","../src/utils/cli-session.ts","../src/utils/command-summary.ts","../src/utils/contract-versions.ts","../src/utils/detect-better-auth.ts","../src/utils/device-auth.ts","../src/utils/file-import-path.ts","../src/utils/file-imports-serializer.ts","../src/utils/file-writer.ts","../src/utils/generate-bootstrap-file.ts","../src/utils/get-cli-version.ts","../src/utils/parse-cli-filters.ts","../src/utils/pikku-cli-config.ts","../src/utils/pikku-files-and-methods.ts","../src/utils/serialize-import-map.ts","../src/utils/serialize-meta-ts.ts","../src/utils/serialize-schemas.ts","../src/utils/strip-verbose-meta.ts","../src/utils/tsc-check.ts","../.pikku/pikku-bootstrap.gen.ts","../.pikku/pikku-meta-service.gen.ts","../.pikku/pikku-services.gen.ts","../.pikku/pikku-types.gen.ts","../.pikku/agent/pikku-agent-map.gen.d.ts","../.pikku/agent/pikku-agent-types.gen.ts","../.pikku/channel/pikku-channel-types.gen.ts","../.pikku/cli/pikku-cli-channel.ts","../.pikku/cli/pikku-cli-client.gen.ts","../.pikku/cli/pikku-cli-contracts-meta.gen.ts","../.pikku/cli/pikku-cli-types.gen.ts","../.pikku/cli/pikku-cli-wirings-meta.gen.ts","../.pikku/cli/pikku-cli-wirings.gen.ts","../.pikku/cli/pikku-cli.gen.ts","../.pikku/console/pikku-node-types.gen.ts","../.pikku/function/pikku-function-types.gen.ts","../.pikku/function/pikku-functions-meta.gen.ts","../.pikku/function/pikku-functions.gen.ts","../.pikku/http/pikku-http-types.gen.ts","../.pikku/http/pikku-http-wirings-map.gen.d.ts","../.pikku/http/pikku-http-wirings-meta.gen.ts","../.pikku/http/pikku-http-wirings.gen.ts","../.pikku/mcp/pikku-mcp-types.gen.ts","../.pikku/node/pikku-node-types.gen.ts","../.pikku/queue/pikku-queue-types.gen.ts","../.pikku/queue/pikku-queue-workers-wirings-map.gen.d.ts","../.pikku/queue/pikku-queue-workers-wirings-meta.gen.ts","../.pikku/queue/pikku-queue-workers-wirings.gen.ts","../.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts","../.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts","../.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts","../.pikku/scheduler/pikku-scheduler-types.gen.ts","../.pikku/schemas/register.gen.ts","../.pikku/secrets/pikku-secret-types.gen.ts","../.pikku/secrets/pikku-secrets.gen.ts","../.pikku/trigger/pikku-trigger-types.gen.ts","../.pikku/variables/pikku-variable-types.gen.ts","../.pikku/variables/pikku-variables.gen.ts","../.pikku/workflow/pikku-workflow-map.gen.d.ts","../.pikku/workflow/pikku-workflow-types.gen.ts","../.pikku/workflow/pikku-workflow-wirings-meta.gen.ts","../.pikku/workflow/pikku-workflow-wirings.gen.ts","../types/application-types.d.ts","../types/bun-sqlite.d.ts","../types/config.d.ts"],"version":"6.0.3"}
1
+ {"root":["../bin/pikku.ts","../src/cli.wiring.ts","../src/services.ts","../src/deploy/build-pipeline.ts","../src/deploy/provider-adapter.ts","../src/deploy/server-entry.ts","../src/deploy/analyzer/analyzer.ts","../src/deploy/analyzer/index.ts","../src/deploy/analyzer/manifest.ts","../src/deploy/bundler/bun-bundler.ts","../src/deploy/bundler/bundler.interface.ts","../src/deploy/bundler/bundler.ts","../src/deploy/bundler/dep-extractor.ts","../src/deploy/bundler/index.ts","../src/deploy/bundler/node-bundler.ts","../src/deploy/bundler/types.ts","../src/deploy/codegen/index.ts","../src/deploy/codegen/per-unit-codegen.ts","../src/deploy/plan/executor.ts","../src/deploy/plan/formatter.ts","../src/deploy/plan/index.ts","../src/deploy/plan/planner.ts","../src/deploy/plan/provider.ts","../src/deploy/plan/types.ts","../src/fabric/fabric-commands.ts","../src/fabric/functions/add.function.ts","../src/fabric/functions/addon-verify.function.ts","../src/fabric/functions/db-schema.function.ts","../src/fabric/functions/deploy-list.function.ts","../src/fabric/functions/deploy-units.function.ts","../src/fabric/functions/deploy.function.ts","../src/fabric/functions/domains-add.function.ts","../src/fabric/functions/domains-list.function.ts","../src/fabric/functions/domains-remove.function.ts","../src/fabric/functions/errors.function.ts","../src/fabric/functions/init.function.ts","../src/fabric/functions/link.function.ts","../src/fabric/functions/llm-key.function.ts","../src/fabric/functions/login.function.ts","../src/fabric/functions/logs.function.ts","../src/fabric/functions/metrics.function.ts","../src/fabric/functions/publish.function.ts","../src/fabric/functions/rollback.function.ts","../src/fabric/functions/secrets-list.function.ts","../src/fabric/functions/secrets-set.function.ts","../src/fabric/functions/smoke.function.ts","../src/fabric/functions/status.function.ts","../src/fabric/functions/trace.function.ts","../src/fabric/functions/validate.function.ts","../src/fabric/lib/config.ts","../src/fabric/lib/console-url.ts","../src/fabric/lib/git.ts","../src/fabric/lib/http.ts","../src/fabric/lib/not-implemented.ts","../src/fabric/lib/output.ts","../src/fabric/lib/prompt.ts","../src/fabric/lib/stage.ts","../src/fabric/sdk/http-map.gen.d.ts","../src/fabric/sdk/pikku-fetch.gen.ts","../src/fabric/sdk/pikku-rpc.gen.ts","../src/fabric/sdk/rpc-map.gen.d.ts","../src/functions/commands/all.ts","../src/functions/commands/audit.ts","../src/functions/commands/binary.ts","../src/functions/commands/bootstrap.ts","../src/functions/commands/bun-coverage-loader.ts","../src/functions/commands/db-audit.ts","../src/functions/commands/db-generate.ts","../src/functions/commands/db-migrate.ts","../src/functions/commands/db-reset.ts","../src/functions/commands/db-seed.ts","../src/functions/commands/db-shared.ts","../src/functions/commands/deploy-apply.ts","../src/functions/commands/deploy-info.ts","../src/functions/commands/deploy-plan.ts","../src/functions/commands/dev-ai-runner.ts","../src/functions/commands/dev.ts","../src/functions/commands/emails-init.ts","../src/functions/commands/enable.ts","../src/functions/commands/info.ts","../src/functions/commands/load-user-project.ts","../src/functions/commands/login.ts","../src/functions/commands/meta.ts","../src/functions/commands/new-addon.ts","../src/functions/commands/new-function.ts","../src/functions/commands/new-middleware.ts","../src/functions/commands/new-permission.ts","../src/functions/commands/new-wiring.ts","../src/functions/commands/pikku-command-bootstrap.ts","../src/functions/commands/pikku-command-summary.ts","../src/functions/commands/scenario.ts","../src/functions/commands/serve-console.ts","../src/functions/commands/serve.ts","../src/functions/commands/skills.ts","../src/functions/commands/start-coverage.ts","../src/functions/commands/tests-coverage.ts","../src/functions/commands/tests-init.ts","../src/functions/commands/versions-check.ts","../src/functions/commands/versions-init.ts","../src/functions/commands/versions-update.ts","../src/functions/commands/watch.ts","../src/functions/commands/workspace-validate.ts","../src/functions/db/annotation-parser.ts","../src/functions/db/better-auth-schema.ts","../src/functions/db/coercion-plugin.ts","../src/functions/db/db-codegen.ts","../src/functions/db/db-introspector.ts","../src/functions/db/db-migrator.ts","../src/functions/db/local-db.ts","../src/functions/db/zod-codegen.ts","../src/functions/db/postgres/pglite-kysely.ts","../src/functions/db/postgres/postgres-introspector.ts","../src/functions/db/postgres/postgres-migrator.ts","../src/functions/db/sqlite/seed.ts","../src/functions/db/sqlite/sqlite-introspector.ts","../src/functions/db/sqlite/sqlite-kysely.ts","../src/functions/db/sqlite/sqlite-migrator.ts","../src/functions/db/sqlite/sqlite-runtime-bun.ts","../src/functions/db/sqlite/sqlite-runtime-node.ts","../src/functions/db/sqlite/sqlite-runtime.ts","../src/functions/runtimes/fetch/index.ts","../src/functions/runtimes/nextjs/pikku-command-nextjs.ts","../src/functions/runtimes/nextjs/serialize-nextjs-backend-worker-rpc-wrapper.ts","../src/functions/runtimes/nextjs/serialize-nextjs-backend-wrapper.ts","../src/functions/runtimes/nextjs/serialize-nextjs-http-wrapper.ts","../src/functions/runtimes/tanstack-start/pikku-command-tanstack-start.ts","../src/functions/runtimes/tanstack-start/serialize-tanstack-start-shim.ts","../src/functions/runtimes/websocket/pikku-command-websocket-typed.ts","../src/functions/runtimes/websocket/serialize-websocket-wrapper.ts","../src/functions/validate/workspace-validate.ts","../src/functions/wirings/ai-agent/pikku-command-ai-agent-types.ts","../src/functions/wirings/ai-agent/pikku-command-ai-agent.ts","../src/functions/wirings/ai-agent/pikku-command-public-agent.ts","../src/functions/wirings/ai-agent/serialize-agent-map.ts","../src/functions/wirings/ai-agent/serialize-ai-agent-types.ts","../src/functions/wirings/ai-agent/serialize-public-agent.ts","../src/functions/wirings/auth/pikku-command-auth.ts","../src/functions/wirings/auth/serialize-auth-gen.ts","../src/functions/wirings/auth/serialize-auth-meta.ts","../src/functions/wirings/auth/serialize-auth-types.ts","../src/functions/wirings/channels/pikku-channels.ts","../src/functions/wirings/channels/pikku-command-channel-types.ts","../src/functions/wirings/channels/pikku-command-channels-map.ts","../src/functions/wirings/channels/pikku-command-channels.ts","../src/functions/wirings/channels/serialize-channel-types.ts","../src/functions/wirings/channels/serialize-typed-channel-map.ts","../src/functions/wirings/cli/pikku-command-cli-entry.ts","../src/functions/wirings/cli/pikku-command-cli-types.ts","../src/functions/wirings/cli/pikku-command-cli.ts","../src/functions/wirings/cli/serialize-channel-cli-client.ts","../src/functions/wirings/cli/serialize-channel-cli.ts","../src/functions/wirings/cli/serialize-cli-types.ts","../src/functions/wirings/cli/serialize-local-cli-bootstrap.ts","../src/functions/wirings/console/pikku-command-console-functions.ts","../src/functions/wirings/console/pikku-command-node-types.ts","../src/functions/wirings/console/pikku-command-nodes-meta.ts","../src/functions/wirings/console/serialize-console-functions.ts","../src/functions/wirings/console/serialize-node-types.ts","../src/functions/wirings/credentials/pikku-command-credentials.ts","../src/functions/wirings/credentials/serialize-credentials-types.ts","../src/functions/wirings/emails/pikku-command-emails.ts","../src/functions/wirings/emails/serialize-emails.ts","../src/functions/wirings/functions/pikku-command-addon-types.ts","../src/functions/wirings/functions/pikku-command-function-types-split.ts","../src/functions/wirings/functions/pikku-command-function-types.ts","../src/functions/wirings/functions/pikku-command-functions.ts","../src/functions/wirings/functions/pikku-command-services.ts","../src/functions/wirings/functions/schemas.ts","../src/functions/wirings/functions/serialize-addon-refs.ts","../src/functions/wirings/functions/serialize-addon-types.ts","../src/functions/wirings/functions/serialize-function-imports.ts","../src/functions/wirings/functions/serialize-function-types.ts","../src/functions/wirings/functions/serialize-pikku-types-hub.ts","../src/functions/wirings/gateway/pikku-command-gateway.ts","../src/functions/wirings/gateway/serialize-gateway-meta.ts","../src/functions/wirings/http/pikku-command-http-map.ts","../src/functions/wirings/http/pikku-command-http-routes.ts","../src/functions/wirings/http/pikku-command-http-types.ts","../src/functions/wirings/http/pikku-command-openapi.ts","../src/functions/wirings/http/pikku-http-routes.ts","../src/functions/wirings/http/serialize-fetch-wrapper.ts","../src/functions/wirings/http/serialize-http-types.ts","../src/functions/wirings/http/serialize-typed-http-map.ts","../src/functions/wirings/mcp/pikku-command-mcp-json.ts","../src/functions/wirings/mcp/pikku-command-mcp-types.ts","../src/functions/wirings/mcp/pikku-command-mcp.ts","../src/functions/wirings/mcp/serialize-mcp-types.ts","../src/functions/wirings/middleware/pikku-command-middleware.ts","../src/functions/wirings/middleware/serialize-middleware-imports.ts","../src/functions/wirings/package/pikku-command-package-types.ts","../src/functions/wirings/package/pikku-command-package.ts","../src/functions/wirings/package/serialize-package-types.ts","../src/functions/wirings/package/serialize-package.ts","../src/functions/wirings/permissions/pikku-command-permissions.ts","../src/functions/wirings/permissions/serialize-permissions-imports.ts","../src/functions/wirings/queue/pikku-command-queue-map.ts","../src/functions/wirings/queue/pikku-command-queue-service.ts","../src/functions/wirings/queue/pikku-command-queue-types.ts","../src/functions/wirings/queue/pikku-command-queue.ts","../src/functions/wirings/queue/pikku-queue-map.ts","../src/functions/wirings/queue/pikku-queue.ts","../src/functions/wirings/queue/serialize-queue-map.ts","../src/functions/wirings/queue/serialize-queue-meta.ts","../src/functions/wirings/queue/serialize-queue-types.ts","../src/functions/wirings/queue/serialize-queue-wrapper.ts","../src/functions/wirings/realtime/pikku-command-events-scaffold.ts","../src/functions/wirings/realtime/pikku-command-realtime.ts","../src/functions/wirings/realtime/serialize-events-scaffold.ts","../src/functions/wirings/realtime/serialize-realtime-client.ts","../src/functions/wirings/rpc/pikku-command-public-rpc.ts","../src/functions/wirings/rpc/pikku-command-react-query.ts","../src/functions/wirings/rpc/pikku-command-remote-rpc.ts","../src/functions/wirings/rpc/pikku-command-rpc-client.ts","../src/functions/wirings/rpc/pikku-command-rpc-map.ts","../src/functions/wirings/rpc/pikku-command-rpc.ts","../src/functions/wirings/rpc/serialize-public-rpc.ts","../src/functions/wirings/rpc/serialize-react-query-hooks.ts","../src/functions/wirings/rpc/serialize-remote-rpc.ts","../src/functions/wirings/rpc/serialize-rpc-wrapper.ts","../src/functions/wirings/rpc/serialize-typed-rpc-map.ts","../src/functions/wirings/scheduler/pikku-command-scheduler-types.ts","../src/functions/wirings/scheduler/pikku-command-scheduler.ts","../src/functions/wirings/scheduler/serialize-scheduler-meta.ts","../src/functions/wirings/scheduler/serialize-scheduler-types.ts","../src/functions/wirings/secrets/pikku-command-secrets.ts","../src/functions/wirings/secrets/serialize-secrets-types.ts","../src/functions/wirings/triggers/pikku-command-trigger-types.ts","../src/functions/wirings/triggers/pikku-command-trigger.ts","../src/functions/wirings/triggers/serialize-trigger-meta.ts","../src/functions/wirings/triggers/serialize-trigger-types.ts","../src/functions/wirings/variables/pikku-command-variables.ts","../src/functions/wirings/variables/serialize-variables-types.ts","../src/functions/wirings/workflow/pikku-command-workflow-routes.ts","../src/functions/wirings/workflow/pikku-command-workflow.ts","../src/functions/wirings/workflow/serialize-scenario-actors.ts","../src/functions/wirings/workflow/serialize-workflow-bootstrap-map.ts","../src/functions/wirings/workflow/serialize-workflow-map.ts","../src/functions/wirings/workflow/serialize-workflow-meta.ts","../src/functions/wirings/workflow/serialize-workflow-registration.ts","../src/functions/wirings/workflow/serialize-workflow-routes.ts","../src/functions/wirings/workflow/serialize-workflow-types.ts","../src/functions/workflows/all.workflow.ts","../src/middleware/log-command-info-and-time.ts","../src/scaffold/rpc-remote.gen.ts","../src/server/bun-server-runner.ts","../src/server/dev-server-runner.interface.ts","../src/server/node-server-runner.ts","../src/services/cli-logger-forwarder.service.ts","../src/services/cli-logger.service.ts","../src/utils/assert-single-core-version.ts","../src/utils/check-required-types.ts","../src/utils/cli-session.ts","../src/utils/command-summary.ts","../src/utils/contract-versions.ts","../src/utils/detect-better-auth.ts","../src/utils/device-auth.ts","../src/utils/file-import-path.ts","../src/utils/file-imports-serializer.ts","../src/utils/file-writer.ts","../src/utils/generate-bootstrap-file.ts","../src/utils/get-cli-version.ts","../src/utils/meta-diff.ts","../src/utils/parse-cli-filters.ts","../src/utils/pikku-cli-config.ts","../src/utils/pikku-files-and-methods.ts","../src/utils/serialize-import-map.ts","../src/utils/serialize-meta-ts.ts","../src/utils/serialize-schemas.ts","../src/utils/strip-verbose-meta.ts","../src/utils/tsc-check.ts","../.pikku/pikku-bootstrap.gen.ts","../.pikku/pikku-meta-service.gen.ts","../.pikku/pikku-services.gen.ts","../.pikku/pikku-types.gen.ts","../.pikku/agent/pikku-agent-map.gen.d.ts","../.pikku/agent/pikku-agent-types.gen.ts","../.pikku/channel/pikku-channel-types.gen.ts","../.pikku/cli/pikku-cli-channel.ts","../.pikku/cli/pikku-cli-client.gen.ts","../.pikku/cli/pikku-cli-contracts-meta.gen.ts","../.pikku/cli/pikku-cli-types.gen.ts","../.pikku/cli/pikku-cli-wirings-meta.gen.ts","../.pikku/cli/pikku-cli-wirings.gen.ts","../.pikku/cli/pikku-cli.gen.ts","../.pikku/console/pikku-node-types.gen.ts","../.pikku/function/pikku-function-types.gen.ts","../.pikku/function/pikku-functions-meta.gen.ts","../.pikku/function/pikku-functions.gen.ts","../.pikku/http/pikku-http-types.gen.ts","../.pikku/http/pikku-http-wirings-map.gen.d.ts","../.pikku/http/pikku-http-wirings-meta.gen.ts","../.pikku/http/pikku-http-wirings.gen.ts","../.pikku/mcp/pikku-mcp-types.gen.ts","../.pikku/node/pikku-node-types.gen.ts","../.pikku/queue/pikku-queue-types.gen.ts","../.pikku/queue/pikku-queue-workers-wirings-map.gen.d.ts","../.pikku/queue/pikku-queue-workers-wirings-meta.gen.ts","../.pikku/queue/pikku-queue-workers-wirings.gen.ts","../.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts","../.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts","../.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts","../.pikku/scheduler/pikku-scheduler-types.gen.ts","../.pikku/schemas/register.gen.ts","../.pikku/secrets/pikku-secret-types.gen.ts","../.pikku/secrets/pikku-secrets.gen.ts","../.pikku/trigger/pikku-trigger-types.gen.ts","../.pikku/variables/pikku-variable-types.gen.ts","../.pikku/variables/pikku-variables.gen.ts","../.pikku/workflow/pikku-workflow-map.gen.d.ts","../.pikku/workflow/pikku-workflow-types.gen.ts","../.pikku/workflow/pikku-workflow-wirings-meta.gen.ts","../.pikku/workflow/pikku-workflow-wirings.gen.ts","../types/application-types.d.ts","../types/bun-sqlite.d.ts","../types/config.d.ts"],"version":"6.0.3"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pikku/cli",
3
- "version": "0.12.69",
3
+ "version": "0.12.70",
4
4
  "author": "yasser.fadl@gmail.com",
5
5
  "license": "BUSL-1.1",
6
6
  "imports": {
@@ -29,10 +29,10 @@
29
29
  "@openapi-contrib/json-schema-to-openapi-schema": "^4.3.1",
30
30
  "@pikku/better-auth": "^0.12.15",
31
31
  "@pikku/bun-server": "^0.12.4",
32
- "@pikku/core": "^0.12.52",
32
+ "@pikku/core": "^0.12.53",
33
33
  "@pikku/deploy-cloudflare": "^0.12.8",
34
34
  "@pikku/fetch": "^0.12.6",
35
- "@pikku/inspector": "^0.12.36",
35
+ "@pikku/inspector": "^0.12.37",
36
36
  "@pikku/kysely": "^0.13.0",
37
37
  "@pikku/kysely-node-sqlite": "^0.12.3",
38
38
  "@pikku/node-http-server": "^0.12.5",
@@ -44,6 +44,7 @@
44
44
  "chalk": "^5.6.2",
45
45
  "chokidar": "^4.0.3",
46
46
  "esbuild": "~0.27.0",
47
+ "istanbul-lib-instrument": "^6.0.3",
47
48
  "open": "^10.2.0",
48
49
  "openapi-types": "^12.1.3",
49
50
  "path-to-regexp": "^8.3.0",
@@ -58,6 +59,7 @@
58
59
  "zod-to-ts": "^2.1.0"
59
60
  },
60
61
  "devDependencies": {
62
+ "@types/istanbul-lib-instrument": "^1.7.7",
61
63
  "@types/node": "^24.11.0",
62
64
  "@types/pg": "^8.11.0",
63
65
  "@types/ws": "^8"