@riddix/hamh 2.1.0-alpha.487 → 2.1.0-alpha.489
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/dist/backend/cli.js
CHANGED
|
@@ -146742,8 +146742,7 @@ var init_bridge_config_schema = __esm({
|
|
|
146742
146742
|
description: "Add an OnOff cluster to robot vacuum endpoints. Alexa REQUIRES this (PowerController) to show robotic vacuums in the app. Without it, Alexa commissions the device but never displays it. In Server Mode this is enabled automatically \u2014 only check this for bridge mode. WARNING: OnOff is NOT part of the Matter RVC device type specification. Enabling this may break Apple Home (shows 'Updating') and Google Home.",
|
|
146743
146743
|
type: "boolean"
|
|
146744
146744
|
}
|
|
146745
|
-
}
|
|
146746
|
-
additionalProperties: false
|
|
146745
|
+
}
|
|
146747
146746
|
};
|
|
146748
146747
|
bridgeConfigSchema = {
|
|
146749
146748
|
type: "object",
|
|
@@ -177777,6 +177776,7 @@ var LegacyEndpoint = class _LegacyEndpoint extends EntityEndpoint {
|
|
|
177777
177776
|
this.flushUpdate = debounce4(this.flushPendingUpdate.bind(this), 50);
|
|
177778
177777
|
}
|
|
177779
177778
|
lastState;
|
|
177779
|
+
pendingMappedChange = false;
|
|
177780
177780
|
flushUpdate;
|
|
177781
177781
|
async delete() {
|
|
177782
177782
|
this.flushUpdate.clear();
|
|
@@ -177789,6 +177789,7 @@ var LegacyEndpoint = class _LegacyEndpoint extends EntityEndpoint {
|
|
|
177789
177789
|
return;
|
|
177790
177790
|
}
|
|
177791
177791
|
if (mappedChanged) {
|
|
177792
|
+
this.pendingMappedChange = true;
|
|
177792
177793
|
logger198.debug(
|
|
177793
177794
|
`Mapped entity change detected for ${this.entityId}, forcing update`
|
|
177794
177795
|
);
|
|
@@ -177807,8 +177808,13 @@ var LegacyEndpoint = class _LegacyEndpoint extends EntityEndpoint {
|
|
|
177807
177808
|
}
|
|
177808
177809
|
try {
|
|
177809
177810
|
const current = this.stateOf(HomeAssistantEntityBehavior).entity;
|
|
177811
|
+
let effectiveState = state;
|
|
177812
|
+
if (this.pendingMappedChange) {
|
|
177813
|
+
this.pendingMappedChange = false;
|
|
177814
|
+
effectiveState = { ...state, last_updated: (/* @__PURE__ */ new Date()).toISOString() };
|
|
177815
|
+
}
|
|
177810
177816
|
await this.setStateOf(HomeAssistantEntityBehavior, {
|
|
177811
|
-
entity: { ...current, state }
|
|
177817
|
+
entity: { ...current, state: effectiveState }
|
|
177812
177818
|
});
|
|
177813
177819
|
} catch (error) {
|
|
177814
177820
|
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
@@ -179644,6 +179650,7 @@ var ServerModeVacuumEndpoint = class _ServerModeVacuumEndpoint extends EntityEnd
|
|
|
179644
179650
|
);
|
|
179645
179651
|
}
|
|
179646
179652
|
lastState;
|
|
179653
|
+
pendingMappedChange = false;
|
|
179647
179654
|
flushUpdate;
|
|
179648
179655
|
constructor(type, entityId, customName, mappedEntityIds) {
|
|
179649
179656
|
super(type, entityId, customName, mappedEntityIds);
|
|
@@ -179660,6 +179667,7 @@ var ServerModeVacuumEndpoint = class _ServerModeVacuumEndpoint extends EntityEnd
|
|
|
179660
179667
|
return;
|
|
179661
179668
|
}
|
|
179662
179669
|
if (mappedChanged) {
|
|
179670
|
+
this.pendingMappedChange = true;
|
|
179663
179671
|
logger201.debug(
|
|
179664
179672
|
`Mapped entity change detected for ${this.entityId}, forcing update`
|
|
179665
179673
|
);
|
|
@@ -179678,8 +179686,13 @@ var ServerModeVacuumEndpoint = class _ServerModeVacuumEndpoint extends EntityEnd
|
|
|
179678
179686
|
}
|
|
179679
179687
|
try {
|
|
179680
179688
|
const current = this.stateOf(HomeAssistantEntityBehavior).entity;
|
|
179689
|
+
let effectiveState = state;
|
|
179690
|
+
if (this.pendingMappedChange) {
|
|
179691
|
+
this.pendingMappedChange = false;
|
|
179692
|
+
effectiveState = { ...state, last_updated: (/* @__PURE__ */ new Date()).toISOString() };
|
|
179693
|
+
}
|
|
179681
179694
|
await this.setStateOf(HomeAssistantEntityBehavior, {
|
|
179682
|
-
entity: { ...current, state }
|
|
179695
|
+
entity: { ...current, state: effectiveState }
|
|
179683
179696
|
});
|
|
179684
179697
|
} catch (error) {
|
|
179685
179698
|
if (error instanceof TransactionDestroyedError || error instanceof DestroyedDependencyError) {
|