@pikku/cli 0.10.0 → 0.10.1
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/.pikku/channel/pikku-channel-types.gen.ts +1 -1
- package/.pikku/channel/pikku-channels-map.gen.d.ts +1 -1
- package/.pikku/channel/pikku-channels-meta.gen.ts +1 -1
- package/.pikku/channel/pikku-channels.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-channel.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-client.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-types.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-wirings-meta.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-wirings.gen.ts +1 -1
- package/.pikku/cli/pikku-cli.gen.ts +1 -1
- package/.pikku/function/pikku-function-types.gen.ts +1 -1
- package/.pikku/function/pikku-functions-meta.gen.ts +1 -1
- package/.pikku/function/pikku-functions-meta.min.gen.ts +1 -1
- package/.pikku/function/pikku-functions.gen.ts +1 -1
- package/.pikku/http/pikku-http-types.gen.ts +1 -1
- package/.pikku/http/pikku-http-wirings-map.gen.d.ts +1 -1
- package/.pikku/http/pikku-http-wirings-meta.gen.ts +1 -1
- package/.pikku/http/pikku-http-wirings.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-types.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-wirings-meta.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-wirings.gen.ts +1 -1
- package/.pikku/pikku-bootstrap.gen.ts +1 -1
- package/.pikku/pikku-services.gen.ts +1 -1
- package/.pikku/pikku-types.gen.ts +1 -1
- package/.pikku/pikku-websocket.gen.ts +1 -1
- package/.pikku/queue/pikku-queue-types.gen.ts +1 -1
- package/.pikku/queue/pikku-queue-workers-wirings-map.gen.d.ts +1 -1
- package/.pikku/queue/pikku-queue-workers-wirings-meta.gen.ts +1 -1
- package/.pikku/queue/pikku-queue-workers-wirings.gen.ts +1 -1
- package/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +1 -1
- package/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +1 -1
- package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +1 -1
- package/.pikku/scheduler/pikku-scheduler-types.gen.ts +1 -1
- package/.pikku/scheduler/pikku-schedulers-wirings-meta.gen.ts +1 -1
- package/.pikku/scheduler/pikku-schedulers-wirings.gen.ts +1 -1
- package/.pikku/schemas/register.gen.ts +1 -1
- package/CHANGELOG.md +9 -0
- 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/channel/pikku-channels-meta.gen.js +1 -1
- package/dist/.pikku/channel/pikku-channels.gen.d.ts +1 -1
- package/dist/.pikku/channel/pikku-channels.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-channel.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-client.gen.d.ts +1 -1
- package/dist/.pikku/cli/pikku-cli-client.gen.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/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.min.gen.js +1 -1
- 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/mcp/pikku-mcp-wirings-meta.gen.js +1 -1
- package/dist/.pikku/mcp/pikku-mcp-wirings.gen.d.ts +1 -1
- package/dist/.pikku/mcp/pikku-mcp-wirings.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-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/pikku-websocket.gen.d.ts +1 -1
- package/dist/.pikku/pikku-websocket.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/scheduler/pikku-scheduler-types.gen.d.ts +1 -1
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings-meta.gen.js +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings.gen.d.ts +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings.gen.js +1 -1
- package/dist/.pikku/schemas/register.gen.js +1 -1
- package/dist/src/utils/check-required-types.js +11 -1
- package/package.json +3 -3
- package/src/utils/check-required-types.ts +16 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.
|
|
2
|
+
* This file was generated by @pikku/cli@0.10.1
|
|
3
3
|
*/
|
|
4
4
|
import { CorePikkuWebsocket, CorePikkuRouteHandler } from '@pikku/websocket'
|
|
5
5
|
import { ChannelDefaultHandlerOf, ChannelWiringHandlerOf, ChannelsMap } from './channel/pikku-channels-map.gen.d.js';
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @pikku/cli
|
|
2
2
|
|
|
3
|
+
## 0.10.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 778267e: fix: fixing inspector ensuring pikkuConfig is set
|
|
8
|
+
- Updated dependencies [778267e]
|
|
9
|
+
- @pikku/inspector@0.10.1
|
|
10
|
+
- @pikku/core@0.10.1
|
|
11
|
+
|
|
3
12
|
## 0.10.0
|
|
4
13
|
|
|
5
14
|
This release includes significant improvements across the framework including tree-shaking support, middleware/permission factories, enhanced CLI functionality, improved TypeScript type safety, and comprehensive test strategies.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.
|
|
2
|
+
* This file was generated by @pikku/cli@0.10.1
|
|
3
3
|
*/
|
|
4
4
|
import { CorePikkuWebsocket, CorePikkuRouteHandler } from '@pikku/websocket';
|
|
5
5
|
import { ChannelDefaultHandlerOf, ChannelWiringHandlerOf, ChannelsMap } from './channel/pikku-channels-map.gen.d.js';
|
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
export const checkRequiredTypes = (errors, requires = {}) => {
|
|
2
|
+
// Filter out errors that are about missing Types when we have the corresponding Factory
|
|
3
|
+
// e.g., if we have a CreateConfig factory, we don't need a CoreConfig type
|
|
4
|
+
const errorMessages = Array.from(errors.keys());
|
|
5
|
+
const hasCreateConfigFactory = errorMessages.every((msg) => !msg.includes('No CreateConfig found'));
|
|
2
6
|
// Only throw if there are errors AND we require those types
|
|
3
|
-
const hasRequiredErrors =
|
|
7
|
+
const hasRequiredErrors = errorMessages.some((message) => {
|
|
8
|
+
// Skip CoreConfig type errors if we have a CreateConfig factory
|
|
9
|
+
if (requires.config &&
|
|
10
|
+
message.includes('No CoreConfig found') &&
|
|
11
|
+
hasCreateConfigFactory) {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
4
14
|
if (requires.config && message.includes('CoreConfig'))
|
|
5
15
|
return true;
|
|
6
16
|
if (requires.sessionServiceType && message.includes('CoreServices'))
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pikku/cli",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.1",
|
|
4
4
|
"author": "yasser.fadl@gmail.com",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"bin": {
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@openapi-contrib/json-schema-to-openapi-schema": "^4.2.0",
|
|
25
|
-
"@pikku/core": "^0.10.
|
|
26
|
-
"@pikku/inspector": "^0.10.
|
|
25
|
+
"@pikku/core": "^0.10.1",
|
|
26
|
+
"@pikku/inspector": "^0.10.1",
|
|
27
27
|
"@types/cookie": "^1.0.0",
|
|
28
28
|
"@types/json-schema": "^7.0.15",
|
|
29
29
|
"@types/uuid": "^11.0.0",
|
|
@@ -13,8 +13,23 @@ export const checkRequiredTypes = (
|
|
|
13
13
|
errors: FilesAndMethodsErrors,
|
|
14
14
|
requires: RequiredTypes = {}
|
|
15
15
|
): void => {
|
|
16
|
+
// Filter out errors that are about missing Types when we have the corresponding Factory
|
|
17
|
+
// e.g., if we have a CreateConfig factory, we don't need a CoreConfig type
|
|
18
|
+
const errorMessages = Array.from(errors.keys())
|
|
19
|
+
const hasCreateConfigFactory = errorMessages.every(
|
|
20
|
+
(msg) => !msg.includes('No CreateConfig found')
|
|
21
|
+
)
|
|
22
|
+
|
|
16
23
|
// Only throw if there are errors AND we require those types
|
|
17
|
-
const hasRequiredErrors =
|
|
24
|
+
const hasRequiredErrors = errorMessages.some((message) => {
|
|
25
|
+
// Skip CoreConfig type errors if we have a CreateConfig factory
|
|
26
|
+
if (
|
|
27
|
+
requires.config &&
|
|
28
|
+
message.includes('No CoreConfig found') &&
|
|
29
|
+
hasCreateConfigFactory
|
|
30
|
+
) {
|
|
31
|
+
return false
|
|
32
|
+
}
|
|
18
33
|
if (requires.config && message.includes('CoreConfig')) return true
|
|
19
34
|
if (requires.sessionServiceType && message.includes('CoreServices'))
|
|
20
35
|
return true
|