The index 'bindenv' does not exist

Under what circumstances would I get this error:

the index ‘bindenv’ does not exist: in checkTemperature device_code:4359

The function checkTemperature is defined as a part of a class and the name is shared with no other object or variable, even one in another scope. The class is instantiated once at the global level.

heaterMonitor ← HeaterMonitor()

const HEATER_MONITOR_INTERVAL = 20

class HeaterMonitor{

	constructor() {
    	checkTemperature()
    }

  	function checkTemperature() {
         // Logic to check temperature is here

	    imp.wakeup(HEATER_MONITOR_INTERVAL,checkTemperature.bindenv(this))
    }

}

Is there anything else called checkTemperature, anywhere else in your program? Can you check the type of “checkTemperature” just before you call bindenv on it?

Peter

Nope, just one definition. The function checkTemperature is defined as a part of a class and the name is shared with no other object or variable, even one in another scope. The class is instantiated once at the global level.

I could check the type, but this has only failed once out of ~10k devices and a function that tends to be called several times a minute per device so I doubt we would learn much.

Could you let me know by DM the device id and a timestamp for the event?

Thanks for the info. This might be an impOS bug, I have raised a ticket to investigate.