@camstack/server 1.2.801 → 1.2.803
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/CHANGELOG.md +12 -0
- package/dist/api/trpc/generated-cap-routers.js +26 -0
- package/dist/core/addon/addon-settings-provider.js +25 -0
- package/package.json +10 -9
- package/system/dist/addon-runner.js +1 -0
- package/system/dist/addon-runner.mjs +1 -0
- package/system/dist/{agent-https-BnKdN7Rx.mjs → agent-https-BRfJO9ZR.mjs} +1 -1
- package/system/dist/{agent-https-BjJ2cnwd.js → agent-https-DtYiXPGm.js} +1 -1
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/alerts/alerts.addon.js +1 -1
- package/system/dist/builtins/alerts/alerts.addon.mjs +1 -1
- package/system/dist/builtins/autotrack/index.js +1 -1
- package/system/dist/builtins/autotrack/index.mjs +1 -1
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +2 -2
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +2 -2
- package/system/dist/builtins/calendars/calendars.addon.js +1 -1
- package/system/dist/builtins/calendars/calendars.addon.mjs +1 -1
- package/system/dist/builtins/camera-grid/index.js +1 -1
- package/system/dist/builtins/camera-grid/index.mjs +1 -1
- package/system/dist/builtins/composer/composer.addon.js +6 -5
- package/system/dist/builtins/composer/composer.addon.mjs +6 -5
- package/system/dist/builtins/console-logging/index.js +1 -1
- package/system/dist/builtins/console-logging/index.mjs +1 -1
- package/system/dist/builtins/core-blocks/core-blocks.addon.js +65 -6
- package/system/dist/builtins/core-blocks/core-blocks.addon.mjs +65 -6
- package/system/dist/builtins/core-blocks/timed-run/timed-run-service.d.ts +17 -0
- package/system/dist/builtins/core-blocks/timed-run/timed-run-wiring.d.ts +6 -0
- package/system/dist/builtins/device-history/device-history.addon.js +2 -2
- package/system/dist/builtins/device-history/device-history.addon.mjs +2 -2
- package/system/dist/builtins/device-manager/device-config-contribution.d.ts +1 -0
- package/system/dist/builtins/device-manager/device-manager.addon.js +47 -2
- package/system/dist/builtins/device-manager/device-manager.addon.mjs +47 -2
- package/system/dist/builtins/device-manager/timed-run-config-schema.d.ts +18 -0
- package/system/dist/builtins/hub-forwarder/index.js +1 -1
- package/system/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/system/dist/builtins/keychain/index.js +4 -4
- package/system/dist/builtins/keychain/index.mjs +4 -4
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/system/dist/builtins/local-auth/local-auth.addon.js +2 -2
- package/system/dist/builtins/local-auth/local-auth.addon.mjs +2 -2
- package/system/dist/builtins/local-network/local-network.addon.js +2 -2
- package/system/dist/builtins/local-network/local-network.addon.mjs +2 -2
- package/system/dist/builtins/loki-logging/index.js +1 -1
- package/system/dist/builtins/loki-logging/index.mjs +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
- package/system/dist/builtins/platform-probe/index.js +1 -1
- package/system/dist/builtins/platform-probe/index.mjs +1 -1
- package/system/dist/builtins/record-entries/index.js +1 -1
- package/system/dist/builtins/record-entries/index.mjs +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/snapshot/index.js +1 -1
- package/system/dist/builtins/snapshot/index.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/index.js +1 -1
- package/system/dist/builtins/sqlite-storage/index.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.js +3 -3
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +3 -3
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/system-config/system-config.addon.js +3 -3
- package/system/dist/builtins/system-config/system-config.addon.mjs +284 -284
- package/system/dist/builtins/winston-logging/index.js +1 -1
- package/system/dist/builtins/winston-logging/index.mjs +1 -1
- package/system/dist/{capture-engine-B9__aDmc.mjs → capture-engine-BFgeAHa9.mjs} +1 -1
- package/system/dist/{capture-engine-DfPZm5jP.js → capture-engine-BQ08XTnZ.js} +1 -1
- package/system/dist/{composition-sources-CcikkVOX.js → composition-sources-DNHNUvTr.js} +1 -1
- package/system/dist/{composition-sources-CjT_EsId.mjs → composition-sources-DkOfzgpS.mjs} +1 -1
- package/system/dist/{constants-Iha5kSgS.js → constants-D5CG3Gvc.js} +1 -1
- package/system/dist/{constants-D09uTsrc.mjs → constants-GCrIKhD_.mjs} +1 -1
- package/system/dist/{device-ca-C1pfeZfN.js → device-ca-DgZeLVC1.js} +1 -1
- package/system/dist/{device-ca-DM2h_Qrk.mjs → device-ca-Dk2sx_18.mjs} +1 -1
- package/system/dist/{dist--HaCM746.js → dist-D5nGm8Sd.js} +602 -372
- package/system/dist/{dist-ysMqEeaW.mjs → dist-ze-qVU7x.mjs} +585 -373
- package/system/dist/file-host-worker.js +1 -1
- package/system/dist/file-host-worker.mjs +1 -1
- package/system/dist/{hub-mdns-ciao-CUZ6phZn.js → hub-mdns-ciao-D4g9qsNL.js} +2 -2
- package/system/dist/{hub-mdns-ciao-C3jwbb5f.mjs → hub-mdns-ciao-DD2QP3w5.mjs} +2 -2
- package/system/dist/index.js +16 -10
- package/system/dist/index.mjs +16 -10
- package/system/dist/kernel/transport/child-cap-protocol.d.ts +1 -1
- package/system/dist/{legacy-integration-rows-door-B1ZSr6jn.mjs → legacy-integration-rows-door-BvEFQrAa.mjs} +1 -1
- package/system/dist/{legacy-integration-rows-door-CCZw-yoA.js → legacy-integration-rows-door-MRr8Ncb_.js} +1 -1
- package/system/dist/{restore-archive-wzwpsuCo.mjs → restore-archive-DBc5sNQS.mjs} +82 -82
- package/system/dist/{restore-archive-rBEGddHB.js → restore-archive-aG7OlQNo.js} +1 -1
- package/system/dist/{wal-maintenance-EhxZt6T-.js → wal-maintenance-C-ddHy-q.js} +0 -0
- package/system/dist/{wal-maintenance-_PPIgcP4.mjs → wal-maintenance-vQHsOLGg.mjs} +0 -0
- package/system/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { $ as EMPTY_AUTOMATION_STATE, $
|
|
1
|
+
import { $ as EMPTY_AUTOMATION_STATE, $a as validateSchedulerInput, $n as coreBlocksCapability, A as ControlStatusSchema, Ac as DeviceType$1, Ai as normalizeCoreBlockWrite, Ao as helperMembers, C as CORE_BLOCKS_ADDON_ID, Di as nextOccurrence, Et as MediaPlayerStatusSchema, Fi as occurrenceOn, Ft as PowerSourceInfoSchema, Ga as timedRunLimitOf, Gi as powerSourceCapability, Gt as RemoteConfigSchema, Hr as internalActionId, In as capUnitResolver, Is as defineAddonMigrations, J as DeclaredDevices, Ja as timedRunSeconds, Ji as problemsBlockSave, Ka as timedRunMaxIn, Ki as powerSourceLinkOfComposition, Kt as RunningStateStatusSchema, Mc as EventCategory$1, Mr as fanPresetsCapability, Ms as collectSecretMarkerRefs, O as ConditionMirror, Oi as normalizeActionUnits, On as buildActionSteps, Qn as coreBlockSourceKind, R as DEFAULT_HOLD_OVERRIDE, S as COMPOSER_RUNNER_ID, Tc as transformSecretWrite, To as compositionSourceKey, Tr as evaluateWhenTree, Ua as templateCapability, Ui as planComposition, Uo as BaseAddon, Vn as collectWhenMirrorSources, Vt as REMOTE_MEDIA_COMMANDS, Wa as timedRunCapability, Wn as compileScalarOverride, Wt as RemoteAssumedStateSchema, Xn as coreBlockComposition, Xt as SchedulerError, Yn as coreBlockAddonId, Za as validateComposition, Zi as proposeRunningThreshold, Zn as coreBlockIdFromAddonId, Zr as isInternalActionId, Zt as SchedulerSchema, _c as resolveSecretMarkers, aa as resolveActionVariables, an as SwitchStatusSchema, ao as weekdayOfLocalDate, ba as schedulersCapability, bc as secretTreeFromSchema, bo as composedDeviceRef, c as ActionError, ca as resolveCoreBlockEntry, ci as localDateOf, co as zoneOnlySite, d as ActionVariableSchema, dn as actionSourceCapability, do as DAY_MS, dr as describeComposableCaps, et as EMPTY_REMOTE_ASSUMED_STATE, fi as lockDoorLinkOfComposition, fn as actionWaitTotalMs, ga as resolveStepArgs, go as HelperMemberSchema, gt as INTERNAL_ACTION_PREFIX, ht as IDLE_ACTION_STATUS, ia as replacedFieldKeys, ic as isSecretRefOwnedBy, io as vocabActionIdFor, it as FanControlStatusSchema, j as CoreBlockSchema, jc as errMsg$1, ji as normalizeStepTargets, jo as historyRetentionFromSettings, ka as siteFor, ki as normalizeCapStep, kn as buildCapabilityLookup, l as ActionStepSchema, la as resolveCoreBlockFiles, m as BUILTIN_REMOTE_COMPONENTS, mn as addonIdOfActionId, n as ACTION_TARGET_INVALIDATION_EVENTS, na as remoteCapability, nc as isSecretMarker, ni as kebabToCamel, nr as customKeyOfRole, nt as FAN_CAPTURE_FIELDS, on as TemplateKindSchema, ot as FanPresetSchema, p as AutomationStateDocSchema, pn as actionsCapability, qa as timedRunQuickRun, qn as compositionSourceRefs, qs as hydrateSchema, ra as remoteLayoutComponentsCapability, rr as customRole, s as ALL_CAPABILITY_DEFINITIONS, tt as EMPTY_REMOTE_CONFIG, u as ActionTargetResolver, un as actionEffect, uo as CompositionSchema, va as runSteps, w as CORE_BLOCK_ADDON_PREFIX, xn as appendTrace, zn as checkTemplatePayload, zs as defineRecordKinds, zt as QuantityUnitError } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
|
-
import { i as parseDeviceStateChanged, t as describeCompositionSources } from "../../composition-sources-
|
|
4
|
-
import { i as capSeriesKey } from "../../capture-engine-
|
|
3
|
+
import { i as parseDeviceStateChanged, t as describeCompositionSources } from "../../composition-sources-DkOfzgpS.mjs";
|
|
4
|
+
import { i as capSeriesKey } from "../../capture-engine-BFgeAHa9.mjs";
|
|
5
5
|
import { t as prefixRange } from "../../prefix-range-Dl0znowN.mjs";
|
|
6
6
|
import { n as unwrapStoredValue, t as loadPrefixed } from "../../prefix-walk-DAOBSyH1.mjs";
|
|
7
7
|
import { createRequire } from "node:module";
|
|
@@ -3676,6 +3676,37 @@ var TimedRunService = class {
|
|
|
3676
3676
|
this.deps = deps;
|
|
3677
3677
|
}
|
|
3678
3678
|
getStatus = async ({ deviceId }) => this.statusOf(deviceId);
|
|
3679
|
+
getOptions = async ({ deviceId }) => {
|
|
3680
|
+
const limit = await this.limitOf(deviceId);
|
|
3681
|
+
if (limit === null) throw new Error(`timed-run: device ${deviceId} has no timed run`);
|
|
3682
|
+
return {
|
|
3683
|
+
unit: limit.unit,
|
|
3684
|
+
maxDuration: timedRunMaxIn(limit),
|
|
3685
|
+
defaultDuration: limit.quickRunDefault
|
|
3686
|
+
};
|
|
3687
|
+
};
|
|
3688
|
+
/**
|
|
3689
|
+
* The one-tap run of a device. Above the type's maximum it is REFUSED, like `runFor`. It
|
|
3690
|
+
* THROWS rather than returning a typed result: `setSettings` returns void on every
|
|
3691
|
+
* derived-form cap (day-night, image-settings), and the form's save path shows a thrown
|
|
3692
|
+
* message to the operator; a void return would let a refused value look saved.
|
|
3693
|
+
*/
|
|
3694
|
+
setSettings = async ({ deviceId, settings }) => {
|
|
3695
|
+
const limit = await this.limitOf(deviceId);
|
|
3696
|
+
if (limit === null) throw new Error(`timed-run: device ${deviceId} has no timed run`);
|
|
3697
|
+
const duration = settings.quickRunDuration;
|
|
3698
|
+
if (duration === void 0) return;
|
|
3699
|
+
if (duration !== null && duration > timedRunMaxIn(limit)) {
|
|
3700
|
+
this.deps.logger.warn("timed-run refused: the one-tap run is over the maximum", { tags: { deviceId } });
|
|
3701
|
+
throw new Error(`timed-run: a one-tap run of ${duration} ${limit.unit} is over the maximum of ${timedRunMaxIn(limit)} ${limit.unit}`);
|
|
3702
|
+
}
|
|
3703
|
+
await this.deps.quickRuns.write(deviceId, duration);
|
|
3704
|
+
await this.publishStatus(deviceId);
|
|
3705
|
+
};
|
|
3706
|
+
async limitOf(deviceId) {
|
|
3707
|
+
const type = await this.deps.deviceTypeOf(deviceId);
|
|
3708
|
+
return type === null ? null : timedRunLimitOf(type);
|
|
3709
|
+
}
|
|
3679
3710
|
runFor = async (input) => {
|
|
3680
3711
|
const { deviceId } = input;
|
|
3681
3712
|
const type = await this.deps.deviceTypeOf(deviceId);
|
|
@@ -3752,7 +3783,8 @@ var TimedRunService = class {
|
|
|
3752
3783
|
for (const { deviceId, body } of rows) if (body.activeUntil <= now) this.queueExpire(deviceId, body);
|
|
3753
3784
|
else this.pending.set(deviceId, body);
|
|
3754
3785
|
this.rearm();
|
|
3755
|
-
|
|
3786
|
+
const ids = new Set([...rows.map((row) => row.deviceId), ...await this.deps.timedRunDeviceIds()]);
|
|
3787
|
+
for (const deviceId of ids) await this.publishStatus(deviceId);
|
|
3756
3788
|
}
|
|
3757
3789
|
/** Resolves when every deadline that already fired has been carried out. */
|
|
3758
3790
|
async settled() {
|
|
@@ -3774,17 +3806,19 @@ var TimedRunService = class {
|
|
|
3774
3806
|
this.rearm();
|
|
3775
3807
|
await this.publishStatus(deviceId);
|
|
3776
3808
|
}
|
|
3777
|
-
statusOf(deviceId) {
|
|
3809
|
+
async statusOf(deviceId) {
|
|
3778
3810
|
const row = this.pending.get(deviceId);
|
|
3811
|
+
const limit = await this.limitOf(deviceId);
|
|
3779
3812
|
return {
|
|
3780
3813
|
activeUntil: row?.activeUntil ?? null,
|
|
3781
3814
|
requestedBy: row?.requestedBy ?? null,
|
|
3815
|
+
quickRun: limit === null ? null : timedRunQuickRun(limit, await this.deps.quickRuns.read(deviceId)),
|
|
3782
3816
|
lastFetchedAt: this.deps.now()
|
|
3783
3817
|
};
|
|
3784
3818
|
}
|
|
3785
3819
|
async publishStatus(deviceId) {
|
|
3786
3820
|
try {
|
|
3787
|
-
await this.deps.publish(deviceId, this.statusOf(deviceId));
|
|
3821
|
+
await this.deps.publish(deviceId, await this.statusOf(deviceId));
|
|
3788
3822
|
} catch (error) {
|
|
3789
3823
|
this.deps.logger.warn("timed-run could not publish its state", {
|
|
3790
3824
|
tags: { deviceId },
|
|
@@ -3836,6 +3870,11 @@ var TimedRunService = class {
|
|
|
3836
3870
|
};
|
|
3837
3871
|
//#endregion
|
|
3838
3872
|
//#region src/builtins/core-blocks/timed-run/timed-run-wiring.ts
|
|
3873
|
+
/**
|
|
3874
|
+
* Wires `TimedRunService` to the hub: its rows (the `timed-runs` kind), the
|
|
3875
|
+
* device registry for a device's type, the device caps for the on/off command
|
|
3876
|
+
* and `deviceState.setCapSlice` for the mirrored slice.
|
|
3877
|
+
*/
|
|
3839
3878
|
var ARM_RETRY_DELAY_MS$2 = 5e3;
|
|
3840
3879
|
var ARM_MAX_ATTEMPTS$2 = 24;
|
|
3841
3880
|
function rowsOver(records) {
|
|
@@ -3867,6 +3906,21 @@ function rowsOver(records) {
|
|
|
3867
3906
|
}
|
|
3868
3907
|
};
|
|
3869
3908
|
}
|
|
3909
|
+
var QUICK_RUN_KEY = "quickRunDuration";
|
|
3910
|
+
function quickRunsOver(settings) {
|
|
3911
|
+
const need = () => {
|
|
3912
|
+
const current = settings();
|
|
3913
|
+
if (current === void 0) throw new Error("core-blocks: no ctx.settings on this node");
|
|
3914
|
+
return current;
|
|
3915
|
+
};
|
|
3916
|
+
return {
|
|
3917
|
+
read: async (deviceId) => {
|
|
3918
|
+
const stored = (await need().readDeviceStore(deviceId))[QUICK_RUN_KEY];
|
|
3919
|
+
return typeof stored === "number" ? stored : null;
|
|
3920
|
+
},
|
|
3921
|
+
write: (deviceId, duration) => need().writeDeviceStore(deviceId, { [QUICK_RUN_KEY]: duration })
|
|
3922
|
+
};
|
|
3923
|
+
}
|
|
3870
3924
|
function actuationOver(api) {
|
|
3871
3925
|
const invoke = invokeCapOver(api);
|
|
3872
3926
|
return { set: (deviceId, actuator, on) => actuator === "switch" ? invoke({
|
|
@@ -3893,7 +3947,11 @@ function buildTimedRunService(deps) {
|
|
|
3893
3947
|
const found = await need().deviceManager.getDevice.query({ deviceId });
|
|
3894
3948
|
return found === null || found === void 0 ? null : found.type;
|
|
3895
3949
|
},
|
|
3950
|
+
timedRunDeviceIds: async () => {
|
|
3951
|
+
return (await need().deviceManager.listAll.query({ projection: "slim" })).filter((d) => timedRunLimitOf(d.type) !== null).map((d) => d.id);
|
|
3952
|
+
},
|
|
3896
3953
|
actuation: actuationOver(deps.api),
|
|
3954
|
+
quickRuns: quickRunsOver(deps.settings),
|
|
3897
3955
|
publish: async (deviceId, status) => {
|
|
3898
3956
|
await need().deviceState.setCapSlice.mutate({
|
|
3899
3957
|
deviceId,
|
|
@@ -7625,6 +7683,7 @@ var CoreBlocksAddon = class extends BaseAddon {
|
|
|
7625
7683
|
this.installDeviceCallRedirect();
|
|
7626
7684
|
const timedRun = buildTimedRunService({
|
|
7627
7685
|
records,
|
|
7686
|
+
settings: () => this.ctx.settings,
|
|
7628
7687
|
api: () => this.ctx.api,
|
|
7629
7688
|
logger: this.ctx.logger.child("timed-run")
|
|
7630
7689
|
});
|
|
@@ -33,10 +33,18 @@ export interface TimedRunActuation {
|
|
|
33
33
|
/** Throws when the device does not take the command. */
|
|
34
34
|
readonly set: (deviceId: number, actuator: TimedRunActuator, on: boolean) => Promise<void>;
|
|
35
35
|
}
|
|
36
|
+
/** The one-tap run duration an operator stored per device, in the type's unit. */
|
|
37
|
+
export interface TimedRunQuickRuns {
|
|
38
|
+
readonly read: (deviceId: number) => Promise<number | null>;
|
|
39
|
+
readonly write: (deviceId: number, duration: number | null) => Promise<void>;
|
|
40
|
+
}
|
|
36
41
|
export interface TimedRunServiceDeps {
|
|
37
42
|
readonly rows: TimedRunRows;
|
|
38
43
|
readonly deviceTypeOf: (deviceId: number) => Promise<DeviceType | null>;
|
|
44
|
+
/** Every device whose type offers a timed run: boot publishes each one's status. */
|
|
45
|
+
readonly timedRunDeviceIds: () => Promise<readonly number[]>;
|
|
39
46
|
readonly actuation: TimedRunActuation;
|
|
47
|
+
readonly quickRuns: TimedRunQuickRuns;
|
|
40
48
|
/** Mirror the slice into the device state; failures are logged by the service. */
|
|
41
49
|
readonly publish: (deviceId: number, status: TimedRunStatus) => Promise<void>;
|
|
42
50
|
readonly scheduler: PowerSourceScheduler;
|
|
@@ -63,6 +71,15 @@ export declare class TimedRunService implements ITimedRunProvider {
|
|
|
63
71
|
private stopped;
|
|
64
72
|
constructor(deps: TimedRunServiceDeps);
|
|
65
73
|
getStatus: ITimedRunProvider["getStatus"];
|
|
74
|
+
getOptions: ITimedRunProvider["getOptions"];
|
|
75
|
+
/**
|
|
76
|
+
* The one-tap run of a device. Above the type's maximum it is REFUSED, like `runFor`. It
|
|
77
|
+
* THROWS rather than returning a typed result: `setSettings` returns void on every
|
|
78
|
+
* derived-form cap (day-night, image-settings), and the form's save path shows a thrown
|
|
79
|
+
* message to the operator; a void return would let a refused value look saved.
|
|
80
|
+
*/
|
|
81
|
+
setSettings: ITimedRunProvider["setSettings"];
|
|
82
|
+
private limitOf;
|
|
66
83
|
runFor: ITimedRunProvider["runFor"];
|
|
67
84
|
cancel: ITimedRunProvider["cancel"];
|
|
68
85
|
/** Feed one `DeviceStateChanged`: a manual off cancels the pending deadline. */
|
|
@@ -5,8 +5,14 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { type AddonApi, type IScopedLogger, type RecordsAccess } from "@camstack/types";
|
|
7
7
|
import { TimedRunService } from "./timed-run-service.js";
|
|
8
|
+
/** The addon's per-device settings (D865), the one home of the one-tap run. */
|
|
9
|
+
export interface TimedRunSettingsAccess {
|
|
10
|
+
readonly readDeviceStore: (deviceId: number) => Promise<Record<string, unknown>>;
|
|
11
|
+
readonly writeDeviceStore: (deviceId: number, patch: Record<string, unknown>) => Promise<void>;
|
|
12
|
+
}
|
|
8
13
|
export interface TimedRunWiringDeps {
|
|
9
14
|
readonly records: RecordsAccess;
|
|
15
|
+
readonly settings: () => TimedRunSettingsAccess | undefined;
|
|
10
16
|
readonly api: () => AddonApi | undefined;
|
|
11
17
|
readonly logger: IScopedLogger;
|
|
12
18
|
}
|
|
@@ -3,8 +3,8 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
7
|
-
const require_capture_engine = require("../../capture-engine-
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
|
+
const require_capture_engine = require("../../capture-engine-BQ08XTnZ.js");
|
|
8
8
|
const require_retention = require("../../retention-BNONb5X_.js");
|
|
9
9
|
let node_crypto = require("node:crypto");
|
|
10
10
|
//#region src/builtins/device-history/capture/point-writer.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as catalogMetrics, c as DeviceDirectory, d as identityOf, f as subjectIdOf, i as capSeriesKey, l as isRealDeviceType, n as CaptureEngine, o as readPath, r as capItemSeriesKey, s as readUnit, t as CAP_KEY_PREFIX, u as SeriesRegistry } from "../../capture-engine-
|
|
1
|
+
import { $s as isReadingQuantity, Ac as DeviceType, Ho as wattMillisecondsToKwh, Ks as historyUnitFor, Mc as EventCategory, Sn as armRemovalReconcile, Uo as BaseAddon, V as DEVICE_HISTORY_ENERGY_KEY, Vs as emitReadiness, Y as DeviceRunSchema, _r as deviceRemovalHookCapability, dt as HISTORY_ITEM_CATALOG, hr as deviceHistoryCapability, ut as HISTORY_CATALOG, vr as deviceRunsCapability, zs as defineRecordKinds } from "../../dist-ze-qVU7x.mjs";
|
|
2
|
+
import { a as catalogMetrics, c as DeviceDirectory, d as identityOf, f as subjectIdOf, i as capSeriesKey, l as isRealDeviceType, n as CaptureEngine, o as readPath, r as capItemSeriesKey, s as readUnit, t as CAP_KEY_PREFIX, u as SeriesRegistry } from "../../capture-engine-BFgeAHa9.mjs";
|
|
3
3
|
import { a as FIVE_MINUTES_MS, c as bucketEndOf, i as DAY_MS, l as bucketStartOf, n as RetentionJob, o as HOUR_MS, r as DepartureTracker, s as ROLLUP_GRACE_MS, t as DEFAULT_RETENTION, u as floorTo } from "../../retention-B9l9TnGE.mjs";
|
|
4
4
|
import { randomUUID } from "node:crypto";
|
|
5
5
|
//#region src/builtins/device-history/capture/point-writer.ts
|
|
@@ -24,6 +24,7 @@ export declare const STREAM_PARAMS_BUILDER_ID: "stream-params";
|
|
|
24
24
|
export declare const DAY_NIGHT_BUILDER_ID: "day-night";
|
|
25
25
|
export declare const IMAGE_SETTINGS_BUILDER_ID: "image-settings";
|
|
26
26
|
export declare const RECORDING_ONBOARD_BUILDER_ID: "recording-onboard";
|
|
27
|
+
export declare const TIMED_RUN_BUILDER_ID: "timed-run";
|
|
27
28
|
/**
|
|
28
29
|
* Build the device-detail form section for a `derived-form` device-config
|
|
29
30
|
* cap. Returns null when the camera exposes no configurable property.
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
8
8
|
const require_prefix_range = require("../../prefix-range-D_KueXbQ.js");
|
|
9
9
|
const require_prefix_walk = require("../../prefix-walk-Dv6MLZlM.js");
|
|
@@ -2081,6 +2081,44 @@ function parseImageSettingsFormPatch(patch) {
|
|
|
2081
2081
|
return out;
|
|
2082
2082
|
}
|
|
2083
2083
|
//#endregion
|
|
2084
|
+
//#region src/builtins/device-manager/timed-run-config-schema.ts
|
|
2085
|
+
var TIMED_RUN_QUICK_RUN_KEY = "timedRun_quickRunDuration";
|
|
2086
|
+
function buildTimedRunConfigSchema(options, status) {
|
|
2087
|
+
return { sections: [{
|
|
2088
|
+
id: "timed-run",
|
|
2089
|
+
tab: "general",
|
|
2090
|
+
title: "One-tap run",
|
|
2091
|
+
titleKey: "server:section.s_timed-run.title",
|
|
2092
|
+
description: "How long the Run button starts this device for. The hub switches it off when the time is up.",
|
|
2093
|
+
descriptionKey: "server:section.s_timed-run.description",
|
|
2094
|
+
columns: 1,
|
|
2095
|
+
fields: [{
|
|
2096
|
+
type: "number",
|
|
2097
|
+
key: TIMED_RUN_QUICK_RUN_KEY,
|
|
2098
|
+
label: "One-tap run",
|
|
2099
|
+
labelKey: "server:timedRunConfig.timedRun_quickRunDuration.label",
|
|
2100
|
+
unit: options.unit,
|
|
2101
|
+
min: 1,
|
|
2102
|
+
max: options.maxDuration,
|
|
2103
|
+
step: 1,
|
|
2104
|
+
default: status?.quickRun?.duration ?? options.defaultDuration
|
|
2105
|
+
}]
|
|
2106
|
+
}] };
|
|
2107
|
+
}
|
|
2108
|
+
/**
|
|
2109
|
+
* Re-parse a flat form patch into a `TimedRunSettingsPatch`. Empty when the field did not
|
|
2110
|
+
* change; a cleared field is `null` (back to the type's default); a value that is not a
|
|
2111
|
+
* positive number is REFUSED by name, never dropped to an empty patch that looks saved.
|
|
2112
|
+
*/
|
|
2113
|
+
function parseTimedRunFormPatch(patch) {
|
|
2114
|
+
if (!("timedRun_quickRunDuration" in patch)) return {};
|
|
2115
|
+
const raw = patch[TIMED_RUN_QUICK_RUN_KEY];
|
|
2116
|
+
if (raw === null || raw === void 0 || typeof raw === "string" && raw.trim() === "") return { quickRunDuration: null };
|
|
2117
|
+
const value = typeof raw === "number" ? raw : Number(raw);
|
|
2118
|
+
if (!Number.isFinite(value) || value <= 0) throw new Error(`timed-run: the one-tap run must be a positive number, got ${String(raw)}`);
|
|
2119
|
+
return { quickRunDuration: value };
|
|
2120
|
+
}
|
|
2121
|
+
//#endregion
|
|
2084
2122
|
//#region src/builtins/device-manager/recording-onboard-config-schema.ts
|
|
2085
2123
|
var KEY_PREFIX = "recordingOnboard_";
|
|
2086
2124
|
var RECORDING_ONBOARD_KEYS = {
|
|
@@ -2585,6 +2623,7 @@ var STREAM_PARAMS_BUILDER_ID = "stream-params";
|
|
|
2585
2623
|
var DAY_NIGHT_BUILDER_ID = "day-night";
|
|
2586
2624
|
var IMAGE_SETTINGS_BUILDER_ID = "image-settings";
|
|
2587
2625
|
var RECORDING_ONBOARD_BUILDER_ID = "recording-onboard";
|
|
2626
|
+
var TIMED_RUN_BUILDER_ID = "timed-run";
|
|
2588
2627
|
var STREAM_PARAMS_REDUCER = {
|
|
2589
2628
|
kind: "profile",
|
|
2590
2629
|
buildSchema: (options, status) => require_dist.buildStreamParamsConfigSchema(options, status ?? null),
|
|
@@ -2610,11 +2649,17 @@ var RECORDING_ONBOARD_REDUCER = {
|
|
|
2610
2649
|
buildSchema: (options, status) => buildRecordingOnboardConfigSchema(options, status ?? null),
|
|
2611
2650
|
parsePatch: (patch) => parseRecordingOnboardFormPatch(patch)
|
|
2612
2651
|
};
|
|
2652
|
+
var TIMED_RUN_REDUCER = {
|
|
2653
|
+
kind: "settings",
|
|
2654
|
+
buildSchema: (options, status) => buildTimedRunConfigSchema(options, status ?? null),
|
|
2655
|
+
parsePatch: (patch) => parseTimedRunFormPatch(patch)
|
|
2656
|
+
};
|
|
2613
2657
|
var BUILDER_REDUCERS = {
|
|
2614
2658
|
[STREAM_PARAMS_BUILDER_ID]: STREAM_PARAMS_REDUCER,
|
|
2615
2659
|
[DAY_NIGHT_BUILDER_ID]: DAY_NIGHT_REDUCER,
|
|
2616
2660
|
[IMAGE_SETTINGS_BUILDER_ID]: IMAGE_SETTINGS_REDUCER,
|
|
2617
|
-
[RECORDING_ONBOARD_BUILDER_ID]: RECORDING_ONBOARD_REDUCER
|
|
2661
|
+
[RECORDING_ONBOARD_BUILDER_ID]: RECORDING_ONBOARD_REDUCER,
|
|
2662
|
+
[TIMED_RUN_BUILDER_ID]: TIMED_RUN_REDUCER
|
|
2618
2663
|
};
|
|
2619
2664
|
function resolveReducer(builderId) {
|
|
2620
2665
|
const reducer = BUILDER_REDUCERS[builderId];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Aa as siteZoneKey, Ac as DeviceType, Cr as enumerateSchemaFields, Cs as WELL_KNOWN_TAB_MAP, Dr as expandContainer, Ec as userError, Fn as canonicalIconKey, L as DAY_NAMES, Lr as formatMinutes, Mc as EventCategory, Mi as normalizeUnit, Mn as buildStreamParamsConfigSchema, Ns as collectZodSecretPaths, Oc as DeviceFeature, Q as DiscoveryProposalBodySchema, Qs as isKeychainStoredField, Sc as sleep$1, Sr as enumerateItemArrayFields, Tc as transformSecretWrite, Uo as BaseAddon, X as DeviceStatusSchema, Ys as isDeviceConfigCap, Yt as STREAM_PROFILE_META, Z as DeviceTombstoneSchema, _ as CAMERA_SWITCH_ORDER, _c as resolveSecretMarkers, ai as legacyAutoLinkIds, br as deviceStatusCapability, ct as FieldClaimSchema, ec as isSecretClear, gr as deviceManagerCapability, jc as errMsg, kc as DeviceRole, lr as defineExtensionSlotProvider, mr as deviceExtensionCapability, nc as isSecretMarker, rc as isSecretMarkerLike, s as ALL_CAPABILITY_DEFINITIONS, st as FieldClaimModeSchema, tr as createDeviceExtensionProvider, ui as locationIconKey, vs as SECRET_CLEAR, wc as toSecretFieldView, wt as MINUTES_PER_DAY, y as CAP_NAMES_WITH_STATUS, ya as runtimeStatePolicyFor, yc as secretTreeFromPaths, yr as deviceStateCapability, zi as parseStreamParamsFormPatch, zs as defineRecordKinds } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
3
|
import { t as prefixRange } from "../../prefix-range-Dl0znowN.mjs";
|
|
4
4
|
import { t as loadPrefixed } from "../../prefix-walk-DAOBSyH1.mjs";
|
|
@@ -2076,6 +2076,44 @@ function parseImageSettingsFormPatch(patch) {
|
|
|
2076
2076
|
return out;
|
|
2077
2077
|
}
|
|
2078
2078
|
//#endregion
|
|
2079
|
+
//#region src/builtins/device-manager/timed-run-config-schema.ts
|
|
2080
|
+
var TIMED_RUN_QUICK_RUN_KEY = "timedRun_quickRunDuration";
|
|
2081
|
+
function buildTimedRunConfigSchema(options, status) {
|
|
2082
|
+
return { sections: [{
|
|
2083
|
+
id: "timed-run",
|
|
2084
|
+
tab: "general",
|
|
2085
|
+
title: "One-tap run",
|
|
2086
|
+
titleKey: "server:section.s_timed-run.title",
|
|
2087
|
+
description: "How long the Run button starts this device for. The hub switches it off when the time is up.",
|
|
2088
|
+
descriptionKey: "server:section.s_timed-run.description",
|
|
2089
|
+
columns: 1,
|
|
2090
|
+
fields: [{
|
|
2091
|
+
type: "number",
|
|
2092
|
+
key: TIMED_RUN_QUICK_RUN_KEY,
|
|
2093
|
+
label: "One-tap run",
|
|
2094
|
+
labelKey: "server:timedRunConfig.timedRun_quickRunDuration.label",
|
|
2095
|
+
unit: options.unit,
|
|
2096
|
+
min: 1,
|
|
2097
|
+
max: options.maxDuration,
|
|
2098
|
+
step: 1,
|
|
2099
|
+
default: status?.quickRun?.duration ?? options.defaultDuration
|
|
2100
|
+
}]
|
|
2101
|
+
}] };
|
|
2102
|
+
}
|
|
2103
|
+
/**
|
|
2104
|
+
* Re-parse a flat form patch into a `TimedRunSettingsPatch`. Empty when the field did not
|
|
2105
|
+
* change; a cleared field is `null` (back to the type's default); a value that is not a
|
|
2106
|
+
* positive number is REFUSED by name, never dropped to an empty patch that looks saved.
|
|
2107
|
+
*/
|
|
2108
|
+
function parseTimedRunFormPatch(patch) {
|
|
2109
|
+
if (!("timedRun_quickRunDuration" in patch)) return {};
|
|
2110
|
+
const raw = patch[TIMED_RUN_QUICK_RUN_KEY];
|
|
2111
|
+
if (raw === null || raw === void 0 || typeof raw === "string" && raw.trim() === "") return { quickRunDuration: null };
|
|
2112
|
+
const value = typeof raw === "number" ? raw : Number(raw);
|
|
2113
|
+
if (!Number.isFinite(value) || value <= 0) throw new Error(`timed-run: the one-tap run must be a positive number, got ${String(raw)}`);
|
|
2114
|
+
return { quickRunDuration: value };
|
|
2115
|
+
}
|
|
2116
|
+
//#endregion
|
|
2079
2117
|
//#region src/builtins/device-manager/recording-onboard-config-schema.ts
|
|
2080
2118
|
var KEY_PREFIX = "recordingOnboard_";
|
|
2081
2119
|
var RECORDING_ONBOARD_KEYS = {
|
|
@@ -2580,6 +2618,7 @@ var STREAM_PARAMS_BUILDER_ID = "stream-params";
|
|
|
2580
2618
|
var DAY_NIGHT_BUILDER_ID = "day-night";
|
|
2581
2619
|
var IMAGE_SETTINGS_BUILDER_ID = "image-settings";
|
|
2582
2620
|
var RECORDING_ONBOARD_BUILDER_ID = "recording-onboard";
|
|
2621
|
+
var TIMED_RUN_BUILDER_ID = "timed-run";
|
|
2583
2622
|
var STREAM_PARAMS_REDUCER = {
|
|
2584
2623
|
kind: "profile",
|
|
2585
2624
|
buildSchema: (options, status) => buildStreamParamsConfigSchema(options, status ?? null),
|
|
@@ -2605,11 +2644,17 @@ var RECORDING_ONBOARD_REDUCER = {
|
|
|
2605
2644
|
buildSchema: (options, status) => buildRecordingOnboardConfigSchema(options, status ?? null),
|
|
2606
2645
|
parsePatch: (patch) => parseRecordingOnboardFormPatch(patch)
|
|
2607
2646
|
};
|
|
2647
|
+
var TIMED_RUN_REDUCER = {
|
|
2648
|
+
kind: "settings",
|
|
2649
|
+
buildSchema: (options, status) => buildTimedRunConfigSchema(options, status ?? null),
|
|
2650
|
+
parsePatch: (patch) => parseTimedRunFormPatch(patch)
|
|
2651
|
+
};
|
|
2608
2652
|
var BUILDER_REDUCERS = {
|
|
2609
2653
|
[STREAM_PARAMS_BUILDER_ID]: STREAM_PARAMS_REDUCER,
|
|
2610
2654
|
[DAY_NIGHT_BUILDER_ID]: DAY_NIGHT_REDUCER,
|
|
2611
2655
|
[IMAGE_SETTINGS_BUILDER_ID]: IMAGE_SETTINGS_REDUCER,
|
|
2612
|
-
[RECORDING_ONBOARD_BUILDER_ID]: RECORDING_ONBOARD_REDUCER
|
|
2656
|
+
[RECORDING_ONBOARD_BUILDER_ID]: RECORDING_ONBOARD_REDUCER,
|
|
2657
|
+
[TIMED_RUN_BUILDER_ID]: TIMED_RUN_REDUCER
|
|
2613
2658
|
};
|
|
2614
2659
|
function resolveReducer(builderId) {
|
|
2615
2660
|
const reducer = BUILDER_REDUCERS[builderId];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `timed-run` - server-side `ConfigUISchema` builder + form-patch parser (D14).
|
|
3
|
+
* Sibling of `day-night-config-schema.ts`, registered against the `timed-run`
|
|
4
|
+
* builderId in `device-config-contribution.ts`.
|
|
5
|
+
*
|
|
6
|
+
* One field: the duration the one-tap "Run" button starts this device for, in
|
|
7
|
+
* the unit the type thinks in. The bound is the type's maximum - the same safety
|
|
8
|
+
* bound `runFor` refuses above - so the form cannot offer what the cap refuses.
|
|
9
|
+
*/
|
|
10
|
+
import type { ConfigUISchema, TimedRunOptions, TimedRunSettingsPatch, TimedRunStatus } from "@camstack/types";
|
|
11
|
+
export declare const TIMED_RUN_QUICK_RUN_KEY = "timedRun_quickRunDuration";
|
|
12
|
+
export declare function buildTimedRunConfigSchema(options: TimedRunOptions, status: TimedRunStatus | null): ConfigUISchema | null;
|
|
13
|
+
/**
|
|
14
|
+
* Re-parse a flat form patch into a `TimedRunSettingsPatch`. Empty when the field did not
|
|
15
|
+
* change; a cleared field is `null` (back to the type's default); a value that is not a
|
|
16
|
+
* positive number is REFUSED by name, never dropped to an empty patch that looks saved.
|
|
17
|
+
*/
|
|
18
|
+
export declare function parseTimedRunFormPatch(patch: Record<string, unknown>): TimedRunSettingsPatch;
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
const require_formatter = require("../../formatter-xbxeV4GD.js");
|
|
8
8
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
9
9
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Uo as BaseAddon, pi as logDestinationCapability } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-DkYZ4LXp.mjs";
|
|
3
3
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
4
4
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -3,11 +3,11 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
7
|
-
const require_device_ca = require("../../device-ca-
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
|
+
const require_device_ca = require("../../device-ca-DgZeLVC1.js");
|
|
8
8
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
9
|
-
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-
|
|
10
|
-
const require_constants = require("../../constants-
|
|
9
|
+
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-MRr8Ncb_.js");
|
|
10
|
+
const require_constants = require("../../constants-D5CG3Gvc.js");
|
|
11
11
|
const require_platform_key_source = require("../../platform-key-source-Di7HrlGR.js");
|
|
12
12
|
let node_crypto = require("node:crypto");
|
|
13
13
|
let _camstack_types_node = require("@camstack/types/node");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { d as JWT_SIGNING_KEY_REF, n as DEVICE_CA_KEY_REF, p as SYSTEM_SECRET_OWNER } from "../../device-ca-
|
|
1
|
+
import { Mc as EventCategory, Uo as BaseAddon, Us as formatSecretScope, _t as KEYCHAIN_RESET_TRIGGER_ACTOR, ii as keychainCapability, pc as parseSecretRef, ri as keychainAdminCapability, uc as normalizeSecretOwner, vt as KeychainAuditEntrySchema, yt as KeychainResetRecordSchema, zs as defineRecordKinds } from "../../dist-ze-qVU7x.mjs";
|
|
2
|
+
import { d as JWT_SIGNING_KEY_REF, n as DEVICE_CA_KEY_REF, p as SYSTEM_SECRET_OWNER } from "../../device-ca-Dk2sx_18.mjs";
|
|
3
3
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
4
|
-
import { t as LEGACY_INTEGRATION_ROWS_TABLE } from "../../legacy-integration-rows-door-
|
|
5
|
-
import { a as MESH_CA_KEY_REF } from "../../constants-
|
|
4
|
+
import { t as LEGACY_INTEGRATION_ROWS_TABLE } from "../../legacy-integration-rows-door-BvEFQrAa.mjs";
|
|
5
|
+
import { a as MESH_CA_KEY_REF } from "../../constants-GCrIKhD_.mjs";
|
|
6
6
|
import { n as getPlatformKeychainKey } from "../../platform-key-source-BWlq0jjn.mjs";
|
|
7
7
|
import { createCipheriv, createDecipheriv, createHmac, randomBytes, randomUUID, timingSafeEqual } from "node:crypto";
|
|
8
8
|
import { restrictDirToOwnerSync, restrictFileToOwnerSync, writeOwnerOnlyFileSync } from "@camstack/types/node";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist
|
|
3
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
4
4
|
let node_fs = require("node:fs");
|
|
5
5
|
let node_path = require("node:path");
|
|
6
6
|
node_path = require_chunk.__toESM(node_path);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Bt as RECORDING_SOURCE_CAMSTACK_ADDON, Mc as EventCategory, Ps as createEvent, Uo as BaseAddon, Ut as RecordingStatusSchema, _i as mayWriteToLocation, jc as errMsg } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { constants } from "node:fs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import * as fsp from "node:fs/promises";
|
|
@@ -3,10 +3,10 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
const require_safe_buffer$1 = require("../../safe-buffer-D3aoa-7X.js");
|
|
8
8
|
const require_ms$1 = require("../../ms-LB3giGoU.js");
|
|
9
|
-
const require_device_ca = require("../../device-ca-
|
|
9
|
+
const require_device_ca = require("../../device-ca-DgZeLVC1.js");
|
|
10
10
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
11
11
|
let zod = require("zod");
|
|
12
12
|
let node_crypto = require("node:crypto");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { i as __require, o as __toESM, t as __commonJSMin } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { An as buildDeviceEnrollmentLink, B as DEVICE_ENROLLMENT_TTL_MS, Cn as authProviderCapability, Ec as userError, Ir as formatDeviceRevoker, It as PreferenceDeviceIdSchema, Lt as PreferenceNamespaceSchema, M as CredentialTokenClaimsSchema, Qt as ScopedTokenSchema, Rt as PreferenceValueSchema, T as CREDENTIAL_TOKEN_AUDIENCE, U as DEVICE_NONCE_TTL_MS, Uo as BaseAddon, Xa as userManagementCapability, Yr as isCredentialTokenPayload, ac as makeSecretMarker, en as SsoBridgeClaimsSchema, jn as buildDeviceSignatureMessage, jt as PREFERENCES_MAX_VALUE_BYTES, ln as UserRecordSchema, nc as isSecretMarker, pr as deviceCredentialsCapability, sn as TokenScopeSchema, zs as defineRecordKinds } from "../../dist-ze-qVU7x.mjs";
|
|
3
3
|
import { t as require_safe_buffer } from "../../safe-buffer-B1OjL1I9.mjs";
|
|
4
4
|
import { t as require_ms } from "../../ms-CgH2OFlD.mjs";
|
|
5
|
-
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-
|
|
5
|
+
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-Dk2sx_18.mjs";
|
|
6
6
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import * as crypto$1 from "node:crypto";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist
|
|
3
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
4
4
|
const require_dns_wire = require("../../dns-wire-B1BvF9Ao.js");
|
|
5
|
-
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-
|
|
5
|
+
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-D4g9qsNL.js");
|
|
6
6
|
let zod = require("zod");
|
|
7
7
|
let node_net = require("node:net");
|
|
8
8
|
let node_fs = require("node:fs");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Hi as pickAppLinkHub, Is as defineAddonMigrations, Kr as isAppLinkBase, Mc as EventCategory, Oa as shortHostname, Qa as validateCustomAddress, Rn as checkRoleAddress, Uo as BaseAddon, Xr as isDefaultAppConnectionEndpoint, ft as HUB_MDNS_SERVICE_TYPE, jc as errMsg, kt as NetworkTunnelStartedDataSchema, li as localNetworkCapability, ma as resolveNotificationTapAddress, oa as resolveAppConnections, pt as HUB_MDNS_TXT_KEYS, qi as preconditionOf, ua as resolveHubAddressRoles, v as CAMSTACK_APP_LINK_ORIGIN } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { a as emptyMdnsRecords, c as parseMdnsMessage, i as buildRecordQuery, l as parseMdnsRecords, n as MDNS_PORT, o as mergeMdnsRecords, r as buildPtrQuery, s as normalizeServiceType, t as MDNS_GROUP } from "../../dns-wire-Dm3H_7ST.mjs";
|
|
3
|
-
import { E as ensureTlsCert, I as readLanHttpState, N as applyLanHttp, _ as readTlsMode, a as storeUploadedCertificate, b as writeTlsEnabled, d as servedHttpsLeafFingerprint, h as readTlsAccessStatus, i as revertToGeneratedCertificate, j as DEFAULT_LAN_HTTP_PORT, m as readExtraSans, n as applyCertificateToListener, o as useStoredUploadedCertificate, r as regenerateCertificate, t as createCiaoPublisher, y as writeExtraSans } from "../../hub-mdns-ciao-
|
|
3
|
+
import { E as ensureTlsCert, I as readLanHttpState, N as applyLanHttp, _ as readTlsMode, a as storeUploadedCertificate, b as writeTlsEnabled, d as servedHttpsLeafFingerprint, h as readTlsAccessStatus, i as revertToGeneratedCertificate, j as DEFAULT_LAN_HTTP_PORT, m as readExtraSans, n as applyCertificateToListener, o as useStoredUploadedCertificate, r as regenerateCertificate, t as createCiaoPublisher, y as writeExtraSans } from "../../hub-mdns-ciao-DD2QP3w5.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
import { isIP } from "node:net";
|
|
6
6
|
import { readFileSync } from "node:fs";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
const require_log_read_filter = require("../../log-read-filter-Bi066jwU.js");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Is as defineAddonMigrations, Rs as defineEntryKind, Tn as bareAddonId, Uo as BaseAddon, Vr as integrationInstancesCapability, Zs as isInstanceEnabled, _s as RevConflictError, ei as isSameAddonId, fs as RecordIntegrationInstances, nc as isSecretMarker, pi as logDestinationCapability, qi as preconditionOf, tc as isSecretFieldView } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { n as compileLogFilter, o as lineMatches } from "../../log-read-filter-D7Ev3zm-.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
let node_fs = require("node:fs");
|
|
8
8
|
node_fs = require_chunk.__toESM(node_fs);
|
|
9
9
|
let node_fs_promises = require("node:fs/promises");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fr as foldSnapshotByFunction, Ht as ROOT_BUCKET_KEY, Mc as EventCategory, Ps as createEvent, Si as metricsProviderCapability, Uo as BaseAddon, cn as UNATTRIBUTED_BUCKET_KEY, jc as errMsg, sa as resolveBucketMs, ta as reducePoints } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import * as fs$1 from "node:fs";
|
|
3
3
|
import { constants, readFileSync } from "node:fs";
|
|
4
4
|
import { access, readFile, readdir } from "node:fs/promises";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
const require_coral_accelerators = require("../../coral-accelerators-BSVsBVzt.js");
|
|
8
8
|
let node_fs = require("node:fs");
|
|
9
9
|
node_fs = require_chunk.__toESM(node_fs);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { o as __toESM, r as __exportAll } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { Ca as scoreRuntimes, Li as parseAcceleratorFactsJson, Mc as EventCategory, Uo as BaseAddon, Vs as emitReadiness, Wi as platformProbeCapability, jc as errMsg, xr as enumerateInferenceDevices } from "../../dist-ze-qVU7x.mjs";
|
|
3
3
|
import { n as detectCoralAccelerator, r as nodeCoralFs } from "../../coral-accelerators-DBlgWB8k.mjs";
|
|
4
4
|
import * as fs$1 from "node:fs";
|
|
5
5
|
import * as path$1 from "node:path";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
//#region src/builtins/record-entries/entries-service.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $i as recordEntriesCapability,
|
|
1
|
+
import { $i as recordEntriesCapability, $o as InvalidRecordError, Ss as UnknownRecordKindError, Uo as BaseAddon, xc as secretViewsOf } from "../../dist-ze-qVU7x.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { randomUUID } from "node:crypto";
|
|
4
4
|
//#region src/builtins/record-entries/entries-service.ts
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist
|
|
6
|
+
const require_dist = require("../../dist-D5nGm8Sd.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
9
9
|
/**
|