@pikku/cli 0.12.33 → 0.12.35
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/console-app/assets/index-BOM3RFeu.js +233 -0
- package/console-app/index.html +1 -1
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +1 -1
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +1 -1
- package/dist/.pikku/channel/pikku-channel-types.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-channel.js +1 -1
- package/dist/.pikku/cli/pikku-cli-types.gen.d.ts +1 -1
- package/dist/.pikku/cli/pikku-cli-types.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-wirings-meta.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-wirings.gen.d.ts +1 -1
- package/dist/.pikku/cli/pikku-cli-wirings.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli.gen.d.ts +1 -1
- package/dist/.pikku/cli/pikku-cli.gen.js +1 -1
- package/dist/.pikku/console/pikku-node-types.gen.d.ts +1 -1
- package/dist/.pikku/function/pikku-function-types.gen.d.ts +1 -1
- package/dist/.pikku/function/pikku-function-types.gen.js +1 -1
- package/dist/.pikku/function/pikku-functions-meta.gen.js +1 -1
- package/dist/.pikku/function/pikku-functions-meta.gen.json +24 -24
- package/dist/.pikku/function/pikku-functions.gen.js +1 -1
- package/dist/.pikku/http/pikku-http-types.gen.d.ts +1 -1
- package/dist/.pikku/http/pikku-http-types.gen.js +1 -1
- package/dist/.pikku/http/pikku-http-wirings-meta.gen.js +1 -1
- package/dist/.pikku/http/pikku-http-wirings.gen.d.ts +1 -1
- package/dist/.pikku/http/pikku-http-wirings.gen.js +1 -1
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +1 -1
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js +1 -1
- package/dist/.pikku/pikku-bootstrap.gen.d.ts +1 -1
- package/dist/.pikku/pikku-bootstrap.gen.js +1 -1
- package/dist/.pikku/pikku-meta-service.gen.d.ts +1 -1
- package/dist/.pikku/pikku-meta-service.gen.js +1 -1
- package/dist/.pikku/pikku-services.gen.d.ts +1 -1
- package/dist/.pikku/pikku-types.gen.d.ts +1 -1
- package/dist/.pikku/pikku-types.gen.js +1 -1
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +1 -1
- package/dist/.pikku/queue/pikku-queue-types.gen.js +1 -1
- package/dist/.pikku/queue/pikku-queue-workers-wirings-meta.gen.js +1 -1
- package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.d.ts +1 -1
- package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.js +1 -1
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +1 -1
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +2 -2
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +1 -1
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +1 -1
- package/dist/.pikku/schemas/register.gen.js +3 -3
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +1 -1
- package/dist/.pikku/secrets/pikku-secret-types.gen.js +1 -1
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +1 -1
- package/dist/.pikku/secrets/pikku-secrets.gen.js +1 -1
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +1 -1
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js +1 -1
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +1 -1
- package/dist/.pikku/variables/pikku-variable-types.gen.js +1 -1
- package/dist/.pikku/variables/pikku-variables.gen.d.ts +1 -1
- package/dist/.pikku/variables/pikku-variables.gen.js +1 -1
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +1 -1
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +1 -1
- package/dist/bin/pikku-bin.mjs +2 -2
- package/dist/src/functions/db/annotation-parser.d.ts +27 -16
- package/dist/src/functions/db/annotation-parser.js +50 -110
- package/dist/src/functions/db/coercion-plugin.d.ts +1 -1
- package/dist/src/functions/db/coercion-plugin.js +4 -0
- package/dist/src/functions/db/db-codegen.d.ts +13 -1
- package/dist/src/functions/db/db-codegen.js +149 -34
- package/dist/src/functions/db/db-introspector.d.ts +6 -0
- package/dist/src/functions/db/local-db.js +96 -78
- package/dist/src/functions/db/postgres/postgres-introspector.js +2 -0
- package/dist/src/functions/db/zod-codegen.d.ts +38 -0
- package/dist/src/functions/db/zod-codegen.js +219 -32
- package/dist/src/scaffold/rpc-remote.gen.js +1 -1
- package/package.json +3 -3
- package/console-app/assets/index-DsW0T00Z.js +0 -233
package/console-app/index.html
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
}
|
|
22
22
|
} catch (e) {}
|
|
23
23
|
</script>
|
|
24
|
-
<script type="module" crossorigin src="/assets/index-
|
|
24
|
+
<script type="module" crossorigin src="/assets/index-BOM3RFeu.js"></script>
|
|
25
25
|
<link rel="stylesheet" crossorigin href="/assets/index-DwUzVI5k.css">
|
|
26
26
|
</head>
|
|
27
27
|
<body>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.35
|
|
3
3
|
*/
|
|
4
4
|
import { CoreAIAgent, PikkuAIMiddlewareHooks } from '@pikku/core/ai-agent';
|
|
5
5
|
import type { PikkuPermission, PikkuMiddleware, Services, PikkuFunctionConfig } from '../function/pikku-function-types.gen.js';
|
|
@@ -2001,30 +2001,6 @@
|
|
|
2001
2001
|
"inputHash": "b98cb2ee",
|
|
2002
2002
|
"outputHash": "9e33f562"
|
|
2003
2003
|
},
|
|
2004
|
-
"pikkuGateway": {
|
|
2005
|
-
"pikkuFuncId": "pikkuGateway",
|
|
2006
|
-
"functionType": "user",
|
|
2007
|
-
"funcWrapper": "pikkuSessionlessFunc",
|
|
2008
|
-
"sessionless": true,
|
|
2009
|
-
"name": "pikkuGateway",
|
|
2010
|
-
"inputSchemaName": null,
|
|
2011
|
-
"outputSchemaName": "PikkuGatewayOutput",
|
|
2012
|
-
"inputs": [],
|
|
2013
|
-
"outputs": [
|
|
2014
|
-
"PikkuGatewayOutput"
|
|
2015
|
-
],
|
|
2016
|
-
"implementationHash": "cc85ec16d890311e",
|
|
2017
|
-
"middleware": [
|
|
2018
|
-
{
|
|
2019
|
-
"type": "wire",
|
|
2020
|
-
"name": "logCommandInfoAndTime",
|
|
2021
|
-
"inline": false
|
|
2022
|
-
}
|
|
2023
|
-
],
|
|
2024
|
-
"contractHash": "8c9fc7c18aeb2212",
|
|
2025
|
-
"inputHash": "a5477eae",
|
|
2026
|
-
"outputHash": "b5ea8b47"
|
|
2027
|
-
},
|
|
2028
2004
|
"pikkuFunctionTypesSplit": {
|
|
2029
2005
|
"pikkuFuncId": "pikkuFunctionTypesSplit",
|
|
2030
2006
|
"functionType": "user",
|
|
@@ -2117,6 +2093,30 @@
|
|
|
2117
2093
|
"inputHash": "a3e730d9",
|
|
2118
2094
|
"outputHash": "e0b61e49"
|
|
2119
2095
|
},
|
|
2096
|
+
"pikkuGateway": {
|
|
2097
|
+
"pikkuFuncId": "pikkuGateway",
|
|
2098
|
+
"functionType": "user",
|
|
2099
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
2100
|
+
"sessionless": true,
|
|
2101
|
+
"name": "pikkuGateway",
|
|
2102
|
+
"inputSchemaName": null,
|
|
2103
|
+
"outputSchemaName": "PikkuGatewayOutput",
|
|
2104
|
+
"inputs": [],
|
|
2105
|
+
"outputs": [
|
|
2106
|
+
"PikkuGatewayOutput"
|
|
2107
|
+
],
|
|
2108
|
+
"implementationHash": "cc85ec16d890311e",
|
|
2109
|
+
"middleware": [
|
|
2110
|
+
{
|
|
2111
|
+
"type": "wire",
|
|
2112
|
+
"name": "logCommandInfoAndTime",
|
|
2113
|
+
"inline": false
|
|
2114
|
+
}
|
|
2115
|
+
],
|
|
2116
|
+
"contractHash": "8c9fc7c18aeb2212",
|
|
2117
|
+
"inputHash": "a5477eae",
|
|
2118
|
+
"outputHash": "b5ea8b47"
|
|
2119
|
+
},
|
|
2120
2120
|
"pikkuHTTPMap": {
|
|
2121
2121
|
"pikkuFuncId": "pikkuHTTPMap",
|
|
2122
2122
|
"functionType": "user",
|
|
@@ -95,7 +95,6 @@
|
|
|
95
95
|
"pikkuAIAgentTypes": "pikkuAIAgentTypes",
|
|
96
96
|
"pikkuAIAgent": "pikkuAIAgent",
|
|
97
97
|
"pikkuPublicAgent": "pikkuPublicAgent",
|
|
98
|
-
"pikkuAuth": "pikkuAuth",
|
|
99
98
|
"pikkuChannels": "pikkuChannels",
|
|
100
99
|
"pikkuChannelTypes": "pikkuChannelTypes",
|
|
101
100
|
"pikkuChannelsMap": "pikkuChannelsMap",
|
|
@@ -140,5 +139,6 @@
|
|
|
140
139
|
"pikkuTriggerTypes": "pikkuTriggerTypes",
|
|
141
140
|
"pikkuTrigger": "pikkuTrigger",
|
|
142
141
|
"pikkuVariables": "pikkuVariables",
|
|
143
|
-
"pikkuWorkflowRoutes": "pikkuWorkflowRoutes"
|
|
142
|
+
"pikkuWorkflowRoutes": "pikkuWorkflowRoutes",
|
|
143
|
+
"pikkuAuth": "pikkuAuth"
|
|
144
144
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.35
|
|
3
3
|
*/
|
|
4
4
|
import { addSchema } from '@pikku/core/schema';
|
|
5
5
|
import * as PikkuSchemasOutput from './schemas/PikkuSchemasOutput.schema.json' with { type: 'json' };
|
|
@@ -192,12 +192,12 @@ import * as PikkuCLIEntryOutput from './schemas/PikkuCLIEntryOutput.schema.json'
|
|
|
192
192
|
addSchema('PikkuCLIEntryOutput', PikkuCLIEntryOutput);
|
|
193
193
|
import * as PikkuCLIOutput from './schemas/PikkuCLIOutput.schema.json' with { type: 'json' };
|
|
194
194
|
addSchema('PikkuCLIOutput', PikkuCLIOutput);
|
|
195
|
-
import * as PikkuGatewayOutput from './schemas/PikkuGatewayOutput.schema.json' with { type: 'json' };
|
|
196
|
-
addSchema('PikkuGatewayOutput', PikkuGatewayOutput);
|
|
197
195
|
import * as PikkuFunctionTypesSplitInput from './schemas/PikkuFunctionTypesSplitInput.schema.json' with { type: 'json' };
|
|
198
196
|
addSchema('PikkuFunctionTypesSplitInput', PikkuFunctionTypesSplitInput);
|
|
199
197
|
import * as PikkuFunctionsOutput from './schemas/PikkuFunctionsOutput.schema.json' with { type: 'json' };
|
|
200
198
|
addSchema('PikkuFunctionsOutput', PikkuFunctionsOutput);
|
|
199
|
+
import * as PikkuGatewayOutput from './schemas/PikkuGatewayOutput.schema.json' with { type: 'json' };
|
|
200
|
+
addSchema('PikkuGatewayOutput', PikkuGatewayOutput);
|
|
201
201
|
import * as PikkuCommandHTTPOutput from './schemas/PikkuCommandHTTPOutput.schema.json' with { type: 'json' };
|
|
202
202
|
addSchema('PikkuCommandHTTPOutput', PikkuCommandHTTPOutput);
|
|
203
203
|
import * as PikkuHTTPOutput from './schemas/PikkuHTTPOutput.schema.json' with { type: 'json' };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.35
|
|
3
3
|
*/
|
|
4
4
|
export { wireVariable } from '@pikku/core/variable';
|
|
5
5
|
export type { CoreVariable, VariableDefinitionMeta, VariableDefinitionsMeta } from '@pikku/core/variable';
|
package/dist/bin/pikku-bin.mjs
CHANGED
|
@@ -11,8 +11,8 @@ async function checkForUpdate() {
|
|
|
11
11
|
})
|
|
12
12
|
if (!res.ok) return
|
|
13
13
|
const { version: latest } = await res.json()
|
|
14
|
-
if (latest !== '0.12.
|
|
15
|
-
process.stderr.write(`\n Update available 0.12.
|
|
14
|
+
if (latest !== '0.12.35') {
|
|
15
|
+
process.stderr.write(`\n Update available 0.12.35 → ${latest}\n brew upgrade pikku or npm install -g @pikku/cli\n\n`)
|
|
16
16
|
}
|
|
17
17
|
} catch {}
|
|
18
18
|
}
|
|
@@ -1,31 +1,42 @@
|
|
|
1
1
|
import type { ColumnKind } from './coercion-plugin.js';
|
|
2
|
+
import { type ZodFormat } from './zod-codegen.js';
|
|
2
3
|
type Classification = 'public' | 'private' | 'pii' | 'secret';
|
|
3
4
|
type AnonymizeStrategy = 'fake:email' | 'fake:name' | 'hash' | 'keep' | null;
|
|
4
5
|
export interface ColAnnotation {
|
|
6
|
+
/** Column kind override: `date`, `bool`, `json`, or `uuid`. */
|
|
5
7
|
kind?: ColumnKind;
|
|
6
|
-
/** TypeScript type string
|
|
8
|
+
/** TypeScript type string that overrides the inferred column type, e.g. `string[]`. */
|
|
7
9
|
tsType?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Zod string-format validator (`email`, `url`, …). Refines the zod schema only;
|
|
12
|
+
* the TypeScript type stays `string`. Applied by the codegen only when the
|
|
13
|
+
* column's resolved type is plain `string`.
|
|
14
|
+
*/
|
|
15
|
+
format?: ZodFormat;
|
|
8
16
|
classification?: Classification;
|
|
9
17
|
anonymize?: AnonymizeStrategy;
|
|
10
18
|
}
|
|
11
|
-
/** Per-table, per-column annotation map
|
|
19
|
+
/** Per-table, per-column annotation map sourced from `db/annotations.ts`. */
|
|
12
20
|
export type AnnotationMap = Record<string, Record<string, ColAnnotation>>;
|
|
13
21
|
/**
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
22
|
+
* Warn-only naming heuristic. We no longer *infer* a column's kind from its
|
|
23
|
+
* name (it produced wrong types — e.g. SQLite stores `*_at` as ISO TEXT, not a
|
|
24
|
+
* `Date`). Instead the codegen warns when a column name looks like it wants a
|
|
25
|
+
* `kind` but none is declared in `db/annotations.ts`, so the developer can opt
|
|
26
|
+
* in explicitly. Returns the *suggested* kind, or null.
|
|
17
27
|
*/
|
|
18
|
-
export declare function
|
|
19
|
-
kind: ColumnKind;
|
|
20
|
-
} | null;
|
|
28
|
+
export declare function nameSuggestsKind(colName: string): ColumnKind | null;
|
|
21
29
|
/**
|
|
22
|
-
*
|
|
23
|
-
*
|
|
30
|
+
* Load annotations from the `db/annotations.gen.json` sidecar, which is
|
|
31
|
+
* compiled from the developer-authored `db/annotations.ts` (`DbClassificationMap`)
|
|
32
|
+
* by `syncClassifications`. This is the single source of column classification
|
|
33
|
+
* and type-override information — there is no SQL-comment fallback.
|
|
34
|
+
*
|
|
35
|
+
* The authored `ColumnEntry` shape is:
|
|
36
|
+
* { security?, classification?: <anonymize strategy>, kind?, tsType?, description? }
|
|
37
|
+
* where `security` is the privacy level and `classification` is the anonymize
|
|
38
|
+
* strategy. Returns `{}` if the sidecar doesn't exist yet (first migrate run,
|
|
39
|
+
* before it has been generated).
|
|
24
40
|
*/
|
|
25
|
-
export declare function
|
|
26
|
-
/**
|
|
27
|
-
* Load annotations for a project. Tries `db/annotations.ts` sidecar first;
|
|
28
|
-
* falls back to SQL comment parsing from `migrationsDir` if not found.
|
|
29
|
-
*/
|
|
30
|
-
export declare function loadAnnotations(rootDir: string, migrationsDir?: string): AnnotationMap;
|
|
41
|
+
export declare function loadAnnotations(rootDir: string): AnnotationMap;
|
|
31
42
|
export {};
|