Description
Minor inconvenience yet probably good to report:
This code runs fine, but Pylance with standard type checking complains about the Callback definitions.
Code:
mqttc = mqtt.Client(callback_api_version = mqtt.CallbackAPIVersion.VERSION2, client_id = 'Palert',protocol = mqtt.MQTTv5)
Results in pylance error:
"CallbackAPIVersion" is not exported from module "paho.mqtt.client"
Leave out the mqtt.:
mqttc = mqtt.Client(callback_api_version = CallbackAPIVersion.VERSION2, client_id = 'Palert',protocol = mqtt.MQTTv5)
error = "CallbackAPIVersion" is not defined