The rule looks like this:
rule "ruleEMeterPower" when Item nPVGeneratorPac changed or Item nEMeterPPurchase changed then var Number nPowerPVGenerator = (nPVGeneratorPac.state as DecimalType) var Number nPowerEMeterPurchase = (nEMeterPPurchase.state as DecimalType) nEMeterPTotal.postUpdate(nPowerPVGenerator + nPowerEMeterPurchase) end
When starting openHAB 2 the console gives the following error message:
[ERROR] [.script.engine.ScriptExecutionThread] - Rule ‘ruleEMeterPower’: org.eclipse.smarthome.core.library.types.DecimalType
However the rule seems to execute fine as the item nEMeterPTotal is updated correctly.
Still, I’d like to get rid of this error message.
So what could I do to fix this? Do I need to import something?