webloom-framework 0.4.0 → 0.4.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 +1 -1
- package/dist/advanced.d.ts +5 -5
- package/dist/advanced.js +4 -4
- package/dist/{chunk-RAQOFUZY.js → chunk-ANA6GBEI.js} +3 -3
- package/dist/{chunk-RAQOFUZY.js.map → chunk-ANA6GBEI.js.map} +1 -1
- package/dist/{chunk-JHJZIO2H.js → chunk-HJKPKWI7.js} +8 -2
- package/dist/chunk-HJKPKWI7.js.map +1 -0
- package/dist/{chunk-YOIH6H36.js → chunk-SX46RHDI.js} +15 -15
- package/dist/chunk-SX46RHDI.js.map +1 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -4
- package/dist/{messagePortServiceTransport-B0FyJr43.d.ts → messagePortServiceTransport-BYprNvQY.d.ts} +1 -1
- package/dist/react.js +1 -1
- package/dist/{sharedWorkerHost-Cb2a1_KD.d.ts → sharedWorkerHost-KI7TIGdX.d.ts} +2 -0
- package/dist/testing.d.ts +3 -3
- package/dist/testing.js +4 -4
- package/dist/{windowRuntime-B6Ue8jso.d.ts → windowRuntime-BKkLPsAS.d.ts} +1 -1
- package/docs/api.md +1 -1
- package/docs/proposals/webloom-v4/verification.md +86 -55
- package/package.json +5 -3
- package/dist/chunk-JHJZIO2H.js.map +0 -1
- package/dist/chunk-YOIH6H36.js.map +0 -1
|
@@ -485,11 +485,17 @@ function validateTransferListWithStats(value, transfer, options = {}) {
|
|
|
485
485
|
maxEdges: limits.maxDtoEdges,
|
|
486
486
|
maxBudgetBytes: limits.maxMessageBudgetBytes
|
|
487
487
|
},
|
|
488
|
+
// MessagePort presence is checked below so a missing declaration is
|
|
489
|
+
// reported as a transfer-contract error, while the walker still validates
|
|
490
|
+
// the complete DTO graph and preserves the actual port identity set.
|
|
491
|
+
allowUnlistedMessagePorts: true,
|
|
488
492
|
transferables: new Set(result),
|
|
489
493
|
phase: options.phase ?? "validate"
|
|
490
494
|
});
|
|
491
495
|
const reachable = new Set(stats.reachableTransferables);
|
|
492
496
|
if (result.some((item) => !reachable.has(item))) throw new WebLoomError("transfer_invalid", "Capability transfer resource is not reachable from its payload", options.phase ?? "validate");
|
|
497
|
+
const declared = new Set(result);
|
|
498
|
+
if (stats.messagePorts.some((port) => !declared.has(port))) throw new WebLoomError("transfer_invalid", "Capability payload contains a MessagePort missing from its transfer declaration", options.phase ?? "validate");
|
|
493
499
|
return { transfer: Object.freeze(result), stats };
|
|
494
500
|
}
|
|
495
501
|
function validateTransferList(value, transfer, options = {}) {
|
|
@@ -4014,5 +4020,5 @@ function hostForWindowApp(app) {
|
|
|
4014
4020
|
}
|
|
4015
4021
|
|
|
4016
4022
|
export { DEFAULT_RUNTIME_LIMITS, LIFECYCLE_ERROR_TEXT, LifecycleScopeRevokedError, PermissionDeniedError, PermissionLeaseRevokedError, RESOURCE_OWNER, RESOURCE_REGISTRY, RUNTIME_CALL_TYPE, RUNTIME_CANCEL_TYPE, RUNTIME_CREDIT_TYPE, RUNTIME_ERROR_MESSAGE_TYPE, RUNTIME_ERROR_TYPE, RUNTIME_NEXT_TYPE, RUNTIME_PROTOCOL_VERSION, RUNTIME_RESULT_TYPE, RUNTIME_SNAPSHOT_TYPE, RuntimeInitializationError, RuntimeUnavailableError, SCOPED_TASK_SCHEDULER_CAPABILITY, StartupCapabilityError, StartupPluginError, UpgradeGateRejectedError, WebLoomError, assertCapability, assertReceivedPortSet, buildPluginGraph, capabilityDescriptor, capabilityKey, cloneFrozenAttributes, createCapabilityRegistry, createInMemoryPluginConfigStore, createLifecycleScope, createMessageBus, createPermissionLease, createPluginHost, createReceivePortLedger, createResourceRegistry, createResourceScope, createResourceStore, createRuntimeBudget, createRuntimeMessageCodec, createRuntimeUnitImplementationRegistry, createScopedTaskScheduler, createWindowApp, createWindowAppFromHost, defineCapability, dependenciesOfManifest, hostForWindowApp, invokeCapabilityHandler, isCapability, isCapabilityDescriptor, isRuntimeSnapshot, lifecycleErrorText, materializePluginDefinitions, normalizeRuntimeLimits, providesOfManifest, registerOwnedResource, reverseDependentsOf, selectRuntimeUnit, validateDto, validatePluginGraph, validateRawDto, validateTransferList, validateTransferListWithStats };
|
|
4017
|
-
//# sourceMappingURL=chunk-
|
|
4018
|
-
//# sourceMappingURL=chunk-
|
|
4023
|
+
//# sourceMappingURL=chunk-HJKPKWI7.js.map
|
|
4024
|
+
//# sourceMappingURL=chunk-HJKPKWI7.js.map
|