openhab-core/bundles/org.openhab.core.thing
Cody Cutrer 35a70064c4
Fix CommunicationManager erroring on unusual item<->channel link (#3326)
Some bindings that dynamically create channels (mqtt.homie) might create
a channel that declares itself as Number:Dimensionless because the
end-device metadata has a unit of "%". But a savvy user might want to
link that to a Dimmer or Rollershutter item depending on what the device
actually is. This actually works just fine since QuantityType (with unit
PERCENT) and PercentType implicitly convert between each other. Except
this odd compatibility code in CommunicationManager that tries to assist
bindings that _aren't_ QuantityType compatible. It assumes if the channel's
item type is a dimensioned item, that the actual Item is a NumberItem,
and casts without checking. All this does is checks for that case to avoid
a ClassCastException.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
2023-01-23 20:53:24 +01:00
..
src Fix CommunicationManager erroring on unusual item<->channel link (#3326) 2023-01-23 20:53:24 +01:00
.classpath Update Eclipse .classpath files (#3250) 2022-12-22 14:14:35 +01:00
.project mavenize openHAB and integrate mavenized ESH repository (#467) 2019-01-28 13:07:31 +01:00
NOTICE Updated NOTICE files to openHAB (#578) 2019-02-15 10:46:18 +01:00
pom.xml Fix spotless and resolve itests (#3239) 2022-12-19 11:09:31 +01:00