@mininglamp-oss/octo-runtime 1.0.1 → 1.1.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/README.md +122 -18
- package/apps/cli/README.md +44 -214
- package/apps/cli/dist/build-info.json +2 -2
- package/apps/cli/dist/extras.d.ts +4 -2
- package/apps/cli/dist/extras.js +24 -20
- package/apps/cli/dist/foreground.d.ts +4 -0
- package/apps/cli/dist/foreground.js +57 -0
- package/apps/cli/dist/help.d.ts +1 -14
- package/apps/cli/dist/help.js +73 -151
- package/apps/cli/dist/index.js +12 -1
- package/apps/cli/dist/logs.d.ts +10 -0
- package/apps/cli/dist/logs.js +186 -0
- package/apps/cli/dist/main.d.ts +6 -13
- package/apps/cli/dist/main.js +430 -447
- package/{node_modules/@mininglamp-oss/octo-runtime-cli/dist/default_adapters.json → apps/cli/dist/manifest.json} +5 -0
- package/apps/cli/dist/module-manifest.d.ts +3 -0
- package/apps/cli/dist/module-manifest.js +11 -0
- package/apps/{daemon → cli}/dist/openclaw.d.ts +1 -1
- package/apps/{daemon → cli}/dist/openclaw.js +30 -6
- package/apps/cli/dist/output.d.ts +20 -0
- package/apps/cli/dist/output.js +190 -0
- package/apps/cli/dist/playboard.js +33 -18
- package/apps/cli/dist/service-control.d.ts +2 -5
- package/apps/cli/dist/service-control.js +28 -33
- package/apps/cli/dist/state.js +4 -4
- package/apps/cli/dist/status-output.d.ts +10 -0
- package/apps/cli/dist/status-output.js +65 -0
- package/apps/cli/dist/worker.js +18 -0
- package/dist/public/channel-gateway.d.ts +3 -0
- package/dist/public/channel-gateway.js +1 -0
- package/dist/public/channel-wecom.d.ts +2 -0
- package/dist/public/channel-wecom.js +1 -0
- package/dist/public/executor-core.d.ts +2 -0
- package/dist/public/executor-core.js +1 -0
- package/dist/public/executor-kernel.d.ts +4 -0
- package/dist/public/executor-kernel.js +2 -0
- package/dist/public/extra.d.ts +3 -3
- package/dist/public/extra.js +1 -1
- package/dist/public/host.d.ts +7 -0
- package/dist/public/host.js +3 -0
- package/dist/public/webui.d.ts +1 -0
- package/dist/public/webui.js +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-acp-client/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.d.ts +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.js +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/module-manifest.d.ts +33 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/module-manifest.js +118 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/native.js +23 -6
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-cleanup.d.ts +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-cleanup.js +19 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log-worker.js +7 -5
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log.d.ts +3 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log.js +45 -10
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.d.ts +11 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.js +70 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/package.json +5 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/dist/app-server.js +18 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/build-info.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extras.d.ts +4 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extras.js +24 -20
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/foreground.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/foreground.js +57 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/help.d.ts +1 -14
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/help.js +73 -151
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/index.js +12 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/logs.d.ts +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/logs.js +186 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.d.ts +6 -13
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.js +430 -447
- package/{apps/cli/dist/default_adapters.json → node_modules/@mininglamp-oss/octo-runtime-cli/dist/manifest.json} +5 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/module-manifest.d.ts +3 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/module-manifest.js +11 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon-app → octo-runtime-cli}/dist/openclaw.d.ts +1 -1
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon-app → octo-runtime-cli}/dist/openclaw.js +30 -6
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.d.ts +20 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.js +190 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard.js +33 -18
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/service-control.d.ts +2 -5
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/service-control.js +28 -33
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/state.js +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/status-output.d.ts +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/status-output.js +65 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/worker.js +18 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/package.json +23 -8
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/common.d.ts +2 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/common.js +8 -3
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/launchd.js +19 -6
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/systemd.d.ts +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/systemd.js +47 -8
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/windows-task.d.ts +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/dist/windows-task.js +63 -12
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/package.json +2 -2
- package/node_modules/@mininglamp-oss/{octo-runtime-core → octo-runtime-executor-core}/dist/context.d.ts +5 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-core → octo-runtime-executor-core}/dist/context.js +5 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/index.d.ts +28 -16
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/index.js +217 -102
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/invoke-input.d.ts +11 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-core → octo-runtime-executor-core}/dist/invoke-input.js +5 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/model-input.d.ts +8 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/model-input.js +9 -6
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/watchdog.d.ts +4 -1
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/watchdog.js +4 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/package.json +15 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/client.d.ts +8 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/client.js +442 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/endpoint.d.ts +2 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/endpoint.js +108 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/heartbeat.d.ts +16 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/heartbeat.js +59 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/host-run-service.d.ts +15 -9
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/host-run-service.js +8 -2
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.d.ts +13 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.js +13 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-lifecycle.d.ts +53 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-lifecycle.js +279 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-executor-kernel}/dist/invocation-manifest.d.ts +11 -2
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-executor-kernel}/dist/invocation-manifest.js +25 -14
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/lifecycle.d.ts +23 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/lifecycle.js +23 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/manifest-adapters.d.ts +6 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/manifest-adapters.js +88 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/module-specifier.d.ts +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/module-specifier.js +2 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/process.d.ts +35 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/process.js +218 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/rpc.d.ts +13 -11
- package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/rpc.js +19 -8
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runner.js +5 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/serve.d.ts +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/serve.js +89 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.d.ts +22 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.js +436 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/service.d.ts +15 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/service.js +105 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/supervisor.d.ts +13 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/supervisor.js +191 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/types.d.ts +72 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/types.js +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/package.json +29 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/config-schema.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/host-session-store.d.ts +17 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/host-session-store.js +123 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/im-channel.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/im-channel.js +192 -67
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/rules-context.d.ts +25 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/rules-context.js +39 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/session-store.d.ts +25 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/session-store.js +28 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/contracts.d.ts +5 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/dispatcher.d.ts +2 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/dispatcher.js +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/task.d.ts +6 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/task.js +40 -8
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/extra.d.ts +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/extra.js +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/index.d.ts +4 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/manager.d.ts +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/manager.js +77 -17
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/ports.d.ts +14 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-session.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-session.js +22 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/channel.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/channel.js +31 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/contexts.js +7 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/normalize.d.ts +6 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/normalize.js +27 -0
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/wukong.js +12 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/package.json +6 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/config-schema.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/application/im-channel.js +11 -8
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/contracts.d.ts +1 -12
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/delivery/dispatcher.d.ts +2 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/delivery/dispatcher.js +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/extra.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/extra.js +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/ports.d.ts +4 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/package.json +5 -9
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/config-schema.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/index.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/index.js +6 -8
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/store.d.ts +4 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/store.js +54 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/package.json +2 -2
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/context-loader.d.ts +1 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/context-loader.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/endpoint.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/endpoint.js +20 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/errors.d.ts +6 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/errors.js +12 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/extra-config.d.ts +8 -1
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/extra-config.js +27 -12
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-dependencies.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-dependencies.js +21 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.d.ts +22 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.js +309 -0
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/extras.d.ts +5 -14
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon → octo-runtime-host-sdk}/dist/extras.js +24 -13
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon/dist/runtime → octo-runtime-host-sdk/dist}/home.d.ts +9 -18
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon/dist/runtime → octo-runtime-host-sdk/dist}/home.js +22 -73
- package/node_modules/@mininglamp-oss/{octo-runtime-daemon/dist/runtime → octo-runtime-host-sdk/dist}/identity.d.ts +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.d.ts +12 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.js +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/launch.d.ts +15 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/launch.js +22 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/native.d.ts +16 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/native.js +160 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/shutdown.d.ts +7 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/shutdown.js +39 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/types.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/types.js +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/package.json +30 -0
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.d.ts +124 -73
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.d.ts +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/invoke-input.js +6 -9
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/package.json +1 -1
- package/node_modules/import-meta-resolve/index.d.ts +19 -0
- package/node_modules/import-meta-resolve/index.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/index.js +47 -0
- package/node_modules/import-meta-resolve/lib/errors.d.ts +24 -0
- package/node_modules/import-meta-resolve/lib/errors.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/lib/errors.js +504 -0
- package/node_modules/import-meta-resolve/lib/get-format.d.ts +13 -0
- package/node_modules/import-meta-resolve/lib/get-format.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/lib/get-format.js +159 -0
- package/node_modules/import-meta-resolve/lib/package-json-reader.d.ts +31 -0
- package/node_modules/import-meta-resolve/lib/package-json-reader.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/lib/package-json-reader.js +177 -0
- package/node_modules/import-meta-resolve/lib/resolve.d.ts +29 -0
- package/node_modules/import-meta-resolve/lib/resolve.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/lib/resolve.js +1301 -0
- package/node_modules/import-meta-resolve/lib/utils.d.ts +6 -0
- package/node_modules/import-meta-resolve/lib/utils.d.ts.map +1 -0
- package/node_modules/import-meta-resolve/lib/utils.js +47 -0
- package/node_modules/import-meta-resolve/license +74 -0
- package/node_modules/import-meta-resolve/package.json +78 -0
- package/node_modules/import-meta-resolve/readme.md +252 -0
- package/package.json +60 -45
- package/packages/octo-runtime-extra-channel-gateway/config-schema.json +2 -2
- package/packages/octo-runtime-extra-channel-wecom/config-schema.json +2 -2
- package/packages/octo-runtime-extra-webui/config-schema.json +2 -2
- package/packages/octo-runtime-protocol/schema/kernel-ipc-fixtures.json +53 -0
- package/packages/octo-runtime-protocol/schema/kernel-ipc.schema.json +151 -0
- package/packages/octo-runtime-protocol/schema/protocol.schema.json +3991 -0
- package/apps/cli/dist/daemon-output.d.ts +0 -1
- package/apps/cli/dist/daemon-output.js +0 -49
- package/apps/cli/dist/temporary-daemon.d.ts +0 -11
- package/apps/cli/dist/temporary-daemon.js +0 -109
- package/apps/daemon/dist/index.d.ts +0 -2
- package/apps/daemon/dist/index.js +0 -134
- package/apps/daemon/dist/launcher.d.ts +0 -2
- package/apps/daemon/dist/launcher.js +0 -52
- package/apps/daemon/dist/runtime-options.d.ts +0 -9
- package/apps/daemon/dist/runtime-options.js +0 -58
- package/apps/daemon/dist/server.d.ts +0 -1
- package/apps/daemon/dist/server.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/model-input.d.ts +0 -5
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/process.d.ts +0 -31
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/process.js +0 -86
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/runner.js +0 -98
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/serve.d.ts +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/serve.js +0 -48
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/socket-server.d.ts +0 -21
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/dist/socket-server.js +0 -260
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-host/package.json +0 -37
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/daemon-output.d.ts +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/daemon-output.js +0 -49
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/temporary-daemon.d.ts +0 -11
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/temporary-daemon.js +0 -109
- package/node_modules/@mininglamp-oss/octo-runtime-core/dist/index.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-core/dist/index.js +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-core/dist/invoke-input.d.ts +0 -7
- package/node_modules/@mininglamp-oss/octo-runtime-core/package.json +0 -14
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/index.d.ts +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/index.js +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/modules.d.ts +0 -55
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/modules.js +0 -138
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/adapter-host.js +0 -33
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/daemon-runtime.d.ts +0 -37
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/daemon-runtime.js +0 -623
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/errors.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/errors.js +0 -17
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/index.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/index.js +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/local-extras.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/local-extras.js +0 -133
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/run-stream.d.ts +0 -14
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/run-stream.js +0 -223
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/runner.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/runner.js +0 -103
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/runtime-contract.d.ts +0 -36
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/runtime-contract.js +0 -57
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/supervisor.d.ts +0 -23
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/supervisor.js +0 -245
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/types.d.ts +0 -116
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/version.d.ts +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/version.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime-endpoint.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime-endpoint.js +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/server.d.ts +0 -67
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/dist/server.js +0 -814
- package/node_modules/@mininglamp-oss/octo-runtime-daemon/package.json +0 -52
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/index.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/index.js +0 -134
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/launcher.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/launcher.js +0 -52
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/runtime-options.d.ts +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/runtime-options.js +0 -58
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/server.d.ts +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/dist/server.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-daemon-app/package.json +0 -33
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/daemon-module.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/daemon-module.js +0 -64
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/daemon-module.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/daemon-module.js +0 -64
- package/node_modules/ajv/.runkit_example.js +0 -23
- package/node_modules/ajv/LICENSE +0 -22
- package/node_modules/ajv/README.md +0 -207
- package/node_modules/ajv/dist/2019.d.ts +0 -19
- package/node_modules/ajv/dist/2019.js +0 -61
- package/node_modules/ajv/dist/2019.js.map +0 -1
- package/node_modules/ajv/dist/2020.d.ts +0 -19
- package/node_modules/ajv/dist/2020.js +0 -55
- package/node_modules/ajv/dist/2020.js.map +0 -1
- package/node_modules/ajv/dist/ajv.d.ts +0 -18
- package/node_modules/ajv/dist/ajv.js +0 -50
- package/node_modules/ajv/dist/ajv.js.map +0 -1
- package/node_modules/ajv/dist/compile/codegen/code.d.ts +0 -40
- package/node_modules/ajv/dist/compile/codegen/code.js +0 -156
- package/node_modules/ajv/dist/compile/codegen/code.js.map +0 -1
- package/node_modules/ajv/dist/compile/codegen/index.d.ts +0 -79
- package/node_modules/ajv/dist/compile/codegen/index.js +0 -697
- package/node_modules/ajv/dist/compile/codegen/index.js.map +0 -1
- package/node_modules/ajv/dist/compile/codegen/scope.d.ts +0 -79
- package/node_modules/ajv/dist/compile/codegen/scope.js +0 -143
- package/node_modules/ajv/dist/compile/codegen/scope.js.map +0 -1
- package/node_modules/ajv/dist/compile/errors.d.ts +0 -13
- package/node_modules/ajv/dist/compile/errors.js +0 -123
- package/node_modules/ajv/dist/compile/errors.js.map +0 -1
- package/node_modules/ajv/dist/compile/index.d.ts +0 -80
- package/node_modules/ajv/dist/compile/index.js +0 -242
- package/node_modules/ajv/dist/compile/index.js.map +0 -1
- package/node_modules/ajv/dist/compile/jtd/parse.d.ts +0 -4
- package/node_modules/ajv/dist/compile/jtd/parse.js +0 -350
- package/node_modules/ajv/dist/compile/jtd/parse.js.map +0 -1
- package/node_modules/ajv/dist/compile/jtd/serialize.d.ts +0 -4
- package/node_modules/ajv/dist/compile/jtd/serialize.js +0 -236
- package/node_modules/ajv/dist/compile/jtd/serialize.js.map +0 -1
- package/node_modules/ajv/dist/compile/jtd/types.d.ts +0 -6
- package/node_modules/ajv/dist/compile/jtd/types.js +0 -14
- package/node_modules/ajv/dist/compile/jtd/types.js.map +0 -1
- package/node_modules/ajv/dist/compile/names.d.ts +0 -20
- package/node_modules/ajv/dist/compile/names.js +0 -28
- package/node_modules/ajv/dist/compile/names.js.map +0 -1
- package/node_modules/ajv/dist/compile/ref_error.d.ts +0 -6
- package/node_modules/ajv/dist/compile/ref_error.js +0 -12
- package/node_modules/ajv/dist/compile/ref_error.js.map +0 -1
- package/node_modules/ajv/dist/compile/resolve.d.ts +0 -12
- package/node_modules/ajv/dist/compile/resolve.js +0 -155
- package/node_modules/ajv/dist/compile/resolve.js.map +0 -1
- package/node_modules/ajv/dist/compile/rules.d.ts +0 -28
- package/node_modules/ajv/dist/compile/rules.js +0 -26
- package/node_modules/ajv/dist/compile/rules.js.map +0 -1
- package/node_modules/ajv/dist/compile/util.d.ts +0 -40
- package/node_modules/ajv/dist/compile/util.js +0 -178
- package/node_modules/ajv/dist/compile/util.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/applicability.d.ts +0 -6
- package/node_modules/ajv/dist/compile/validate/applicability.js +0 -19
- package/node_modules/ajv/dist/compile/validate/applicability.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/boolSchema.d.ts +0 -4
- package/node_modules/ajv/dist/compile/validate/boolSchema.js +0 -50
- package/node_modules/ajv/dist/compile/validate/boolSchema.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/dataType.d.ts +0 -17
- package/node_modules/ajv/dist/compile/validate/dataType.js +0 -203
- package/node_modules/ajv/dist/compile/validate/dataType.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/defaults.d.ts +0 -2
- package/node_modules/ajv/dist/compile/validate/defaults.js +0 -35
- package/node_modules/ajv/dist/compile/validate/defaults.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/index.d.ts +0 -42
- package/node_modules/ajv/dist/compile/validate/index.js +0 -520
- package/node_modules/ajv/dist/compile/validate/index.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/keyword.d.ts +0 -8
- package/node_modules/ajv/dist/compile/validate/keyword.js +0 -124
- package/node_modules/ajv/dist/compile/validate/keyword.js.map +0 -1
- package/node_modules/ajv/dist/compile/validate/subschema.d.ts +0 -47
- package/node_modules/ajv/dist/compile/validate/subschema.js +0 -81
- package/node_modules/ajv/dist/compile/validate/subschema.js.map +0 -1
- package/node_modules/ajv/dist/core.d.ts +0 -174
- package/node_modules/ajv/dist/core.js +0 -618
- package/node_modules/ajv/dist/core.js.map +0 -1
- package/node_modules/ajv/dist/jtd.d.ts +0 -47
- package/node_modules/ajv/dist/jtd.js +0 -72
- package/node_modules/ajv/dist/jtd.js.map +0 -1
- package/node_modules/ajv/dist/refs/data.json +0 -13
- package/node_modules/ajv/dist/refs/json-schema-2019-09/index.d.ts +0 -2
- package/node_modules/ajv/dist/refs/json-schema-2019-09/index.js +0 -28
- package/node_modules/ajv/dist/refs/json-schema-2019-09/index.js.map +0 -1
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/applicator.json +0 -53
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/content.json +0 -17
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/core.json +0 -57
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/format.json +0 -14
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/meta-data.json +0 -37
- package/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json +0 -90
- package/node_modules/ajv/dist/refs/json-schema-2019-09/schema.json +0 -39
- package/node_modules/ajv/dist/refs/json-schema-2020-12/index.d.ts +0 -2
- package/node_modules/ajv/dist/refs/json-schema-2020-12/index.js +0 -30
- package/node_modules/ajv/dist/refs/json-schema-2020-12/index.js.map +0 -1
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/applicator.json +0 -48
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/content.json +0 -17
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/core.json +0 -51
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/format-annotation.json +0 -14
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/meta-data.json +0 -37
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/unevaluated.json +0 -15
- package/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json +0 -90
- package/node_modules/ajv/dist/refs/json-schema-2020-12/schema.json +0 -55
- package/node_modules/ajv/dist/refs/json-schema-draft-06.json +0 -137
- package/node_modules/ajv/dist/refs/json-schema-draft-07.json +0 -151
- package/node_modules/ajv/dist/refs/json-schema-secure.json +0 -88
- package/node_modules/ajv/dist/refs/jtd-schema.d.ts +0 -3
- package/node_modules/ajv/dist/refs/jtd-schema.js +0 -118
- package/node_modules/ajv/dist/refs/jtd-schema.js.map +0 -1
- package/node_modules/ajv/dist/runtime/equal.d.ts +0 -6
- package/node_modules/ajv/dist/runtime/equal.js +0 -7
- package/node_modules/ajv/dist/runtime/equal.js.map +0 -1
- package/node_modules/ajv/dist/runtime/parseJson.d.ts +0 -18
- package/node_modules/ajv/dist/runtime/parseJson.js +0 -185
- package/node_modules/ajv/dist/runtime/parseJson.js.map +0 -1
- package/node_modules/ajv/dist/runtime/quote.d.ts +0 -5
- package/node_modules/ajv/dist/runtime/quote.js +0 -30
- package/node_modules/ajv/dist/runtime/quote.js.map +0 -1
- package/node_modules/ajv/dist/runtime/re2.d.ts +0 -6
- package/node_modules/ajv/dist/runtime/re2.js +0 -6
- package/node_modules/ajv/dist/runtime/re2.js.map +0 -1
- package/node_modules/ajv/dist/runtime/timestamp.d.ts +0 -5
- package/node_modules/ajv/dist/runtime/timestamp.js +0 -42
- package/node_modules/ajv/dist/runtime/timestamp.js.map +0 -1
- package/node_modules/ajv/dist/runtime/ucs2length.d.ts +0 -5
- package/node_modules/ajv/dist/runtime/ucs2length.js +0 -24
- package/node_modules/ajv/dist/runtime/ucs2length.js.map +0 -1
- package/node_modules/ajv/dist/runtime/uri.d.ts +0 -6
- package/node_modules/ajv/dist/runtime/uri.js +0 -6
- package/node_modules/ajv/dist/runtime/uri.js.map +0 -1
- package/node_modules/ajv/dist/runtime/validation_error.d.ts +0 -7
- package/node_modules/ajv/dist/runtime/validation_error.js +0 -11
- package/node_modules/ajv/dist/runtime/validation_error.js.map +0 -1
- package/node_modules/ajv/dist/standalone/index.d.ts +0 -6
- package/node_modules/ajv/dist/standalone/index.js +0 -90
- package/node_modules/ajv/dist/standalone/index.js.map +0 -1
- package/node_modules/ajv/dist/standalone/instance.d.ts +0 -12
- package/node_modules/ajv/dist/standalone/instance.js +0 -35
- package/node_modules/ajv/dist/standalone/instance.js.map +0 -1
- package/node_modules/ajv/dist/types/index.d.ts +0 -183
- package/node_modules/ajv/dist/types/index.js +0 -3
- package/node_modules/ajv/dist/types/index.js.map +0 -1
- package/node_modules/ajv/dist/types/json-schema.d.ts +0 -125
- package/node_modules/ajv/dist/types/json-schema.js +0 -3
- package/node_modules/ajv/dist/types/json-schema.js.map +0 -1
- package/node_modules/ajv/dist/types/jtd-schema.d.ts +0 -174
- package/node_modules/ajv/dist/types/jtd-schema.js +0 -3
- package/node_modules/ajv/dist/types/jtd-schema.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/additionalItems.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js +0 -49
- package/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js +0 -106
- package/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/allOf.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/allOf.js +0 -23
- package/node_modules/ajv/dist/vocabularies/applicator/allOf.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/anyOf.d.ts +0 -4
- package/node_modules/ajv/dist/vocabularies/applicator/anyOf.js +0 -12
- package/node_modules/ajv/dist/vocabularies/applicator/anyOf.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/contains.d.ts +0 -7
- package/node_modules/ajv/dist/vocabularies/applicator/contains.js +0 -95
- package/node_modules/ajv/dist/vocabularies/applicator/contains.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/dependencies.d.ts +0 -21
- package/node_modules/ajv/dist/vocabularies/applicator/dependencies.js +0 -85
- package/node_modules/ajv/dist/vocabularies/applicator/dependencies.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/dependentSchemas.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/dependentSchemas.js +0 -11
- package/node_modules/ajv/dist/vocabularies/applicator/dependentSchemas.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/if.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/applicator/if.js +0 -66
- package/node_modules/ajv/dist/vocabularies/applicator/if.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/index.d.ts +0 -13
- package/node_modules/ajv/dist/vocabularies/applicator/index.js +0 -44
- package/node_modules/ajv/dist/vocabularies/applicator/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/items.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/applicator/items.js +0 -52
- package/node_modules/ajv/dist/vocabularies/applicator/items.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/items2020.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/applicator/items2020.js +0 -30
- package/node_modules/ajv/dist/vocabularies/applicator/items2020.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/not.d.ts +0 -4
- package/node_modules/ajv/dist/vocabularies/applicator/not.js +0 -26
- package/node_modules/ajv/dist/vocabularies/applicator/not.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/oneOf.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/applicator/oneOf.js +0 -60
- package/node_modules/ajv/dist/vocabularies/applicator/oneOf.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/patternProperties.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js +0 -75
- package/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/prefixItems.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js +0 -12
- package/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/properties.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/properties.js +0 -54
- package/node_modules/ajv/dist/vocabularies/applicator/properties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/propertyNames.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js +0 -38
- package/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/applicator/thenElse.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/applicator/thenElse.js +0 -13
- package/node_modules/ajv/dist/vocabularies/applicator/thenElse.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/code.d.ts +0 -17
- package/node_modules/ajv/dist/vocabularies/code.js +0 -131
- package/node_modules/ajv/dist/vocabularies/code.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/core/id.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/core/id.js +0 -10
- package/node_modules/ajv/dist/vocabularies/core/id.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/core/index.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/core/index.js +0 -16
- package/node_modules/ajv/dist/vocabularies/core/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/core/ref.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/core/ref.js +0 -122
- package/node_modules/ajv/dist/vocabularies/core/ref.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/discriminator/index.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/discriminator/index.js +0 -104
- package/node_modules/ajv/dist/vocabularies/discriminator/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/discriminator/types.d.ts +0 -10
- package/node_modules/ajv/dist/vocabularies/discriminator/types.js +0 -9
- package/node_modules/ajv/dist/vocabularies/discriminator/types.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/draft2020.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/draft2020.js +0 -23
- package/node_modules/ajv/dist/vocabularies/draft2020.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/draft7.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/draft7.js +0 -17
- package/node_modules/ajv/dist/vocabularies/draft7.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicAnchor.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicAnchor.js +0 -30
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicAnchor.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.js +0 -51
- package/node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/dynamic/index.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/dynamic/index.js +0 -9
- package/node_modules/ajv/dist/vocabularies/dynamic/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveAnchor.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveAnchor.js +0 -16
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveAnchor.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveRef.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveRef.js +0 -10
- package/node_modules/ajv/dist/vocabularies/dynamic/recursiveRef.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/errors.d.ts +0 -9
- package/node_modules/ajv/dist/vocabularies/errors.js +0 -3
- package/node_modules/ajv/dist/vocabularies/errors.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/format/format.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/format/format.js +0 -92
- package/node_modules/ajv/dist/vocabularies/format/format.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/format/index.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/format/index.js +0 -6
- package/node_modules/ajv/dist/vocabularies/format/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/discriminator.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/jtd/discriminator.js +0 -71
- package/node_modules/ajv/dist/vocabularies/jtd/discriminator.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/elements.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/jtd/elements.js +0 -24
- package/node_modules/ajv/dist/vocabularies/jtd/elements.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/enum.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/jtd/enum.js +0 -43
- package/node_modules/ajv/dist/vocabularies/jtd/enum.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/error.d.ts +0 -9
- package/node_modules/ajv/dist/vocabularies/jtd/error.js +0 -20
- package/node_modules/ajv/dist/vocabularies/jtd/error.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/index.d.ts +0 -10
- package/node_modules/ajv/dist/vocabularies/jtd/index.js +0 -29
- package/node_modules/ajv/dist/vocabularies/jtd/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/metadata.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/jtd/metadata.js +0 -25
- package/node_modules/ajv/dist/vocabularies/jtd/metadata.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/nullable.d.ts +0 -4
- package/node_modules/ajv/dist/vocabularies/jtd/nullable.js +0 -22
- package/node_modules/ajv/dist/vocabularies/jtd/nullable.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/optionalProperties.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/jtd/optionalProperties.js +0 -15
- package/node_modules/ajv/dist/vocabularies/jtd/optionalProperties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/properties.d.ts +0 -22
- package/node_modules/ajv/dist/vocabularies/jtd/properties.js +0 -149
- package/node_modules/ajv/dist/vocabularies/jtd/properties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/ref.d.ts +0 -4
- package/node_modules/ajv/dist/vocabularies/jtd/ref.js +0 -67
- package/node_modules/ajv/dist/vocabularies/jtd/ref.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/type.d.ts +0 -10
- package/node_modules/ajv/dist/vocabularies/jtd/type.js +0 -69
- package/node_modules/ajv/dist/vocabularies/jtd/type.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/union.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/jtd/union.js +0 -12
- package/node_modules/ajv/dist/vocabularies/jtd/union.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/jtd/values.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/jtd/values.js +0 -51
- package/node_modules/ajv/dist/vocabularies/jtd/values.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/metadata.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/metadata.js +0 -18
- package/node_modules/ajv/dist/vocabularies/metadata.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/next.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/next.js +0 -8
- package/node_modules/ajv/dist/vocabularies/next.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/unevaluated/index.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/unevaluated/index.js +0 -7
- package/node_modules/ajv/dist/vocabularies/unevaluated/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.js +0 -40
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.js +0 -65
- package/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/const.d.ts +0 -6
- package/node_modules/ajv/dist/vocabularies/validation/const.js +0 -25
- package/node_modules/ajv/dist/vocabularies/validation/const.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/dependentRequired.d.ts +0 -5
- package/node_modules/ajv/dist/vocabularies/validation/dependentRequired.js +0 -12
- package/node_modules/ajv/dist/vocabularies/validation/dependentRequired.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/enum.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/validation/enum.js +0 -48
- package/node_modules/ajv/dist/vocabularies/validation/enum.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/index.d.ts +0 -16
- package/node_modules/ajv/dist/vocabularies/validation/index.js +0 -33
- package/node_modules/ajv/dist/vocabularies/validation/index.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/limitContains.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/validation/limitContains.js +0 -15
- package/node_modules/ajv/dist/vocabularies/validation/limitContains.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/limitItems.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/validation/limitItems.js +0 -24
- package/node_modules/ajv/dist/vocabularies/validation/limitItems.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/limitLength.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/validation/limitLength.js +0 -27
- package/node_modules/ajv/dist/vocabularies/validation/limitLength.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/limitNumber.d.ts +0 -11
- package/node_modules/ajv/dist/vocabularies/validation/limitNumber.js +0 -27
- package/node_modules/ajv/dist/vocabularies/validation/limitNumber.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/limitProperties.d.ts +0 -3
- package/node_modules/ajv/dist/vocabularies/validation/limitProperties.js +0 -24
- package/node_modules/ajv/dist/vocabularies/validation/limitProperties.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/multipleOf.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/validation/multipleOf.js +0 -26
- package/node_modules/ajv/dist/vocabularies/validation/multipleOf.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/pattern.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/validation/pattern.js +0 -33
- package/node_modules/ajv/dist/vocabularies/validation/pattern.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/required.d.ts +0 -8
- package/node_modules/ajv/dist/vocabularies/validation/required.js +0 -79
- package/node_modules/ajv/dist/vocabularies/validation/required.js.map +0 -1
- package/node_modules/ajv/dist/vocabularies/validation/uniqueItems.d.ts +0 -9
- package/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js +0 -64
- package/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js.map +0 -1
- package/node_modules/ajv/lib/2019.ts +0 -81
- package/node_modules/ajv/lib/2020.ts +0 -75
- package/node_modules/ajv/lib/ajv.ts +0 -70
- package/node_modules/ajv/lib/compile/codegen/code.ts +0 -169
- package/node_modules/ajv/lib/compile/codegen/index.ts +0 -852
- package/node_modules/ajv/lib/compile/codegen/scope.ts +0 -215
- package/node_modules/ajv/lib/compile/errors.ts +0 -184
- package/node_modules/ajv/lib/compile/index.ts +0 -324
- package/node_modules/ajv/lib/compile/jtd/parse.ts +0 -411
- package/node_modules/ajv/lib/compile/jtd/serialize.ts +0 -277
- package/node_modules/ajv/lib/compile/jtd/types.ts +0 -16
- package/node_modules/ajv/lib/compile/names.ts +0 -27
- package/node_modules/ajv/lib/compile/ref_error.ts +0 -13
- package/node_modules/ajv/lib/compile/resolve.ts +0 -149
- package/node_modules/ajv/lib/compile/rules.ts +0 -50
- package/node_modules/ajv/lib/compile/util.ts +0 -213
- package/node_modules/ajv/lib/compile/validate/applicability.ts +0 -22
- package/node_modules/ajv/lib/compile/validate/boolSchema.ts +0 -47
- package/node_modules/ajv/lib/compile/validate/dataType.ts +0 -230
- package/node_modules/ajv/lib/compile/validate/defaults.ts +0 -32
- package/node_modules/ajv/lib/compile/validate/index.ts +0 -582
- package/node_modules/ajv/lib/compile/validate/keyword.ts +0 -171
- package/node_modules/ajv/lib/compile/validate/subschema.ts +0 -135
- package/node_modules/ajv/lib/core.ts +0 -892
- package/node_modules/ajv/lib/jtd.ts +0 -132
- package/node_modules/ajv/lib/refs/data.json +0 -13
- package/node_modules/ajv/lib/refs/json-schema-2019-09/index.ts +0 -28
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/applicator.json +0 -53
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/content.json +0 -17
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/core.json +0 -57
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/format.json +0 -14
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/meta-data.json +0 -37
- package/node_modules/ajv/lib/refs/json-schema-2019-09/meta/validation.json +0 -90
- package/node_modules/ajv/lib/refs/json-schema-2019-09/schema.json +0 -39
- package/node_modules/ajv/lib/refs/json-schema-2020-12/index.ts +0 -30
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/applicator.json +0 -48
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/content.json +0 -17
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/core.json +0 -51
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/format-annotation.json +0 -14
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/meta-data.json +0 -37
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/unevaluated.json +0 -15
- package/node_modules/ajv/lib/refs/json-schema-2020-12/meta/validation.json +0 -90
- package/node_modules/ajv/lib/refs/json-schema-2020-12/schema.json +0 -55
- package/node_modules/ajv/lib/refs/json-schema-draft-06.json +0 -137
- package/node_modules/ajv/lib/refs/json-schema-draft-07.json +0 -151
- package/node_modules/ajv/lib/refs/json-schema-secure.json +0 -88
- package/node_modules/ajv/lib/refs/jtd-schema.ts +0 -130
- package/node_modules/ajv/lib/runtime/equal.ts +0 -7
- package/node_modules/ajv/lib/runtime/parseJson.ts +0 -177
- package/node_modules/ajv/lib/runtime/quote.ts +0 -31
- package/node_modules/ajv/lib/runtime/re2.ts +0 -6
- package/node_modules/ajv/lib/runtime/timestamp.ts +0 -46
- package/node_modules/ajv/lib/runtime/ucs2length.ts +0 -20
- package/node_modules/ajv/lib/runtime/uri.ts +0 -6
- package/node_modules/ajv/lib/runtime/validation_error.ts +0 -13
- package/node_modules/ajv/lib/standalone/index.ts +0 -100
- package/node_modules/ajv/lib/standalone/instance.ts +0 -36
- package/node_modules/ajv/lib/types/index.ts +0 -244
- package/node_modules/ajv/lib/types/json-schema.ts +0 -187
- package/node_modules/ajv/lib/types/jtd-schema.ts +0 -273
- package/node_modules/ajv/lib/vocabularies/applicator/additionalItems.ts +0 -56
- package/node_modules/ajv/lib/vocabularies/applicator/additionalProperties.ts +0 -118
- package/node_modules/ajv/lib/vocabularies/applicator/allOf.ts +0 -22
- package/node_modules/ajv/lib/vocabularies/applicator/anyOf.ts +0 -14
- package/node_modules/ajv/lib/vocabularies/applicator/contains.ts +0 -109
- package/node_modules/ajv/lib/vocabularies/applicator/dependencies.ts +0 -112
- package/node_modules/ajv/lib/vocabularies/applicator/dependentSchemas.ts +0 -11
- package/node_modules/ajv/lib/vocabularies/applicator/if.ts +0 -80
- package/node_modules/ajv/lib/vocabularies/applicator/index.ts +0 -53
- package/node_modules/ajv/lib/vocabularies/applicator/items.ts +0 -59
- package/node_modules/ajv/lib/vocabularies/applicator/items2020.ts +0 -36
- package/node_modules/ajv/lib/vocabularies/applicator/not.ts +0 -38
- package/node_modules/ajv/lib/vocabularies/applicator/oneOf.ts +0 -82
- package/node_modules/ajv/lib/vocabularies/applicator/patternProperties.ts +0 -91
- package/node_modules/ajv/lib/vocabularies/applicator/prefixItems.ts +0 -12
- package/node_modules/ajv/lib/vocabularies/applicator/properties.ts +0 -57
- package/node_modules/ajv/lib/vocabularies/applicator/propertyNames.ts +0 -50
- package/node_modules/ajv/lib/vocabularies/applicator/thenElse.ts +0 -13
- package/node_modules/ajv/lib/vocabularies/code.ts +0 -168
- package/node_modules/ajv/lib/vocabularies/core/id.ts +0 -10
- package/node_modules/ajv/lib/vocabularies/core/index.ts +0 -16
- package/node_modules/ajv/lib/vocabularies/core/ref.ts +0 -129
- package/node_modules/ajv/lib/vocabularies/discriminator/index.ts +0 -113
- package/node_modules/ajv/lib/vocabularies/discriminator/types.ts +0 -12
- package/node_modules/ajv/lib/vocabularies/draft2020.ts +0 -23
- package/node_modules/ajv/lib/vocabularies/draft7.ts +0 -17
- package/node_modules/ajv/lib/vocabularies/dynamic/dynamicAnchor.ts +0 -31
- package/node_modules/ajv/lib/vocabularies/dynamic/dynamicRef.ts +0 -51
- package/node_modules/ajv/lib/vocabularies/dynamic/index.ts +0 -9
- package/node_modules/ajv/lib/vocabularies/dynamic/recursiveAnchor.ts +0 -14
- package/node_modules/ajv/lib/vocabularies/dynamic/recursiveRef.ts +0 -10
- package/node_modules/ajv/lib/vocabularies/errors.ts +0 -18
- package/node_modules/ajv/lib/vocabularies/format/format.ts +0 -120
- package/node_modules/ajv/lib/vocabularies/format/index.ts +0 -6
- package/node_modules/ajv/lib/vocabularies/jtd/discriminator.ts +0 -89
- package/node_modules/ajv/lib/vocabularies/jtd/elements.ts +0 -32
- package/node_modules/ajv/lib/vocabularies/jtd/enum.ts +0 -45
- package/node_modules/ajv/lib/vocabularies/jtd/error.ts +0 -23
- package/node_modules/ajv/lib/vocabularies/jtd/index.ts +0 -37
- package/node_modules/ajv/lib/vocabularies/jtd/metadata.ts +0 -24
- package/node_modules/ajv/lib/vocabularies/jtd/nullable.ts +0 -21
- package/node_modules/ajv/lib/vocabularies/jtd/optionalProperties.ts +0 -15
- package/node_modules/ajv/lib/vocabularies/jtd/properties.ts +0 -184
- package/node_modules/ajv/lib/vocabularies/jtd/ref.ts +0 -76
- package/node_modules/ajv/lib/vocabularies/jtd/type.ts +0 -75
- package/node_modules/ajv/lib/vocabularies/jtd/union.ts +0 -12
- package/node_modules/ajv/lib/vocabularies/jtd/values.ts +0 -58
- package/node_modules/ajv/lib/vocabularies/metadata.ts +0 -17
- package/node_modules/ajv/lib/vocabularies/next.ts +0 -8
- package/node_modules/ajv/lib/vocabularies/unevaluated/index.ts +0 -7
- package/node_modules/ajv/lib/vocabularies/unevaluated/unevaluatedItems.ts +0 -47
- package/node_modules/ajv/lib/vocabularies/unevaluated/unevaluatedProperties.ts +0 -85
- package/node_modules/ajv/lib/vocabularies/validation/const.ts +0 -28
- package/node_modules/ajv/lib/vocabularies/validation/dependentRequired.ts +0 -23
- package/node_modules/ajv/lib/vocabularies/validation/enum.ts +0 -54
- package/node_modules/ajv/lib/vocabularies/validation/index.ts +0 -49
- package/node_modules/ajv/lib/vocabularies/validation/limitContains.ts +0 -16
- package/node_modules/ajv/lib/vocabularies/validation/limitItems.ts +0 -26
- package/node_modules/ajv/lib/vocabularies/validation/limitLength.ts +0 -30
- package/node_modules/ajv/lib/vocabularies/validation/limitNumber.ts +0 -42
- package/node_modules/ajv/lib/vocabularies/validation/limitProperties.ts +0 -26
- package/node_modules/ajv/lib/vocabularies/validation/multipleOf.ts +0 -34
- package/node_modules/ajv/lib/vocabularies/validation/pattern.ts +0 -39
- package/node_modules/ajv/lib/vocabularies/validation/required.ts +0 -98
- package/node_modules/ajv/lib/vocabularies/validation/uniqueItems.ts +0 -79
- package/node_modules/ajv/package.json +0 -126
- package/node_modules/fast-deep-equal/LICENSE +0 -21
- package/node_modules/fast-deep-equal/README.md +0 -96
- package/node_modules/fast-deep-equal/es6/index.d.ts +0 -2
- package/node_modules/fast-deep-equal/es6/index.js +0 -72
- package/node_modules/fast-deep-equal/es6/react.d.ts +0 -2
- package/node_modules/fast-deep-equal/es6/react.js +0 -79
- package/node_modules/fast-deep-equal/index.d.ts +0 -4
- package/node_modules/fast-deep-equal/index.js +0 -46
- package/node_modules/fast-deep-equal/package.json +0 -61
- package/node_modules/fast-deep-equal/react.d.ts +0 -2
- package/node_modules/fast-deep-equal/react.js +0 -53
- package/node_modules/fast-uri/.gitattributes +0 -2
- package/node_modules/fast-uri/.github/dependabot.yml +0 -13
- package/node_modules/fast-uri/.github/workflows/ci.yml +0 -106
- package/node_modules/fast-uri/.github/workflows/lock-threads.yml +0 -19
- package/node_modules/fast-uri/.github/workflows/package-manager-ci.yml +0 -24
- package/node_modules/fast-uri/LICENSE +0 -30
- package/node_modules/fast-uri/README.md +0 -152
- package/node_modules/fast-uri/benchmark/benchmark.mjs +0 -159
- package/node_modules/fast-uri/benchmark/equal.mjs +0 -51
- package/node_modules/fast-uri/benchmark/non-simple-domain.mjs +0 -22
- package/node_modules/fast-uri/benchmark/package.json +0 -17
- package/node_modules/fast-uri/benchmark/string-array-to-hex-stripped.mjs +0 -24
- package/node_modules/fast-uri/benchmark/ws-is-secure.mjs +0 -65
- package/node_modules/fast-uri/eslint.config.js +0 -6
- package/node_modules/fast-uri/index.js +0 -631
- package/node_modules/fast-uri/lib/schemes.js +0 -272
- package/node_modules/fast-uri/lib/utils.js +0 -747
- package/node_modules/fast-uri/package.json +0 -68
- package/node_modules/fast-uri/test/ajv.test.js +0 -43
- package/node_modules/fast-uri/test/component-safe-serialization.test.js +0 -163
- package/node_modules/fast-uri/test/equal.test.js +0 -145
- package/node_modules/fast-uri/test/fixtures/uri-js-parse.json +0 -503
- package/node_modules/fast-uri/test/fixtures/uri-js-serialize.json +0 -120
- package/node_modules/fast-uri/test/ipv6-canonical.test.js +0 -34
- package/node_modules/fast-uri/test/ipv6-validation.test.js +0 -124
- package/node_modules/fast-uri/test/malformed-percent.test.js +0 -77
- package/node_modules/fast-uri/test/malformed-urn.test.js +0 -61
- package/node_modules/fast-uri/test/parse.test.js +0 -327
- package/node_modules/fast-uri/test/query-fragment-normalization.test.js +0 -33
- package/node_modules/fast-uri/test/reserved-path-normalization.test.js +0 -109
- package/node_modules/fast-uri/test/resolve.test.js +0 -87
- package/node_modules/fast-uri/test/rfc-3986.test.js +0 -90
- package/node_modules/fast-uri/test/scheme-validation.test.js +0 -124
- package/node_modules/fast-uri/test/security-normalization.test.js +0 -178
- package/node_modules/fast-uri/test/security.test.js +0 -431
- package/node_modules/fast-uri/test/serialize.test.js +0 -151
- package/node_modules/fast-uri/test/uri-js-compatibility.test.js +0 -33
- package/node_modules/fast-uri/test/uri-js.test.js +0 -912
- package/node_modules/fast-uri/test/urn-full-input.test.js +0 -29
- package/node_modules/fast-uri/test/util.test.js +0 -38
- package/node_modules/fast-uri/test/websocket-query-preservation.test.js +0 -24
- package/node_modules/fast-uri/tsconfig.json +0 -9
- package/node_modules/fast-uri/types/index.d.ts +0 -60
- package/node_modules/fast-uri/types/index.test-d.ts +0 -17
- package/node_modules/json-schema-traverse/.eslintrc.yml +0 -27
- package/node_modules/json-schema-traverse/.github/FUNDING.yml +0 -2
- package/node_modules/json-schema-traverse/.github/workflows/build.yml +0 -28
- package/node_modules/json-schema-traverse/.github/workflows/publish.yml +0 -27
- package/node_modules/json-schema-traverse/LICENSE +0 -21
- package/node_modules/json-schema-traverse/README.md +0 -95
- package/node_modules/json-schema-traverse/index.d.ts +0 -40
- package/node_modules/json-schema-traverse/index.js +0 -93
- package/node_modules/json-schema-traverse/package.json +0 -43
- package/node_modules/json-schema-traverse/spec/.eslintrc.yml +0 -6
- package/node_modules/json-schema-traverse/spec/fixtures/schema.js +0 -125
- package/node_modules/json-schema-traverse/spec/index.spec.js +0 -171
- package/node_modules/require-from-string/index.js +0 -34
- package/node_modules/require-from-string/license +0 -21
- package/node_modules/require-from-string/package.json +0 -28
- package/node_modules/require-from-string/readme.md +0 -56
- package/node_modules/yaml/LICENSE +0 -13
- package/node_modules/yaml/README.md +0 -172
- package/node_modules/yaml/bin.mjs +0 -11
- package/node_modules/yaml/browser/dist/compose/compose-collection.js +0 -88
- package/node_modules/yaml/browser/dist/compose/compose-doc.js +0 -43
- package/node_modules/yaml/browser/dist/compose/compose-node.js +0 -109
- package/node_modules/yaml/browser/dist/compose/compose-scalar.js +0 -86
- package/node_modules/yaml/browser/dist/compose/composer.js +0 -219
- package/node_modules/yaml/browser/dist/compose/resolve-block-map.js +0 -115
- package/node_modules/yaml/browser/dist/compose/resolve-block-scalar.js +0 -198
- package/node_modules/yaml/browser/dist/compose/resolve-block-seq.js +0 -49
- package/node_modules/yaml/browser/dist/compose/resolve-end.js +0 -37
- package/node_modules/yaml/browser/dist/compose/resolve-flow-collection.js +0 -207
- package/node_modules/yaml/browser/dist/compose/resolve-flow-scalar.js +0 -226
- package/node_modules/yaml/browser/dist/compose/resolve-props.js +0 -146
- package/node_modules/yaml/browser/dist/compose/util-contains-newline.js +0 -34
- package/node_modules/yaml/browser/dist/compose/util-empty-scalar-position.js +0 -26
- package/node_modules/yaml/browser/dist/compose/util-flow-indent-check.js +0 -15
- package/node_modules/yaml/browser/dist/compose/util-map-includes.js +0 -13
- package/node_modules/yaml/browser/dist/doc/Document.js +0 -335
- package/node_modules/yaml/browser/dist/doc/anchors.js +0 -71
- package/node_modules/yaml/browser/dist/doc/applyReviver.js +0 -55
- package/node_modules/yaml/browser/dist/doc/createNode.js +0 -88
- package/node_modules/yaml/browser/dist/doc/directives.js +0 -176
- package/node_modules/yaml/browser/dist/errors.js +0 -57
- package/node_modules/yaml/browser/dist/index.js +0 -17
- package/node_modules/yaml/browser/dist/log.js +0 -11
- package/node_modules/yaml/browser/dist/nodes/Alias.js +0 -118
- package/node_modules/yaml/browser/dist/nodes/Collection.js +0 -147
- package/node_modules/yaml/browser/dist/nodes/Node.js +0 -38
- package/node_modules/yaml/browser/dist/nodes/Pair.js +0 -36
- package/node_modules/yaml/browser/dist/nodes/Scalar.js +0 -24
- package/node_modules/yaml/browser/dist/nodes/YAMLMap.js +0 -144
- package/node_modules/yaml/browser/dist/nodes/YAMLSeq.js +0 -113
- package/node_modules/yaml/browser/dist/nodes/addPairToJSMap.js +0 -63
- package/node_modules/yaml/browser/dist/nodes/identity.js +0 -36
- package/node_modules/yaml/browser/dist/nodes/toJS.js +0 -37
- package/node_modules/yaml/browser/dist/parse/cst-scalar.js +0 -214
- package/node_modules/yaml/browser/dist/parse/cst-stringify.js +0 -61
- package/node_modules/yaml/browser/dist/parse/cst-visit.js +0 -97
- package/node_modules/yaml/browser/dist/parse/cst.js +0 -98
- package/node_modules/yaml/browser/dist/parse/lexer.js +0 -721
- package/node_modules/yaml/browser/dist/parse/line-counter.js +0 -39
- package/node_modules/yaml/browser/dist/parse/parser.js +0 -975
- package/node_modules/yaml/browser/dist/public-api.js +0 -102
- package/node_modules/yaml/browser/dist/schema/Schema.js +0 -37
- package/node_modules/yaml/browser/dist/schema/common/map.js +0 -17
- package/node_modules/yaml/browser/dist/schema/common/null.js +0 -15
- package/node_modules/yaml/browser/dist/schema/common/seq.js +0 -17
- package/node_modules/yaml/browser/dist/schema/common/string.js +0 -14
- package/node_modules/yaml/browser/dist/schema/core/bool.js +0 -19
- package/node_modules/yaml/browser/dist/schema/core/float.js +0 -43
- package/node_modules/yaml/browser/dist/schema/core/int.js +0 -38
- package/node_modules/yaml/browser/dist/schema/core/schema.js +0 -23
- package/node_modules/yaml/browser/dist/schema/json/schema.js +0 -62
- package/node_modules/yaml/browser/dist/schema/tags.js +0 -96
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/binary.js +0 -58
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/bool.js +0 -26
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/float.js +0 -46
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/int.js +0 -71
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/merge.js +0 -67
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/omap.js +0 -74
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/pairs.js +0 -78
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/schema.js +0 -39
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/set.js +0 -93
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/timestamp.js +0 -101
- package/node_modules/yaml/browser/dist/stringify/foldFlowLines.js +0 -146
- package/node_modules/yaml/browser/dist/stringify/stringify.js +0 -129
- package/node_modules/yaml/browser/dist/stringify/stringifyCollection.js +0 -153
- package/node_modules/yaml/browser/dist/stringify/stringifyComment.js +0 -20
- package/node_modules/yaml/browser/dist/stringify/stringifyDocument.js +0 -85
- package/node_modules/yaml/browser/dist/stringify/stringifyNumber.js +0 -25
- package/node_modules/yaml/browser/dist/stringify/stringifyPair.js +0 -150
- package/node_modules/yaml/browser/dist/stringify/stringifyString.js +0 -336
- package/node_modules/yaml/browser/dist/util.js +0 -11
- package/node_modules/yaml/browser/dist/visit.js +0 -233
- package/node_modules/yaml/browser/index.js +0 -5
- package/node_modules/yaml/browser/package.json +0 -3
- package/node_modules/yaml/dist/cli.d.ts +0 -8
- package/node_modules/yaml/dist/cli.mjs +0 -201
- package/node_modules/yaml/dist/compose/compose-collection.d.ts +0 -11
- package/node_modules/yaml/dist/compose/compose-collection.js +0 -90
- package/node_modules/yaml/dist/compose/compose-doc.d.ts +0 -7
- package/node_modules/yaml/dist/compose/compose-doc.js +0 -45
- package/node_modules/yaml/dist/compose/compose-node.d.ts +0 -29
- package/node_modules/yaml/dist/compose/compose-node.js +0 -112
- package/node_modules/yaml/dist/compose/compose-scalar.d.ts +0 -5
- package/node_modules/yaml/dist/compose/compose-scalar.js +0 -88
- package/node_modules/yaml/dist/compose/composer.d.ts +0 -63
- package/node_modules/yaml/dist/compose/composer.js +0 -224
- package/node_modules/yaml/dist/compose/resolve-block-map.d.ts +0 -6
- package/node_modules/yaml/dist/compose/resolve-block-map.js +0 -117
- package/node_modules/yaml/dist/compose/resolve-block-scalar.d.ts +0 -11
- package/node_modules/yaml/dist/compose/resolve-block-scalar.js +0 -200
- package/node_modules/yaml/dist/compose/resolve-block-seq.d.ts +0 -6
- package/node_modules/yaml/dist/compose/resolve-block-seq.js +0 -51
- package/node_modules/yaml/dist/compose/resolve-end.d.ts +0 -6
- package/node_modules/yaml/dist/compose/resolve-end.js +0 -39
- package/node_modules/yaml/dist/compose/resolve-flow-collection.d.ts +0 -7
- package/node_modules/yaml/dist/compose/resolve-flow-collection.js +0 -209
- package/node_modules/yaml/dist/compose/resolve-flow-scalar.d.ts +0 -10
- package/node_modules/yaml/dist/compose/resolve-flow-scalar.js +0 -228
- package/node_modules/yaml/dist/compose/resolve-props.d.ts +0 -23
- package/node_modules/yaml/dist/compose/resolve-props.js +0 -148
- package/node_modules/yaml/dist/compose/util-contains-newline.d.ts +0 -2
- package/node_modules/yaml/dist/compose/util-contains-newline.js +0 -36
- package/node_modules/yaml/dist/compose/util-empty-scalar-position.d.ts +0 -2
- package/node_modules/yaml/dist/compose/util-empty-scalar-position.js +0 -28
- package/node_modules/yaml/dist/compose/util-flow-indent-check.d.ts +0 -3
- package/node_modules/yaml/dist/compose/util-flow-indent-check.js +0 -17
- package/node_modules/yaml/dist/compose/util-map-includes.d.ts +0 -4
- package/node_modules/yaml/dist/compose/util-map-includes.js +0 -15
- package/node_modules/yaml/dist/doc/Document.d.ts +0 -141
- package/node_modules/yaml/dist/doc/Document.js +0 -337
- package/node_modules/yaml/dist/doc/anchors.d.ts +0 -24
- package/node_modules/yaml/dist/doc/anchors.js +0 -76
- package/node_modules/yaml/dist/doc/applyReviver.d.ts +0 -9
- package/node_modules/yaml/dist/doc/applyReviver.js +0 -57
- package/node_modules/yaml/dist/doc/createNode.d.ts +0 -17
- package/node_modules/yaml/dist/doc/createNode.js +0 -90
- package/node_modules/yaml/dist/doc/directives.d.ts +0 -49
- package/node_modules/yaml/dist/doc/directives.js +0 -178
- package/node_modules/yaml/dist/errors.d.ts +0 -21
- package/node_modules/yaml/dist/errors.js +0 -62
- package/node_modules/yaml/dist/index.d.ts +0 -25
- package/node_modules/yaml/dist/index.js +0 -50
- package/node_modules/yaml/dist/log.d.ts +0 -3
- package/node_modules/yaml/dist/log.js +0 -19
- package/node_modules/yaml/dist/nodes/Alias.d.ts +0 -29
- package/node_modules/yaml/dist/nodes/Alias.js +0 -120
- package/node_modules/yaml/dist/nodes/Collection.d.ts +0 -73
- package/node_modules/yaml/dist/nodes/Collection.js +0 -151
- package/node_modules/yaml/dist/nodes/Node.d.ts +0 -53
- package/node_modules/yaml/dist/nodes/Node.js +0 -40
- package/node_modules/yaml/dist/nodes/Pair.d.ts +0 -22
- package/node_modules/yaml/dist/nodes/Pair.js +0 -39
- package/node_modules/yaml/dist/nodes/Scalar.d.ts +0 -47
- package/node_modules/yaml/dist/nodes/Scalar.js +0 -27
- package/node_modules/yaml/dist/nodes/YAMLMap.d.ts +0 -53
- package/node_modules/yaml/dist/nodes/YAMLMap.js +0 -147
- package/node_modules/yaml/dist/nodes/YAMLSeq.d.ts +0 -60
- package/node_modules/yaml/dist/nodes/YAMLSeq.js +0 -115
- package/node_modules/yaml/dist/nodes/addPairToJSMap.d.ts +0 -4
- package/node_modules/yaml/dist/nodes/addPairToJSMap.js +0 -65
- package/node_modules/yaml/dist/nodes/identity.d.ts +0 -23
- package/node_modules/yaml/dist/nodes/identity.js +0 -53
- package/node_modules/yaml/dist/nodes/toJS.d.ts +0 -29
- package/node_modules/yaml/dist/nodes/toJS.js +0 -39
- package/node_modules/yaml/dist/options.d.ts +0 -350
- package/node_modules/yaml/dist/parse/cst-scalar.d.ts +0 -64
- package/node_modules/yaml/dist/parse/cst-scalar.js +0 -218
- package/node_modules/yaml/dist/parse/cst-stringify.d.ts +0 -8
- package/node_modules/yaml/dist/parse/cst-stringify.js +0 -63
- package/node_modules/yaml/dist/parse/cst-visit.d.ts +0 -39
- package/node_modules/yaml/dist/parse/cst-visit.js +0 -99
- package/node_modules/yaml/dist/parse/cst.d.ts +0 -109
- package/node_modules/yaml/dist/parse/cst.js +0 -112
- package/node_modules/yaml/dist/parse/lexer.d.ts +0 -87
- package/node_modules/yaml/dist/parse/lexer.js +0 -723
- package/node_modules/yaml/dist/parse/line-counter.d.ts +0 -22
- package/node_modules/yaml/dist/parse/line-counter.js +0 -41
- package/node_modules/yaml/dist/parse/parser.d.ts +0 -84
- package/node_modules/yaml/dist/parse/parser.js +0 -980
- package/node_modules/yaml/dist/public-api.d.ts +0 -44
- package/node_modules/yaml/dist/public-api.js +0 -107
- package/node_modules/yaml/dist/schema/Schema.d.ts +0 -17
- package/node_modules/yaml/dist/schema/Schema.js +0 -39
- package/node_modules/yaml/dist/schema/common/map.d.ts +0 -2
- package/node_modules/yaml/dist/schema/common/map.js +0 -19
- package/node_modules/yaml/dist/schema/common/null.d.ts +0 -4
- package/node_modules/yaml/dist/schema/common/null.js +0 -17
- package/node_modules/yaml/dist/schema/common/seq.d.ts +0 -2
- package/node_modules/yaml/dist/schema/common/seq.js +0 -19
- package/node_modules/yaml/dist/schema/common/string.d.ts +0 -2
- package/node_modules/yaml/dist/schema/common/string.js +0 -16
- package/node_modules/yaml/dist/schema/core/bool.d.ts +0 -4
- package/node_modules/yaml/dist/schema/core/bool.js +0 -21
- package/node_modules/yaml/dist/schema/core/float.d.ts +0 -4
- package/node_modules/yaml/dist/schema/core/float.js +0 -47
- package/node_modules/yaml/dist/schema/core/int.d.ts +0 -4
- package/node_modules/yaml/dist/schema/core/int.js +0 -42
- package/node_modules/yaml/dist/schema/core/schema.d.ts +0 -1
- package/node_modules/yaml/dist/schema/core/schema.js +0 -25
- package/node_modules/yaml/dist/schema/json/schema.d.ts +0 -2
- package/node_modules/yaml/dist/schema/json/schema.js +0 -64
- package/node_modules/yaml/dist/schema/json-schema.d.ts +0 -69
- package/node_modules/yaml/dist/schema/tags.d.ts +0 -48
- package/node_modules/yaml/dist/schema/tags.js +0 -99
- package/node_modules/yaml/dist/schema/types.d.ts +0 -92
- package/node_modules/yaml/dist/schema/yaml-1.1/binary.d.ts +0 -2
- package/node_modules/yaml/dist/schema/yaml-1.1/binary.js +0 -70
- package/node_modules/yaml/dist/schema/yaml-1.1/bool.d.ts +0 -7
- package/node_modules/yaml/dist/schema/yaml-1.1/bool.js +0 -29
- package/node_modules/yaml/dist/schema/yaml-1.1/float.d.ts +0 -4
- package/node_modules/yaml/dist/schema/yaml-1.1/float.js +0 -50
- package/node_modules/yaml/dist/schema/yaml-1.1/int.d.ts +0 -5
- package/node_modules/yaml/dist/schema/yaml-1.1/int.js +0 -76
- package/node_modules/yaml/dist/schema/yaml-1.1/merge.d.ts +0 -9
- package/node_modules/yaml/dist/schema/yaml-1.1/merge.js +0 -71
- package/node_modules/yaml/dist/schema/yaml-1.1/omap.d.ts +0 -22
- package/node_modules/yaml/dist/schema/yaml-1.1/omap.js +0 -77
- package/node_modules/yaml/dist/schema/yaml-1.1/pairs.d.ts +0 -10
- package/node_modules/yaml/dist/schema/yaml-1.1/pairs.js +0 -82
- package/node_modules/yaml/dist/schema/yaml-1.1/schema.d.ts +0 -1
- package/node_modules/yaml/dist/schema/yaml-1.1/schema.js +0 -41
- package/node_modules/yaml/dist/schema/yaml-1.1/set.d.ts +0 -28
- package/node_modules/yaml/dist/schema/yaml-1.1/set.js +0 -96
- package/node_modules/yaml/dist/schema/yaml-1.1/timestamp.d.ts +0 -6
- package/node_modules/yaml/dist/schema/yaml-1.1/timestamp.js +0 -105
- package/node_modules/yaml/dist/stringify/foldFlowLines.d.ts +0 -34
- package/node_modules/yaml/dist/stringify/foldFlowLines.js +0 -151
- package/node_modules/yaml/dist/stringify/stringify.d.ts +0 -21
- package/node_modules/yaml/dist/stringify/stringify.js +0 -132
- package/node_modules/yaml/dist/stringify/stringifyCollection.d.ts +0 -17
- package/node_modules/yaml/dist/stringify/stringifyCollection.js +0 -155
- package/node_modules/yaml/dist/stringify/stringifyComment.d.ts +0 -10
- package/node_modules/yaml/dist/stringify/stringifyComment.js +0 -24
- package/node_modules/yaml/dist/stringify/stringifyDocument.d.ts +0 -4
- package/node_modules/yaml/dist/stringify/stringifyDocument.js +0 -87
- package/node_modules/yaml/dist/stringify/stringifyNumber.d.ts +0 -2
- package/node_modules/yaml/dist/stringify/stringifyNumber.js +0 -27
- package/node_modules/yaml/dist/stringify/stringifyPair.d.ts +0 -3
- package/node_modules/yaml/dist/stringify/stringifyPair.js +0 -152
- package/node_modules/yaml/dist/stringify/stringifyString.d.ts +0 -9
- package/node_modules/yaml/dist/stringify/stringifyString.js +0 -338
- package/node_modules/yaml/dist/test-events.d.ts +0 -4
- package/node_modules/yaml/dist/test-events.js +0 -134
- package/node_modules/yaml/dist/util.d.ts +0 -16
- package/node_modules/yaml/dist/util.js +0 -28
- package/node_modules/yaml/dist/visit.d.ts +0 -102
- package/node_modules/yaml/dist/visit.js +0 -236
- package/node_modules/yaml/package.json +0 -97
- package/node_modules/yaml/util.js +0 -2
- /package/{node_modules/@mininglamp-oss/octo-runtime-daemon/dist/runtime/adapter-host.d.ts → apps/cli/dist/worker.d.ts} +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-daemon/dist/runtime/types.js → octo-runtime-cli/dist/worker.d.ts} +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/execution-preparation.d.ts +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/execution-preparation.js +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/experience.d.ts +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-core}/dist/experience.js +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/runner.d.ts +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/runtime-configuration.d.ts +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-adapter-host → octo-runtime-executor-kernel}/dist/runtime-configuration.js +0 -0
- /package/node_modules/@mininglamp-oss/{octo-runtime-daemon/dist/runtime → octo-runtime-host-sdk/dist}/identity.js +0 -0
|
@@ -0,0 +1,1301 @@
|
|
|
1
|
+
// Manually “tree shaken” from:
|
|
2
|
+
// <https://github.com/nodejs/node/blob/81a9a97/lib/internal/modules/esm/resolve.js>
|
|
3
|
+
// Last checked on: Apr 29, 2024.
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @import {Stats} from 'node:fs'
|
|
7
|
+
* @import {ErrnoException} from './errors.js'
|
|
8
|
+
* @import {PackageConfig} from './package-json-reader.js'
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
import assert from 'node:assert'
|
|
12
|
+
import {statSync, realpathSync} from 'node:fs'
|
|
13
|
+
import process from 'node:process'
|
|
14
|
+
import {fileURLToPath, pathToFileURL} from 'node:url'
|
|
15
|
+
import path from 'node:path'
|
|
16
|
+
import {builtinModules} from 'node:module'
|
|
17
|
+
import {defaultGetFormatWithoutErrors} from './get-format.js'
|
|
18
|
+
import {codes} from './errors.js'
|
|
19
|
+
import {getPackageScopeConfig, read} from './package-json-reader.js'
|
|
20
|
+
import {getConditionsSet} from './utils.js'
|
|
21
|
+
|
|
22
|
+
const RegExpPrototypeSymbolReplace = RegExp.prototype[Symbol.replace]
|
|
23
|
+
|
|
24
|
+
const {
|
|
25
|
+
ERR_NETWORK_IMPORT_DISALLOWED,
|
|
26
|
+
ERR_INVALID_MODULE_SPECIFIER,
|
|
27
|
+
ERR_INVALID_PACKAGE_CONFIG,
|
|
28
|
+
ERR_INVALID_PACKAGE_TARGET,
|
|
29
|
+
ERR_MODULE_NOT_FOUND,
|
|
30
|
+
ERR_PACKAGE_IMPORT_NOT_DEFINED,
|
|
31
|
+
ERR_PACKAGE_PATH_NOT_EXPORTED,
|
|
32
|
+
ERR_UNSUPPORTED_DIR_IMPORT,
|
|
33
|
+
ERR_UNSUPPORTED_RESOLVE_REQUEST
|
|
34
|
+
} = codes
|
|
35
|
+
|
|
36
|
+
const own = {}.hasOwnProperty
|
|
37
|
+
|
|
38
|
+
const invalidSegmentRegEx =
|
|
39
|
+
/(^|\\|\/)((\.|%2e)(\.|%2e)?|(n|%6e|%4e)(o|%6f|%4f)(d|%64|%44)(e|%65|%45)(_|%5f)(m|%6d|%4d)(o|%6f|%4f)(d|%64|%44)(u|%75|%55)(l|%6c|%4c)(e|%65|%45)(s|%73|%53))?(\\|\/|$)/i
|
|
40
|
+
const deprecatedInvalidSegmentRegEx =
|
|
41
|
+
/(^|\\|\/)((\.|%2e)(\.|%2e)?|(n|%6e|%4e)(o|%6f|%4f)(d|%64|%44)(e|%65|%45)(_|%5f)(m|%6d|%4d)(o|%6f|%4f)(d|%64|%44)(u|%75|%55)(l|%6c|%4c)(e|%65|%45)(s|%73|%53))(\\|\/|$)/i
|
|
42
|
+
const invalidPackageNameRegEx = /^\.|%|\\/
|
|
43
|
+
const patternRegEx = /\*/g
|
|
44
|
+
const encodedSeparatorRegEx = /%2f|%5c/i
|
|
45
|
+
/** @type {Set<string>} */
|
|
46
|
+
const emittedPackageWarnings = new Set()
|
|
47
|
+
|
|
48
|
+
const doubleSlashRegEx = /[/\\]{2}/
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @param {string} target
|
|
53
|
+
* @param {string} request
|
|
54
|
+
* @param {string} match
|
|
55
|
+
* @param {URL} packageJsonUrl
|
|
56
|
+
* @param {boolean} internal
|
|
57
|
+
* @param {URL} base
|
|
58
|
+
* @param {boolean} isTarget
|
|
59
|
+
*/
|
|
60
|
+
function emitInvalidSegmentDeprecation(
|
|
61
|
+
target,
|
|
62
|
+
request,
|
|
63
|
+
match,
|
|
64
|
+
packageJsonUrl,
|
|
65
|
+
internal,
|
|
66
|
+
base,
|
|
67
|
+
isTarget
|
|
68
|
+
) {
|
|
69
|
+
// @ts-expect-error: apparently it does exist, TS.
|
|
70
|
+
if (process.noDeprecation) {
|
|
71
|
+
return
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
const pjsonPath = fileURLToPath(packageJsonUrl)
|
|
75
|
+
const double = doubleSlashRegEx.exec(isTarget ? target : request) !== null
|
|
76
|
+
process.emitWarning(
|
|
77
|
+
`Use of deprecated ${
|
|
78
|
+
double ? 'double slash' : 'leading or trailing slash matching'
|
|
79
|
+
} resolving "${target}" for module ` +
|
|
80
|
+
`request "${request}" ${
|
|
81
|
+
request === match ? '' : `matched to "${match}" `
|
|
82
|
+
}in the "${
|
|
83
|
+
internal ? 'imports' : 'exports'
|
|
84
|
+
}" field module resolution of the package at ${pjsonPath}${
|
|
85
|
+
base ? ` imported from ${fileURLToPath(base)}` : ''
|
|
86
|
+
}.`,
|
|
87
|
+
'DeprecationWarning',
|
|
88
|
+
'DEP0166'
|
|
89
|
+
)
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* @param {URL} url
|
|
94
|
+
* @param {URL} packageJsonUrl
|
|
95
|
+
* @param {URL} base
|
|
96
|
+
* @param {string} [main]
|
|
97
|
+
* @returns {void}
|
|
98
|
+
*/
|
|
99
|
+
function emitLegacyIndexDeprecation(url, packageJsonUrl, base, main) {
|
|
100
|
+
// @ts-expect-error: apparently it does exist, TS.
|
|
101
|
+
if (process.noDeprecation) {
|
|
102
|
+
return
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
const format = defaultGetFormatWithoutErrors(url, {parentURL: base.href})
|
|
106
|
+
if (format !== 'module') return
|
|
107
|
+
const urlPath = fileURLToPath(url.href)
|
|
108
|
+
const packagePath = fileURLToPath(new URL('.', packageJsonUrl))
|
|
109
|
+
const basePath = fileURLToPath(base)
|
|
110
|
+
if (!main) {
|
|
111
|
+
process.emitWarning(
|
|
112
|
+
`No "main" or "exports" field defined in the package.json for ${packagePath} resolving the main entry point "${urlPath.slice(
|
|
113
|
+
packagePath.length
|
|
114
|
+
)}", imported from ${basePath}.\nDefault "index" lookups for the main are deprecated for ES modules.`,
|
|
115
|
+
'DeprecationWarning',
|
|
116
|
+
'DEP0151'
|
|
117
|
+
)
|
|
118
|
+
} else if (path.resolve(packagePath, main) !== urlPath) {
|
|
119
|
+
process.emitWarning(
|
|
120
|
+
`Package ${packagePath} has a "main" field set to "${main}", ` +
|
|
121
|
+
`excluding the full filename and extension to the resolved file at "${urlPath.slice(
|
|
122
|
+
packagePath.length
|
|
123
|
+
)}", imported from ${basePath}.\n Automatic extension resolution of the "main" field is ` +
|
|
124
|
+
'deprecated for ES modules.',
|
|
125
|
+
'DeprecationWarning',
|
|
126
|
+
'DEP0151'
|
|
127
|
+
)
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* @param {string} path
|
|
133
|
+
* @returns {Stats | undefined}
|
|
134
|
+
*/
|
|
135
|
+
function tryStatSync(path) {
|
|
136
|
+
// Note: from Node 15 onwards we can use `throwIfNoEntry: false` instead.
|
|
137
|
+
try {
|
|
138
|
+
return statSync(path)
|
|
139
|
+
} catch {
|
|
140
|
+
// Note: in Node code this returns `new Stats`,
|
|
141
|
+
// but in Node 22 that’s marked as a deprecated internal API.
|
|
142
|
+
// Which, well, we kinda are, but still to prevent that warning,
|
|
143
|
+
// just yield `undefined`.
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* Legacy CommonJS main resolution:
|
|
149
|
+
* 1. let M = pkg_url + (json main field)
|
|
150
|
+
* 2. TRY(M, M.js, M.json, M.node)
|
|
151
|
+
* 3. TRY(M/index.js, M/index.json, M/index.node)
|
|
152
|
+
* 4. TRY(pkg_url/index.js, pkg_url/index.json, pkg_url/index.node)
|
|
153
|
+
* 5. NOT_FOUND
|
|
154
|
+
*
|
|
155
|
+
* @param {URL} url
|
|
156
|
+
* @returns {boolean}
|
|
157
|
+
*/
|
|
158
|
+
function fileExists(url) {
|
|
159
|
+
const stats = statSync(url, {throwIfNoEntry: false})
|
|
160
|
+
const isFile = stats ? stats.isFile() : undefined
|
|
161
|
+
return isFile === null || isFile === undefined ? false : isFile
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* @param {URL} packageJsonUrl
|
|
166
|
+
* @param {PackageConfig} packageConfig
|
|
167
|
+
* @param {URL} base
|
|
168
|
+
* @returns {URL}
|
|
169
|
+
*/
|
|
170
|
+
function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
171
|
+
/** @type {URL | undefined} */
|
|
172
|
+
let guess
|
|
173
|
+
if (packageConfig.main !== undefined) {
|
|
174
|
+
guess = new URL(packageConfig.main, packageJsonUrl)
|
|
175
|
+
// Note: fs check redundances will be handled by Descriptor cache here.
|
|
176
|
+
if (fileExists(guess)) return guess
|
|
177
|
+
|
|
178
|
+
const tries = [
|
|
179
|
+
`./${packageConfig.main}.js`,
|
|
180
|
+
`./${packageConfig.main}.json`,
|
|
181
|
+
`./${packageConfig.main}.node`,
|
|
182
|
+
`./${packageConfig.main}/index.js`,
|
|
183
|
+
`./${packageConfig.main}/index.json`,
|
|
184
|
+
`./${packageConfig.main}/index.node`
|
|
185
|
+
]
|
|
186
|
+
let i = -1
|
|
187
|
+
|
|
188
|
+
while (++i < tries.length) {
|
|
189
|
+
guess = new URL(tries[i], packageJsonUrl)
|
|
190
|
+
if (fileExists(guess)) break
|
|
191
|
+
guess = undefined
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
if (guess) {
|
|
195
|
+
emitLegacyIndexDeprecation(
|
|
196
|
+
guess,
|
|
197
|
+
packageJsonUrl,
|
|
198
|
+
base,
|
|
199
|
+
packageConfig.main
|
|
200
|
+
)
|
|
201
|
+
return guess
|
|
202
|
+
}
|
|
203
|
+
// Fallthrough.
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
const tries = ['./index.js', './index.json', './index.node']
|
|
207
|
+
let i = -1
|
|
208
|
+
|
|
209
|
+
while (++i < tries.length) {
|
|
210
|
+
guess = new URL(tries[i], packageJsonUrl)
|
|
211
|
+
if (fileExists(guess)) break
|
|
212
|
+
guess = undefined
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
if (guess) {
|
|
216
|
+
emitLegacyIndexDeprecation(guess, packageJsonUrl, base, packageConfig.main)
|
|
217
|
+
return guess
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
// Not found.
|
|
221
|
+
throw new ERR_MODULE_NOT_FOUND(
|
|
222
|
+
fileURLToPath(new URL('.', packageJsonUrl)),
|
|
223
|
+
fileURLToPath(base)
|
|
224
|
+
)
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
/**
|
|
228
|
+
* @param {URL} resolved
|
|
229
|
+
* @param {URL} base
|
|
230
|
+
* @param {boolean} [preserveSymlinks]
|
|
231
|
+
* @returns {URL}
|
|
232
|
+
*/
|
|
233
|
+
function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
234
|
+
if (encodedSeparatorRegEx.exec(resolved.pathname) !== null) {
|
|
235
|
+
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
236
|
+
resolved.pathname,
|
|
237
|
+
'must not include encoded "/" or "\\" characters',
|
|
238
|
+
fileURLToPath(base)
|
|
239
|
+
)
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
/** @type {string} */
|
|
243
|
+
let filePath
|
|
244
|
+
|
|
245
|
+
try {
|
|
246
|
+
filePath = fileURLToPath(resolved)
|
|
247
|
+
} catch (error) {
|
|
248
|
+
const cause = /** @type {ErrnoException} */ (error)
|
|
249
|
+
Object.defineProperty(cause, 'input', {value: String(resolved)})
|
|
250
|
+
Object.defineProperty(cause, 'module', {value: String(base)})
|
|
251
|
+
throw cause
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
const stats = tryStatSync(
|
|
255
|
+
filePath.endsWith('/') ? filePath.slice(-1) : filePath
|
|
256
|
+
)
|
|
257
|
+
|
|
258
|
+
if (stats && stats.isDirectory()) {
|
|
259
|
+
const error = new ERR_UNSUPPORTED_DIR_IMPORT(filePath, fileURLToPath(base))
|
|
260
|
+
// @ts-expect-error Add this for `import.meta.resolve`.
|
|
261
|
+
error.url = String(resolved)
|
|
262
|
+
throw error
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
if (!stats || !stats.isFile()) {
|
|
266
|
+
const error = new ERR_MODULE_NOT_FOUND(
|
|
267
|
+
filePath || resolved.pathname,
|
|
268
|
+
base && fileURLToPath(base),
|
|
269
|
+
true
|
|
270
|
+
)
|
|
271
|
+
// @ts-expect-error Add this for `import.meta.resolve`.
|
|
272
|
+
error.url = String(resolved)
|
|
273
|
+
throw error
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
if (!preserveSymlinks) {
|
|
277
|
+
const real = realpathSync(filePath)
|
|
278
|
+
const {search, hash} = resolved
|
|
279
|
+
resolved = pathToFileURL(real + (filePath.endsWith(path.sep) ? '/' : ''))
|
|
280
|
+
resolved.search = search
|
|
281
|
+
resolved.hash = hash
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
return resolved
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* @param {string} specifier
|
|
289
|
+
* @param {URL | undefined} packageJsonUrl
|
|
290
|
+
* @param {URL} base
|
|
291
|
+
* @returns {Error}
|
|
292
|
+
*/
|
|
293
|
+
function importNotDefined(specifier, packageJsonUrl, base) {
|
|
294
|
+
return new ERR_PACKAGE_IMPORT_NOT_DEFINED(
|
|
295
|
+
specifier,
|
|
296
|
+
packageJsonUrl && fileURLToPath(new URL('.', packageJsonUrl)),
|
|
297
|
+
fileURLToPath(base)
|
|
298
|
+
)
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
/**
|
|
302
|
+
* @param {string} subpath
|
|
303
|
+
* @param {URL} packageJsonUrl
|
|
304
|
+
* @param {URL} base
|
|
305
|
+
* @returns {Error}
|
|
306
|
+
*/
|
|
307
|
+
function exportsNotFound(subpath, packageJsonUrl, base) {
|
|
308
|
+
return new ERR_PACKAGE_PATH_NOT_EXPORTED(
|
|
309
|
+
fileURLToPath(new URL('.', packageJsonUrl)),
|
|
310
|
+
subpath,
|
|
311
|
+
base && fileURLToPath(base)
|
|
312
|
+
)
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
/**
|
|
316
|
+
* @param {string} request
|
|
317
|
+
* @param {string} match
|
|
318
|
+
* @param {URL} packageJsonUrl
|
|
319
|
+
* @param {boolean} internal
|
|
320
|
+
* @param {URL} [base]
|
|
321
|
+
* @returns {never}
|
|
322
|
+
*/
|
|
323
|
+
function throwInvalidSubpath(request, match, packageJsonUrl, internal, base) {
|
|
324
|
+
const reason = `request is not a valid match in pattern "${match}" for the "${
|
|
325
|
+
internal ? 'imports' : 'exports'
|
|
326
|
+
}" resolution of ${fileURLToPath(packageJsonUrl)}`
|
|
327
|
+
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
328
|
+
request,
|
|
329
|
+
reason,
|
|
330
|
+
base && fileURLToPath(base)
|
|
331
|
+
)
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
/**
|
|
335
|
+
* @param {string} subpath
|
|
336
|
+
* @param {unknown} target
|
|
337
|
+
* @param {URL} packageJsonUrl
|
|
338
|
+
* @param {boolean} internal
|
|
339
|
+
* @param {URL} [base]
|
|
340
|
+
* @returns {Error}
|
|
341
|
+
*/
|
|
342
|
+
function invalidPackageTarget(subpath, target, packageJsonUrl, internal, base) {
|
|
343
|
+
target =
|
|
344
|
+
typeof target === 'object' && target !== null
|
|
345
|
+
? JSON.stringify(target, null, '')
|
|
346
|
+
: `${target}`
|
|
347
|
+
|
|
348
|
+
return new ERR_INVALID_PACKAGE_TARGET(
|
|
349
|
+
fileURLToPath(new URL('.', packageJsonUrl)),
|
|
350
|
+
subpath,
|
|
351
|
+
target,
|
|
352
|
+
internal,
|
|
353
|
+
base && fileURLToPath(base)
|
|
354
|
+
)
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
/**
|
|
358
|
+
* @param {string} target
|
|
359
|
+
* @param {string} subpath
|
|
360
|
+
* @param {string} match
|
|
361
|
+
* @param {URL} packageJsonUrl
|
|
362
|
+
* @param {URL} base
|
|
363
|
+
* @param {boolean} pattern
|
|
364
|
+
* @param {boolean} internal
|
|
365
|
+
* @param {boolean} isPathMap
|
|
366
|
+
* @param {Set<string> | undefined} conditions
|
|
367
|
+
* @returns {URL}
|
|
368
|
+
*/
|
|
369
|
+
function resolvePackageTargetString(
|
|
370
|
+
target,
|
|
371
|
+
subpath,
|
|
372
|
+
match,
|
|
373
|
+
packageJsonUrl,
|
|
374
|
+
base,
|
|
375
|
+
pattern,
|
|
376
|
+
internal,
|
|
377
|
+
isPathMap,
|
|
378
|
+
conditions
|
|
379
|
+
) {
|
|
380
|
+
if (subpath !== '' && !pattern && target[target.length - 1] !== '/')
|
|
381
|
+
throw invalidPackageTarget(match, target, packageJsonUrl, internal, base)
|
|
382
|
+
|
|
383
|
+
if (!target.startsWith('./')) {
|
|
384
|
+
if (internal && !target.startsWith('../') && !target.startsWith('/')) {
|
|
385
|
+
let isURL = false
|
|
386
|
+
|
|
387
|
+
try {
|
|
388
|
+
new URL(target)
|
|
389
|
+
isURL = true
|
|
390
|
+
} catch {
|
|
391
|
+
// Continue regardless of error.
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
if (!isURL) {
|
|
395
|
+
const exportTarget = pattern
|
|
396
|
+
? RegExpPrototypeSymbolReplace.call(
|
|
397
|
+
patternRegEx,
|
|
398
|
+
target,
|
|
399
|
+
() => subpath
|
|
400
|
+
)
|
|
401
|
+
: target + subpath
|
|
402
|
+
|
|
403
|
+
return packageResolve(exportTarget, packageJsonUrl, conditions)
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
throw invalidPackageTarget(match, target, packageJsonUrl, internal, base)
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
if (invalidSegmentRegEx.exec(target.slice(2)) !== null) {
|
|
411
|
+
if (deprecatedInvalidSegmentRegEx.exec(target.slice(2)) === null) {
|
|
412
|
+
if (!isPathMap) {
|
|
413
|
+
const request = pattern
|
|
414
|
+
? match.replace('*', () => subpath)
|
|
415
|
+
: match + subpath
|
|
416
|
+
const resolvedTarget = pattern
|
|
417
|
+
? RegExpPrototypeSymbolReplace.call(
|
|
418
|
+
patternRegEx,
|
|
419
|
+
target,
|
|
420
|
+
() => subpath
|
|
421
|
+
)
|
|
422
|
+
: target
|
|
423
|
+
emitInvalidSegmentDeprecation(
|
|
424
|
+
resolvedTarget,
|
|
425
|
+
request,
|
|
426
|
+
match,
|
|
427
|
+
packageJsonUrl,
|
|
428
|
+
internal,
|
|
429
|
+
base,
|
|
430
|
+
true
|
|
431
|
+
)
|
|
432
|
+
}
|
|
433
|
+
} else {
|
|
434
|
+
throw invalidPackageTarget(match, target, packageJsonUrl, internal, base)
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
const resolved = new URL(target, packageJsonUrl)
|
|
439
|
+
const resolvedPath = resolved.pathname
|
|
440
|
+
const packagePath = new URL('.', packageJsonUrl).pathname
|
|
441
|
+
|
|
442
|
+
if (!resolvedPath.startsWith(packagePath))
|
|
443
|
+
throw invalidPackageTarget(match, target, packageJsonUrl, internal, base)
|
|
444
|
+
|
|
445
|
+
if (subpath === '') return resolved
|
|
446
|
+
|
|
447
|
+
if (invalidSegmentRegEx.exec(subpath) !== null) {
|
|
448
|
+
const request = pattern
|
|
449
|
+
? match.replace('*', () => subpath)
|
|
450
|
+
: match + subpath
|
|
451
|
+
if (deprecatedInvalidSegmentRegEx.exec(subpath) === null) {
|
|
452
|
+
if (!isPathMap) {
|
|
453
|
+
const resolvedTarget = pattern
|
|
454
|
+
? RegExpPrototypeSymbolReplace.call(
|
|
455
|
+
patternRegEx,
|
|
456
|
+
target,
|
|
457
|
+
() => subpath
|
|
458
|
+
)
|
|
459
|
+
: target
|
|
460
|
+
emitInvalidSegmentDeprecation(
|
|
461
|
+
resolvedTarget,
|
|
462
|
+
request,
|
|
463
|
+
match,
|
|
464
|
+
packageJsonUrl,
|
|
465
|
+
internal,
|
|
466
|
+
base,
|
|
467
|
+
false
|
|
468
|
+
)
|
|
469
|
+
}
|
|
470
|
+
} else {
|
|
471
|
+
throwInvalidSubpath(request, match, packageJsonUrl, internal, base)
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
if (pattern) {
|
|
476
|
+
return new URL(
|
|
477
|
+
RegExpPrototypeSymbolReplace.call(
|
|
478
|
+
patternRegEx,
|
|
479
|
+
resolved.href,
|
|
480
|
+
() => subpath
|
|
481
|
+
)
|
|
482
|
+
)
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
return new URL(subpath, resolved)
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
/**
|
|
489
|
+
* @param {string} key
|
|
490
|
+
* @returns {boolean}
|
|
491
|
+
*/
|
|
492
|
+
function isArrayIndex(key) {
|
|
493
|
+
const keyNumber = Number(key)
|
|
494
|
+
if (`${keyNumber}` !== key) return false
|
|
495
|
+
return keyNumber >= 0 && keyNumber < 0xff_ff_ff_ff
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
/**
|
|
499
|
+
* @param {URL} packageJsonUrl
|
|
500
|
+
* @param {unknown} target
|
|
501
|
+
* @param {string} subpath
|
|
502
|
+
* @param {string} packageSubpath
|
|
503
|
+
* @param {URL} base
|
|
504
|
+
* @param {boolean} pattern
|
|
505
|
+
* @param {boolean} internal
|
|
506
|
+
* @param {boolean} isPathMap
|
|
507
|
+
* @param {Set<string> | undefined} conditions
|
|
508
|
+
* @returns {URL | null}
|
|
509
|
+
*/
|
|
510
|
+
function resolvePackageTarget(
|
|
511
|
+
packageJsonUrl,
|
|
512
|
+
target,
|
|
513
|
+
subpath,
|
|
514
|
+
packageSubpath,
|
|
515
|
+
base,
|
|
516
|
+
pattern,
|
|
517
|
+
internal,
|
|
518
|
+
isPathMap,
|
|
519
|
+
conditions
|
|
520
|
+
) {
|
|
521
|
+
if (typeof target === 'string') {
|
|
522
|
+
return resolvePackageTargetString(
|
|
523
|
+
target,
|
|
524
|
+
subpath,
|
|
525
|
+
packageSubpath,
|
|
526
|
+
packageJsonUrl,
|
|
527
|
+
base,
|
|
528
|
+
pattern,
|
|
529
|
+
internal,
|
|
530
|
+
isPathMap,
|
|
531
|
+
conditions
|
|
532
|
+
)
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
if (Array.isArray(target)) {
|
|
536
|
+
/** @type {Array<unknown>} */
|
|
537
|
+
const targetList = target
|
|
538
|
+
if (targetList.length === 0) return null
|
|
539
|
+
|
|
540
|
+
/** @type {ErrnoException | null | undefined} */
|
|
541
|
+
let lastException
|
|
542
|
+
let i = -1
|
|
543
|
+
|
|
544
|
+
while (++i < targetList.length) {
|
|
545
|
+
const targetItem = targetList[i]
|
|
546
|
+
/** @type {URL | null} */
|
|
547
|
+
let resolveResult
|
|
548
|
+
try {
|
|
549
|
+
resolveResult = resolvePackageTarget(
|
|
550
|
+
packageJsonUrl,
|
|
551
|
+
targetItem,
|
|
552
|
+
subpath,
|
|
553
|
+
packageSubpath,
|
|
554
|
+
base,
|
|
555
|
+
pattern,
|
|
556
|
+
internal,
|
|
557
|
+
isPathMap,
|
|
558
|
+
conditions
|
|
559
|
+
)
|
|
560
|
+
} catch (error) {
|
|
561
|
+
const exception = /** @type {ErrnoException} */ (error)
|
|
562
|
+
lastException = exception
|
|
563
|
+
if (exception.code === 'ERR_INVALID_PACKAGE_TARGET') continue
|
|
564
|
+
throw error
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
if (resolveResult === undefined) continue
|
|
568
|
+
|
|
569
|
+
if (resolveResult === null) {
|
|
570
|
+
lastException = null
|
|
571
|
+
continue
|
|
572
|
+
}
|
|
573
|
+
|
|
574
|
+
return resolveResult
|
|
575
|
+
}
|
|
576
|
+
|
|
577
|
+
if (lastException === undefined || lastException === null) {
|
|
578
|
+
return null
|
|
579
|
+
}
|
|
580
|
+
|
|
581
|
+
throw lastException
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
if (typeof target === 'object' && target !== null) {
|
|
585
|
+
const keys = Object.getOwnPropertyNames(target)
|
|
586
|
+
let i = -1
|
|
587
|
+
|
|
588
|
+
while (++i < keys.length) {
|
|
589
|
+
const key = keys[i]
|
|
590
|
+
if (isArrayIndex(key)) {
|
|
591
|
+
throw new ERR_INVALID_PACKAGE_CONFIG(
|
|
592
|
+
fileURLToPath(packageJsonUrl),
|
|
593
|
+
base,
|
|
594
|
+
'"exports" cannot contain numeric property keys.'
|
|
595
|
+
)
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
i = -1
|
|
600
|
+
|
|
601
|
+
while (++i < keys.length) {
|
|
602
|
+
const key = keys[i]
|
|
603
|
+
if (key === 'default' || (conditions && conditions.has(key))) {
|
|
604
|
+
// @ts-expect-error: indexable.
|
|
605
|
+
const conditionalTarget = /** @type {unknown} */ (target[key])
|
|
606
|
+
const resolveResult = resolvePackageTarget(
|
|
607
|
+
packageJsonUrl,
|
|
608
|
+
conditionalTarget,
|
|
609
|
+
subpath,
|
|
610
|
+
packageSubpath,
|
|
611
|
+
base,
|
|
612
|
+
pattern,
|
|
613
|
+
internal,
|
|
614
|
+
isPathMap,
|
|
615
|
+
conditions
|
|
616
|
+
)
|
|
617
|
+
if (resolveResult === undefined) continue
|
|
618
|
+
return resolveResult
|
|
619
|
+
}
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
return null
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
if (target === null) {
|
|
626
|
+
return null
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
throw invalidPackageTarget(
|
|
630
|
+
packageSubpath,
|
|
631
|
+
target,
|
|
632
|
+
packageJsonUrl,
|
|
633
|
+
internal,
|
|
634
|
+
base
|
|
635
|
+
)
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
/**
|
|
639
|
+
* @param {unknown} exports
|
|
640
|
+
* @param {URL} packageJsonUrl
|
|
641
|
+
* @param {URL} base
|
|
642
|
+
* @returns {boolean}
|
|
643
|
+
*/
|
|
644
|
+
function isConditionalExportsMainSugar(exports, packageJsonUrl, base) {
|
|
645
|
+
if (typeof exports === 'string' || Array.isArray(exports)) return true
|
|
646
|
+
if (typeof exports !== 'object' || exports === null) return false
|
|
647
|
+
|
|
648
|
+
const keys = Object.getOwnPropertyNames(exports)
|
|
649
|
+
let isConditionalSugar = false
|
|
650
|
+
let i = 0
|
|
651
|
+
let keyIndex = -1
|
|
652
|
+
while (++keyIndex < keys.length) {
|
|
653
|
+
const key = keys[keyIndex]
|
|
654
|
+
const currentIsConditionalSugar = key === '' || key[0] !== '.'
|
|
655
|
+
if (i++ === 0) {
|
|
656
|
+
isConditionalSugar = currentIsConditionalSugar
|
|
657
|
+
} else if (isConditionalSugar !== currentIsConditionalSugar) {
|
|
658
|
+
throw new ERR_INVALID_PACKAGE_CONFIG(
|
|
659
|
+
fileURLToPath(packageJsonUrl),
|
|
660
|
+
base,
|
|
661
|
+
'"exports" cannot contain some keys starting with \'.\' and some not.' +
|
|
662
|
+
' The exports object must either be an object of package subpath keys' +
|
|
663
|
+
' or an object of main entry condition name keys only.'
|
|
664
|
+
)
|
|
665
|
+
}
|
|
666
|
+
}
|
|
667
|
+
|
|
668
|
+
return isConditionalSugar
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
/**
|
|
672
|
+
* @param {string} match
|
|
673
|
+
* @param {URL} pjsonUrl
|
|
674
|
+
* @param {URL} base
|
|
675
|
+
*/
|
|
676
|
+
function emitTrailingSlashPatternDeprecation(match, pjsonUrl, base) {
|
|
677
|
+
// @ts-expect-error: apparently it does exist, TS.
|
|
678
|
+
if (process.noDeprecation) {
|
|
679
|
+
return
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
const pjsonPath = fileURLToPath(pjsonUrl)
|
|
683
|
+
if (emittedPackageWarnings.has(pjsonPath + '|' + match)) return
|
|
684
|
+
emittedPackageWarnings.add(pjsonPath + '|' + match)
|
|
685
|
+
process.emitWarning(
|
|
686
|
+
`Use of deprecated trailing slash pattern mapping "${match}" in the ` +
|
|
687
|
+
`"exports" field module resolution of the package at ${pjsonPath}${
|
|
688
|
+
base ? ` imported from ${fileURLToPath(base)}` : ''
|
|
689
|
+
}. Mapping specifiers ending in "/" is no longer supported.`,
|
|
690
|
+
'DeprecationWarning',
|
|
691
|
+
'DEP0155'
|
|
692
|
+
)
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
/**
|
|
696
|
+
* @param {URL} packageJsonUrl
|
|
697
|
+
* @param {string} packageSubpath
|
|
698
|
+
* @param {Record<string, unknown>} packageConfig
|
|
699
|
+
* @param {URL} base
|
|
700
|
+
* @param {Set<string> | undefined} conditions
|
|
701
|
+
* @returns {URL}
|
|
702
|
+
*/
|
|
703
|
+
function packageExportsResolve(
|
|
704
|
+
packageJsonUrl,
|
|
705
|
+
packageSubpath,
|
|
706
|
+
packageConfig,
|
|
707
|
+
base,
|
|
708
|
+
conditions
|
|
709
|
+
) {
|
|
710
|
+
let exports = packageConfig.exports
|
|
711
|
+
|
|
712
|
+
if (isConditionalExportsMainSugar(exports, packageJsonUrl, base)) {
|
|
713
|
+
exports = {'.': exports}
|
|
714
|
+
}
|
|
715
|
+
|
|
716
|
+
if (
|
|
717
|
+
own.call(exports, packageSubpath) &&
|
|
718
|
+
!packageSubpath.includes('*') &&
|
|
719
|
+
!packageSubpath.endsWith('/')
|
|
720
|
+
) {
|
|
721
|
+
// @ts-expect-error: indexable.
|
|
722
|
+
const target = exports[packageSubpath]
|
|
723
|
+
const resolveResult = resolvePackageTarget(
|
|
724
|
+
packageJsonUrl,
|
|
725
|
+
target,
|
|
726
|
+
'',
|
|
727
|
+
packageSubpath,
|
|
728
|
+
base,
|
|
729
|
+
false,
|
|
730
|
+
false,
|
|
731
|
+
false,
|
|
732
|
+
conditions
|
|
733
|
+
)
|
|
734
|
+
if (resolveResult === null || resolveResult === undefined) {
|
|
735
|
+
throw exportsNotFound(packageSubpath, packageJsonUrl, base)
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
return resolveResult
|
|
739
|
+
}
|
|
740
|
+
|
|
741
|
+
let bestMatch = ''
|
|
742
|
+
let bestMatchSubpath = ''
|
|
743
|
+
const keys = Object.getOwnPropertyNames(exports)
|
|
744
|
+
let i = -1
|
|
745
|
+
|
|
746
|
+
while (++i < keys.length) {
|
|
747
|
+
const key = keys[i]
|
|
748
|
+
const patternIndex = key.indexOf('*')
|
|
749
|
+
|
|
750
|
+
if (
|
|
751
|
+
patternIndex !== -1 &&
|
|
752
|
+
packageSubpath.startsWith(key.slice(0, patternIndex))
|
|
753
|
+
) {
|
|
754
|
+
// When this reaches EOL, this can throw at the top of the whole function:
|
|
755
|
+
//
|
|
756
|
+
// if (StringPrototypeEndsWith(packageSubpath, '/'))
|
|
757
|
+
// throwInvalidSubpath(packageSubpath)
|
|
758
|
+
//
|
|
759
|
+
// To match "imports" and the spec.
|
|
760
|
+
if (packageSubpath.endsWith('/')) {
|
|
761
|
+
emitTrailingSlashPatternDeprecation(
|
|
762
|
+
packageSubpath,
|
|
763
|
+
packageJsonUrl,
|
|
764
|
+
base
|
|
765
|
+
)
|
|
766
|
+
}
|
|
767
|
+
|
|
768
|
+
const patternTrailer = key.slice(patternIndex + 1)
|
|
769
|
+
|
|
770
|
+
if (
|
|
771
|
+
packageSubpath.length >= key.length &&
|
|
772
|
+
packageSubpath.endsWith(patternTrailer) &&
|
|
773
|
+
patternKeyCompare(bestMatch, key) === 1 &&
|
|
774
|
+
key.lastIndexOf('*') === patternIndex
|
|
775
|
+
) {
|
|
776
|
+
bestMatch = key
|
|
777
|
+
bestMatchSubpath = packageSubpath.slice(
|
|
778
|
+
patternIndex,
|
|
779
|
+
packageSubpath.length - patternTrailer.length
|
|
780
|
+
)
|
|
781
|
+
}
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
|
|
785
|
+
if (bestMatch) {
|
|
786
|
+
// @ts-expect-error: indexable.
|
|
787
|
+
const target = /** @type {unknown} */ (exports[bestMatch])
|
|
788
|
+
const resolveResult = resolvePackageTarget(
|
|
789
|
+
packageJsonUrl,
|
|
790
|
+
target,
|
|
791
|
+
bestMatchSubpath,
|
|
792
|
+
bestMatch,
|
|
793
|
+
base,
|
|
794
|
+
true,
|
|
795
|
+
false,
|
|
796
|
+
packageSubpath.endsWith('/'),
|
|
797
|
+
conditions
|
|
798
|
+
)
|
|
799
|
+
|
|
800
|
+
if (resolveResult === null || resolveResult === undefined) {
|
|
801
|
+
throw exportsNotFound(packageSubpath, packageJsonUrl, base)
|
|
802
|
+
}
|
|
803
|
+
|
|
804
|
+
return resolveResult
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
throw exportsNotFound(packageSubpath, packageJsonUrl, base)
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
/**
|
|
811
|
+
* @param {string} a
|
|
812
|
+
* @param {string} b
|
|
813
|
+
*/
|
|
814
|
+
function patternKeyCompare(a, b) {
|
|
815
|
+
const aPatternIndex = a.indexOf('*')
|
|
816
|
+
const bPatternIndex = b.indexOf('*')
|
|
817
|
+
const baseLengthA = aPatternIndex === -1 ? a.length : aPatternIndex + 1
|
|
818
|
+
const baseLengthB = bPatternIndex === -1 ? b.length : bPatternIndex + 1
|
|
819
|
+
if (baseLengthA > baseLengthB) return -1
|
|
820
|
+
if (baseLengthB > baseLengthA) return 1
|
|
821
|
+
if (aPatternIndex === -1) return 1
|
|
822
|
+
if (bPatternIndex === -1) return -1
|
|
823
|
+
if (a.length > b.length) return -1
|
|
824
|
+
if (b.length > a.length) return 1
|
|
825
|
+
return 0
|
|
826
|
+
}
|
|
827
|
+
|
|
828
|
+
/**
|
|
829
|
+
* @param {string} name
|
|
830
|
+
* @param {URL} base
|
|
831
|
+
* @param {Set<string>} [conditions]
|
|
832
|
+
* @returns {URL}
|
|
833
|
+
*/
|
|
834
|
+
function packageImportsResolve(name, base, conditions) {
|
|
835
|
+
if (name === '#' || name.startsWith('#/') || name.endsWith('/')) {
|
|
836
|
+
const reason = 'is not a valid internal imports specifier name'
|
|
837
|
+
throw new ERR_INVALID_MODULE_SPECIFIER(name, reason, fileURLToPath(base))
|
|
838
|
+
}
|
|
839
|
+
|
|
840
|
+
/** @type {URL | undefined} */
|
|
841
|
+
let packageJsonUrl
|
|
842
|
+
|
|
843
|
+
const packageConfig = getPackageScopeConfig(base)
|
|
844
|
+
|
|
845
|
+
if (packageConfig.exists) {
|
|
846
|
+
packageJsonUrl = pathToFileURL(packageConfig.pjsonPath)
|
|
847
|
+
const imports = packageConfig.imports
|
|
848
|
+
if (imports) {
|
|
849
|
+
if (own.call(imports, name) && !name.includes('*')) {
|
|
850
|
+
const resolveResult = resolvePackageTarget(
|
|
851
|
+
packageJsonUrl,
|
|
852
|
+
imports[name],
|
|
853
|
+
'',
|
|
854
|
+
name,
|
|
855
|
+
base,
|
|
856
|
+
false,
|
|
857
|
+
true,
|
|
858
|
+
false,
|
|
859
|
+
conditions
|
|
860
|
+
)
|
|
861
|
+
if (resolveResult !== null && resolveResult !== undefined) {
|
|
862
|
+
return resolveResult
|
|
863
|
+
}
|
|
864
|
+
} else {
|
|
865
|
+
let bestMatch = ''
|
|
866
|
+
let bestMatchSubpath = ''
|
|
867
|
+
const keys = Object.getOwnPropertyNames(imports)
|
|
868
|
+
let i = -1
|
|
869
|
+
|
|
870
|
+
while (++i < keys.length) {
|
|
871
|
+
const key = keys[i]
|
|
872
|
+
const patternIndex = key.indexOf('*')
|
|
873
|
+
|
|
874
|
+
if (patternIndex !== -1 && name.startsWith(key.slice(0, -1))) {
|
|
875
|
+
const patternTrailer = key.slice(patternIndex + 1)
|
|
876
|
+
if (
|
|
877
|
+
name.length >= key.length &&
|
|
878
|
+
name.endsWith(patternTrailer) &&
|
|
879
|
+
patternKeyCompare(bestMatch, key) === 1 &&
|
|
880
|
+
key.lastIndexOf('*') === patternIndex
|
|
881
|
+
) {
|
|
882
|
+
bestMatch = key
|
|
883
|
+
bestMatchSubpath = name.slice(
|
|
884
|
+
patternIndex,
|
|
885
|
+
name.length - patternTrailer.length
|
|
886
|
+
)
|
|
887
|
+
}
|
|
888
|
+
}
|
|
889
|
+
}
|
|
890
|
+
|
|
891
|
+
if (bestMatch) {
|
|
892
|
+
const target = imports[bestMatch]
|
|
893
|
+
const resolveResult = resolvePackageTarget(
|
|
894
|
+
packageJsonUrl,
|
|
895
|
+
target,
|
|
896
|
+
bestMatchSubpath,
|
|
897
|
+
bestMatch,
|
|
898
|
+
base,
|
|
899
|
+
true,
|
|
900
|
+
true,
|
|
901
|
+
false,
|
|
902
|
+
conditions
|
|
903
|
+
)
|
|
904
|
+
|
|
905
|
+
if (resolveResult !== null && resolveResult !== undefined) {
|
|
906
|
+
return resolveResult
|
|
907
|
+
}
|
|
908
|
+
}
|
|
909
|
+
}
|
|
910
|
+
}
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
throw importNotDefined(name, packageJsonUrl, base)
|
|
914
|
+
}
|
|
915
|
+
|
|
916
|
+
/**
|
|
917
|
+
* @param {string} specifier
|
|
918
|
+
* @param {URL} base
|
|
919
|
+
*/
|
|
920
|
+
function parsePackageName(specifier, base) {
|
|
921
|
+
let separatorIndex = specifier.indexOf('/')
|
|
922
|
+
let validPackageName = true
|
|
923
|
+
let isScoped = false
|
|
924
|
+
if (specifier[0] === '@') {
|
|
925
|
+
isScoped = true
|
|
926
|
+
if (separatorIndex === -1 || specifier.length === 0) {
|
|
927
|
+
validPackageName = false
|
|
928
|
+
} else {
|
|
929
|
+
separatorIndex = specifier.indexOf('/', separatorIndex + 1)
|
|
930
|
+
}
|
|
931
|
+
}
|
|
932
|
+
|
|
933
|
+
const packageName =
|
|
934
|
+
separatorIndex === -1 ? specifier : specifier.slice(0, separatorIndex)
|
|
935
|
+
|
|
936
|
+
// Package name cannot have leading . and cannot have percent-encoding or
|
|
937
|
+
// \\ separators.
|
|
938
|
+
if (invalidPackageNameRegEx.exec(packageName) !== null) {
|
|
939
|
+
validPackageName = false
|
|
940
|
+
}
|
|
941
|
+
|
|
942
|
+
if (!validPackageName) {
|
|
943
|
+
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
944
|
+
specifier,
|
|
945
|
+
'is not a valid package name',
|
|
946
|
+
fileURLToPath(base)
|
|
947
|
+
)
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
const packageSubpath =
|
|
951
|
+
'.' + (separatorIndex === -1 ? '' : specifier.slice(separatorIndex))
|
|
952
|
+
|
|
953
|
+
return {packageName, packageSubpath, isScoped}
|
|
954
|
+
}
|
|
955
|
+
|
|
956
|
+
/**
|
|
957
|
+
* @param {string} specifier
|
|
958
|
+
* @param {URL} base
|
|
959
|
+
* @param {Set<string> | undefined} conditions
|
|
960
|
+
* @returns {URL}
|
|
961
|
+
*/
|
|
962
|
+
function packageResolve(specifier, base, conditions) {
|
|
963
|
+
if (builtinModules.includes(specifier)) {
|
|
964
|
+
return new URL('node:' + specifier)
|
|
965
|
+
}
|
|
966
|
+
|
|
967
|
+
const {packageName, packageSubpath, isScoped} = parsePackageName(
|
|
968
|
+
specifier,
|
|
969
|
+
base
|
|
970
|
+
)
|
|
971
|
+
|
|
972
|
+
// ResolveSelf
|
|
973
|
+
const packageConfig = getPackageScopeConfig(base)
|
|
974
|
+
|
|
975
|
+
// Can’t test.
|
|
976
|
+
/* c8 ignore next 16 */
|
|
977
|
+
if (packageConfig.exists) {
|
|
978
|
+
const packageJsonUrl = pathToFileURL(packageConfig.pjsonPath)
|
|
979
|
+
if (
|
|
980
|
+
packageConfig.name === packageName &&
|
|
981
|
+
packageConfig.exports !== undefined &&
|
|
982
|
+
packageConfig.exports !== null
|
|
983
|
+
) {
|
|
984
|
+
return packageExportsResolve(
|
|
985
|
+
packageJsonUrl,
|
|
986
|
+
packageSubpath,
|
|
987
|
+
packageConfig,
|
|
988
|
+
base,
|
|
989
|
+
conditions
|
|
990
|
+
)
|
|
991
|
+
}
|
|
992
|
+
}
|
|
993
|
+
|
|
994
|
+
let packageJsonUrl = new URL(
|
|
995
|
+
'./node_modules/' + packageName + '/package.json',
|
|
996
|
+
base
|
|
997
|
+
)
|
|
998
|
+
let packageJsonPath = fileURLToPath(packageJsonUrl)
|
|
999
|
+
/** @type {string} */
|
|
1000
|
+
let lastPath
|
|
1001
|
+
do {
|
|
1002
|
+
const stat = tryStatSync(packageJsonPath.slice(0, -13))
|
|
1003
|
+
if (!stat || !stat.isDirectory()) {
|
|
1004
|
+
lastPath = packageJsonPath
|
|
1005
|
+
packageJsonUrl = new URL(
|
|
1006
|
+
(isScoped ? '../../../../node_modules/' : '../../../node_modules/') +
|
|
1007
|
+
packageName +
|
|
1008
|
+
'/package.json',
|
|
1009
|
+
packageJsonUrl
|
|
1010
|
+
)
|
|
1011
|
+
packageJsonPath = fileURLToPath(packageJsonUrl)
|
|
1012
|
+
continue
|
|
1013
|
+
}
|
|
1014
|
+
|
|
1015
|
+
// Package match.
|
|
1016
|
+
const packageConfig = read(packageJsonPath, {base, specifier})
|
|
1017
|
+
if (packageConfig.exports !== undefined && packageConfig.exports !== null) {
|
|
1018
|
+
return packageExportsResolve(
|
|
1019
|
+
packageJsonUrl,
|
|
1020
|
+
packageSubpath,
|
|
1021
|
+
packageConfig,
|
|
1022
|
+
base,
|
|
1023
|
+
conditions
|
|
1024
|
+
)
|
|
1025
|
+
}
|
|
1026
|
+
|
|
1027
|
+
if (packageSubpath === '.') {
|
|
1028
|
+
return legacyMainResolve(packageJsonUrl, packageConfig, base)
|
|
1029
|
+
}
|
|
1030
|
+
|
|
1031
|
+
return new URL(packageSubpath, packageJsonUrl)
|
|
1032
|
+
// Cross-platform root check.
|
|
1033
|
+
} while (packageJsonPath.length !== lastPath.length)
|
|
1034
|
+
|
|
1035
|
+
throw new ERR_MODULE_NOT_FOUND(packageName, fileURLToPath(base), false)
|
|
1036
|
+
}
|
|
1037
|
+
|
|
1038
|
+
/**
|
|
1039
|
+
* @param {string} specifier
|
|
1040
|
+
* @returns {boolean}
|
|
1041
|
+
*/
|
|
1042
|
+
function isRelativeSpecifier(specifier) {
|
|
1043
|
+
if (specifier[0] === '.') {
|
|
1044
|
+
if (specifier.length === 1 || specifier[1] === '/') return true
|
|
1045
|
+
if (
|
|
1046
|
+
specifier[1] === '.' &&
|
|
1047
|
+
(specifier.length === 2 || specifier[2] === '/')
|
|
1048
|
+
) {
|
|
1049
|
+
return true
|
|
1050
|
+
}
|
|
1051
|
+
}
|
|
1052
|
+
|
|
1053
|
+
return false
|
|
1054
|
+
}
|
|
1055
|
+
|
|
1056
|
+
/**
|
|
1057
|
+
* @param {string} specifier
|
|
1058
|
+
* @returns {boolean}
|
|
1059
|
+
*/
|
|
1060
|
+
function shouldBeTreatedAsRelativeOrAbsolutePath(specifier) {
|
|
1061
|
+
if (specifier === '') return false
|
|
1062
|
+
if (specifier[0] === '/') return true
|
|
1063
|
+
return isRelativeSpecifier(specifier)
|
|
1064
|
+
}
|
|
1065
|
+
|
|
1066
|
+
/**
|
|
1067
|
+
* The “Resolver Algorithm Specification” as detailed in the Node docs (which is
|
|
1068
|
+
* sync and slightly lower-level than `resolve`).
|
|
1069
|
+
*
|
|
1070
|
+
* @param {string} specifier
|
|
1071
|
+
* `/example.js`, `./example.js`, `../example.js`, `some-package`, `fs`, etc.
|
|
1072
|
+
* @param {URL} base
|
|
1073
|
+
* Full URL (to a file) that `specifier` is resolved relative from.
|
|
1074
|
+
* @param {Set<string>} [conditions]
|
|
1075
|
+
* Conditions.
|
|
1076
|
+
* @param {boolean} [preserveSymlinks]
|
|
1077
|
+
* Keep symlinks instead of resolving them.
|
|
1078
|
+
* @returns {URL}
|
|
1079
|
+
* A URL object to the found thing.
|
|
1080
|
+
*/
|
|
1081
|
+
export function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
1082
|
+
// Note: The Node code supports `base` as a string (in this internal API) too,
|
|
1083
|
+
// we don’t.
|
|
1084
|
+
if (conditions === undefined) {
|
|
1085
|
+
conditions = getConditionsSet()
|
|
1086
|
+
}
|
|
1087
|
+
|
|
1088
|
+
const protocol = base.protocol
|
|
1089
|
+
const isData = protocol === 'data:'
|
|
1090
|
+
const isRemote = isData || protocol === 'http:' || protocol === 'https:'
|
|
1091
|
+
// Order swapped from spec for minor perf gain.
|
|
1092
|
+
// Ok since relative URLs cannot parse as URLs.
|
|
1093
|
+
/** @type {URL | undefined} */
|
|
1094
|
+
let resolved
|
|
1095
|
+
|
|
1096
|
+
if (shouldBeTreatedAsRelativeOrAbsolutePath(specifier)) {
|
|
1097
|
+
try {
|
|
1098
|
+
resolved = new URL(specifier, base)
|
|
1099
|
+
} catch (error_) {
|
|
1100
|
+
const error = new ERR_UNSUPPORTED_RESOLVE_REQUEST(specifier, base)
|
|
1101
|
+
error.cause = error_
|
|
1102
|
+
throw error
|
|
1103
|
+
}
|
|
1104
|
+
} else if (protocol === 'file:' && specifier[0] === '#') {
|
|
1105
|
+
resolved = packageImportsResolve(specifier, base, conditions)
|
|
1106
|
+
} else {
|
|
1107
|
+
try {
|
|
1108
|
+
resolved = new URL(specifier)
|
|
1109
|
+
} catch (error_) {
|
|
1110
|
+
// Note: actual code uses `canBeRequiredWithoutScheme`.
|
|
1111
|
+
if (isRemote && !builtinModules.includes(specifier)) {
|
|
1112
|
+
const error = new ERR_UNSUPPORTED_RESOLVE_REQUEST(specifier, base)
|
|
1113
|
+
error.cause = error_
|
|
1114
|
+
throw error
|
|
1115
|
+
}
|
|
1116
|
+
|
|
1117
|
+
resolved = packageResolve(specifier, base, conditions)
|
|
1118
|
+
}
|
|
1119
|
+
}
|
|
1120
|
+
|
|
1121
|
+
assert.ok(resolved !== undefined, 'expected to be defined')
|
|
1122
|
+
|
|
1123
|
+
if (resolved.protocol !== 'file:') {
|
|
1124
|
+
return resolved
|
|
1125
|
+
}
|
|
1126
|
+
|
|
1127
|
+
return finalizeResolution(resolved, base, preserveSymlinks)
|
|
1128
|
+
}
|
|
1129
|
+
|
|
1130
|
+
/**
|
|
1131
|
+
* @param {string} specifier
|
|
1132
|
+
* @param {URL | undefined} parsed
|
|
1133
|
+
* @param {URL | undefined} parsedParentURL
|
|
1134
|
+
*/
|
|
1135
|
+
function checkIfDisallowedImport(specifier, parsed, parsedParentURL) {
|
|
1136
|
+
if (parsedParentURL) {
|
|
1137
|
+
// Avoid accessing the `protocol` property due to the lazy getters.
|
|
1138
|
+
const parentProtocol = parsedParentURL.protocol
|
|
1139
|
+
|
|
1140
|
+
if (parentProtocol === 'http:' || parentProtocol === 'https:') {
|
|
1141
|
+
if (shouldBeTreatedAsRelativeOrAbsolutePath(specifier)) {
|
|
1142
|
+
// Avoid accessing the `protocol` property due to the lazy getters.
|
|
1143
|
+
const parsedProtocol = parsed?.protocol
|
|
1144
|
+
|
|
1145
|
+
// `data:` and `blob:` disallowed due to allowing file: access via
|
|
1146
|
+
// indirection
|
|
1147
|
+
if (
|
|
1148
|
+
parsedProtocol &&
|
|
1149
|
+
parsedProtocol !== 'https:' &&
|
|
1150
|
+
parsedProtocol !== 'http:'
|
|
1151
|
+
) {
|
|
1152
|
+
throw new ERR_NETWORK_IMPORT_DISALLOWED(
|
|
1153
|
+
specifier,
|
|
1154
|
+
parsedParentURL,
|
|
1155
|
+
'remote imports cannot import from a local location.'
|
|
1156
|
+
)
|
|
1157
|
+
}
|
|
1158
|
+
|
|
1159
|
+
return {url: parsed?.href || ''}
|
|
1160
|
+
}
|
|
1161
|
+
|
|
1162
|
+
if (builtinModules.includes(specifier)) {
|
|
1163
|
+
throw new ERR_NETWORK_IMPORT_DISALLOWED(
|
|
1164
|
+
specifier,
|
|
1165
|
+
parsedParentURL,
|
|
1166
|
+
'remote imports cannot import from a local location.'
|
|
1167
|
+
)
|
|
1168
|
+
}
|
|
1169
|
+
|
|
1170
|
+
throw new ERR_NETWORK_IMPORT_DISALLOWED(
|
|
1171
|
+
specifier,
|
|
1172
|
+
parsedParentURL,
|
|
1173
|
+
'only relative and absolute specifiers are supported.'
|
|
1174
|
+
)
|
|
1175
|
+
}
|
|
1176
|
+
}
|
|
1177
|
+
}
|
|
1178
|
+
|
|
1179
|
+
// Note: this is from:
|
|
1180
|
+
// <https://github.com/nodejs/node/blob/3e74590/lib/internal/url.js#L687>
|
|
1181
|
+
/**
|
|
1182
|
+
* Checks if a value has the shape of a WHATWG URL object.
|
|
1183
|
+
*
|
|
1184
|
+
* Using a symbol or instanceof would not be able to recognize URL objects
|
|
1185
|
+
* coming from other implementations (e.g. in Electron), so instead we are
|
|
1186
|
+
* checking some well known properties for a lack of a better test.
|
|
1187
|
+
*
|
|
1188
|
+
* We use `href` and `protocol` as they are the only properties that are
|
|
1189
|
+
* easy to retrieve and calculate due to the lazy nature of the getters.
|
|
1190
|
+
*
|
|
1191
|
+
* @template {unknown} Value
|
|
1192
|
+
* @param {Value} self
|
|
1193
|
+
* @returns {Value is URL}
|
|
1194
|
+
*/
|
|
1195
|
+
function isURL(self) {
|
|
1196
|
+
return Boolean(
|
|
1197
|
+
self &&
|
|
1198
|
+
typeof self === 'object' &&
|
|
1199
|
+
'href' in self &&
|
|
1200
|
+
typeof self.href === 'string' &&
|
|
1201
|
+
'protocol' in self &&
|
|
1202
|
+
typeof self.protocol === 'string' &&
|
|
1203
|
+
self.href &&
|
|
1204
|
+
self.protocol
|
|
1205
|
+
)
|
|
1206
|
+
}
|
|
1207
|
+
|
|
1208
|
+
/**
|
|
1209
|
+
* Validate user-input in `context` supplied by a custom loader.
|
|
1210
|
+
*
|
|
1211
|
+
* @param {unknown} parentURL
|
|
1212
|
+
* @returns {asserts parentURL is URL | string | undefined}
|
|
1213
|
+
*/
|
|
1214
|
+
function throwIfInvalidParentURL(parentURL) {
|
|
1215
|
+
if (parentURL === undefined) {
|
|
1216
|
+
return // Main entry point, so no parent
|
|
1217
|
+
}
|
|
1218
|
+
|
|
1219
|
+
if (typeof parentURL !== 'string' && !isURL(parentURL)) {
|
|
1220
|
+
throw new codes.ERR_INVALID_ARG_TYPE(
|
|
1221
|
+
'parentURL',
|
|
1222
|
+
['string', 'URL'],
|
|
1223
|
+
parentURL
|
|
1224
|
+
)
|
|
1225
|
+
}
|
|
1226
|
+
}
|
|
1227
|
+
|
|
1228
|
+
/**
|
|
1229
|
+
* @param {string} specifier
|
|
1230
|
+
* @param {{parentURL?: string, conditions?: Array<string>}} context
|
|
1231
|
+
* @returns {{url: string, format?: string | null}}
|
|
1232
|
+
*/
|
|
1233
|
+
export function defaultResolve(specifier, context = {}) {
|
|
1234
|
+
const {parentURL} = context
|
|
1235
|
+
assert.ok(parentURL !== undefined, 'expected `parentURL` to be defined')
|
|
1236
|
+
throwIfInvalidParentURL(parentURL)
|
|
1237
|
+
|
|
1238
|
+
/** @type {URL | undefined} */
|
|
1239
|
+
let parsedParentURL
|
|
1240
|
+
if (parentURL) {
|
|
1241
|
+
try {
|
|
1242
|
+
parsedParentURL = new URL(parentURL)
|
|
1243
|
+
} catch {
|
|
1244
|
+
// Ignore exception
|
|
1245
|
+
}
|
|
1246
|
+
}
|
|
1247
|
+
|
|
1248
|
+
/** @type {URL | undefined} */
|
|
1249
|
+
let parsed
|
|
1250
|
+
/** @type {string | undefined} */
|
|
1251
|
+
let protocol
|
|
1252
|
+
|
|
1253
|
+
try {
|
|
1254
|
+
parsed = shouldBeTreatedAsRelativeOrAbsolutePath(specifier)
|
|
1255
|
+
? new URL(specifier, parsedParentURL)
|
|
1256
|
+
: new URL(specifier)
|
|
1257
|
+
|
|
1258
|
+
// Avoid accessing the `protocol` property due to the lazy getters.
|
|
1259
|
+
protocol = parsed.protocol
|
|
1260
|
+
|
|
1261
|
+
if (protocol === 'data:') {
|
|
1262
|
+
return {url: parsed.href, format: null}
|
|
1263
|
+
}
|
|
1264
|
+
} catch {
|
|
1265
|
+
// Ignore exception
|
|
1266
|
+
}
|
|
1267
|
+
|
|
1268
|
+
// There are multiple deep branches that can either throw or return; instead
|
|
1269
|
+
// of duplicating that deeply nested logic for the possible returns, DRY and
|
|
1270
|
+
// check for a return. This seems the least gnarly.
|
|
1271
|
+
const maybeReturn = checkIfDisallowedImport(
|
|
1272
|
+
specifier,
|
|
1273
|
+
parsed,
|
|
1274
|
+
parsedParentURL
|
|
1275
|
+
)
|
|
1276
|
+
|
|
1277
|
+
if (maybeReturn) return maybeReturn
|
|
1278
|
+
|
|
1279
|
+
// This must come after checkIfDisallowedImport
|
|
1280
|
+
if (protocol === undefined && parsed) {
|
|
1281
|
+
protocol = parsed.protocol
|
|
1282
|
+
}
|
|
1283
|
+
|
|
1284
|
+
if (protocol === 'node:') {
|
|
1285
|
+
return {url: specifier}
|
|
1286
|
+
}
|
|
1287
|
+
|
|
1288
|
+
// This must come after checkIfDisallowedImport
|
|
1289
|
+
if (parsed && parsed.protocol === 'node:') return {url: specifier}
|
|
1290
|
+
|
|
1291
|
+
const conditions = getConditionsSet(context.conditions)
|
|
1292
|
+
|
|
1293
|
+
const url = moduleResolve(specifier, new URL(parentURL), conditions, false)
|
|
1294
|
+
|
|
1295
|
+
return {
|
|
1296
|
+
// Do NOT cast `url` to a string: that will work even when there are real
|
|
1297
|
+
// problems, silencing them
|
|
1298
|
+
url: url.href,
|
|
1299
|
+
format: defaultGetFormatWithoutErrors(url, {parentURL})
|
|
1300
|
+
}
|
|
1301
|
+
}
|