@deepseek-ai/dsh-cordis-host-runner 0.2.1-alpha.1 → 0.2.1-alpha.3
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/lib/index.js +9 -9
- package/lib/typert.host.js +756 -223
- package/lib/typert.remote-client.d.ts +16 -2
- package/lib/typert.remote-client.js +564 -212
- package/lib/types/index.d.ts +5 -4
- package/lib/types/index.js +12 -8
- package/locale/en.json +5 -0
- package/locale/zh.json +6 -0
- package/package.json +26 -23
package/lib/index.js
CHANGED
|
@@ -1372,7 +1372,7 @@ var __esDecorate = function(ctor, descriptorIn, decorators, contextIn, initializ
|
|
|
1372
1372
|
* @param id - opaque identifier minted by the Host registry.
|
|
1373
1373
|
* @returns the branded Plugin identifier.
|
|
1374
1374
|
*/
|
|
1375
|
-
function
|
|
1375
|
+
function brandCordisDynamicPluginId(id) {
|
|
1376
1376
|
return id;
|
|
1377
1377
|
}
|
|
1378
1378
|
/**
|
|
@@ -1380,7 +1380,7 @@ function CordisDynamicPluginId(id) {
|
|
|
1380
1380
|
* @param id - opaque identifier minted by the Host registry.
|
|
1381
1381
|
* @returns the branded Package identifier.
|
|
1382
1382
|
*/
|
|
1383
|
-
function
|
|
1383
|
+
function brandCordisDynamicPackageId(id) {
|
|
1384
1384
|
return id;
|
|
1385
1385
|
}
|
|
1386
1386
|
/**
|
|
@@ -1388,7 +1388,7 @@ function CordisDynamicPackageId(id) {
|
|
|
1388
1388
|
* @param id - opaque identifier minted by the Host registry.
|
|
1389
1389
|
* @returns the branded Plugin Run identifier.
|
|
1390
1390
|
*/
|
|
1391
|
-
function
|
|
1391
|
+
function brandCordisDynamicPluginRunId(id) {
|
|
1392
1392
|
return id;
|
|
1393
1393
|
}
|
|
1394
1394
|
/**
|
|
@@ -1396,7 +1396,7 @@ function CordisDynamicPluginRunId(id) {
|
|
|
1396
1396
|
* @param id - opaque identifier minted by the Host registry.
|
|
1397
1397
|
* @returns the branded approval request identifier.
|
|
1398
1398
|
*/
|
|
1399
|
-
function
|
|
1399
|
+
function brandApprovalRequestId(id) {
|
|
1400
1400
|
return id;
|
|
1401
1401
|
}
|
|
1402
1402
|
/** Dynamic Plugin registry and Host-half lifecycle. */
|
|
@@ -1605,7 +1605,7 @@ let DynamicCordisRunnerService = (() => {
|
|
|
1605
1605
|
const prefix = request.plugin.idPrefix.trim();
|
|
1606
1606
|
if (!/^[a-z]{3,6}$/.test(prefix)) throw new Error("cordis_define `plugin.idPrefix` must contain 3–6 lowercase English letters");
|
|
1607
1607
|
plugin = {
|
|
1608
|
-
pluginId:
|
|
1608
|
+
pluginId: brandCordisDynamicPluginId(this.registry.mintPluginId(prefix)),
|
|
1609
1609
|
sessionId: request.sessionId,
|
|
1610
1610
|
packages: /* @__PURE__ */ new Map(),
|
|
1611
1611
|
approvedClientPackages: /* @__PURE__ */ new Set(),
|
|
@@ -1617,7 +1617,7 @@ let DynamicCordisRunnerService = (() => {
|
|
|
1617
1617
|
if (found === void 0 || found.sessionId !== request.sessionId) throw new Error(missingPluginMessage(request.plugin.pluginId));
|
|
1618
1618
|
plugin = found;
|
|
1619
1619
|
}
|
|
1620
|
-
const packageId =
|
|
1620
|
+
const packageId = brandCordisDynamicPackageId(this.registry.mintPackageId());
|
|
1621
1621
|
const definition = {
|
|
1622
1622
|
packageId,
|
|
1623
1623
|
name,
|
|
@@ -1703,7 +1703,7 @@ let DynamicCordisRunnerService = (() => {
|
|
|
1703
1703
|
reason: "host-half-failed"
|
|
1704
1704
|
};
|
|
1705
1705
|
}
|
|
1706
|
-
const requestId =
|
|
1706
|
+
const requestId = brandApprovalRequestId(this.registry.mintApprovalRequestId());
|
|
1707
1707
|
const requiresApproval = !plan.plugin.clientVersionUpdatesApproved && !plan.plugin.approvedClientPackages.has(packageId);
|
|
1708
1708
|
attempt.approvalRequestId = requestId;
|
|
1709
1709
|
attempt.requiresApproval = requiresApproval;
|
|
@@ -2474,7 +2474,7 @@ let DynamicCordisRunnerService = (() => {
|
|
|
2474
2474
|
}
|
|
2475
2475
|
createAttempt(plan) {
|
|
2476
2476
|
return {
|
|
2477
|
-
pluginRunId:
|
|
2477
|
+
pluginRunId: brandCordisDynamicPluginRunId(this.registry.mintPluginRunId()),
|
|
2478
2478
|
packageId: plan.definition.packageId,
|
|
2479
2479
|
mode: plan.mode,
|
|
2480
2480
|
status: "starting-host",
|
|
@@ -2569,4 +2569,4 @@ function cloneAttempt(attempt) {
|
|
|
2569
2569
|
};
|
|
2570
2570
|
}
|
|
2571
2571
|
//#endregion
|
|
2572
|
-
export { ApprovalRequestId, CordisDynamicPackageId, CordisDynamicPluginId, CordisDynamicPluginRunId, CordisInspectRegistryService, DynamicCordisRunnerService, DynamicCordisRunnerService as default };
|
|
2572
|
+
export { brandApprovalRequestId as ApprovalRequestId, brandCordisDynamicPackageId as CordisDynamicPackageId, brandCordisDynamicPluginId as CordisDynamicPluginId, brandCordisDynamicPluginRunId as CordisDynamicPluginRunId, CordisInspectRegistryService, DynamicCordisRunnerService, DynamicCordisRunnerService as default };
|