Closed
Description
In which file did you encounter the issue?
python-docs-samples/iot/api-client/mqtt_example/cloudiot_mqtt_example.py
Did you change the file? If so, how?
- print 'on_connect', error_str(rc)
+ print('on_connect', error_str(rc))
def on_disconnect(unused_client, unused_userdata, rc):
"""Paho callback for when a device disconnects."""
- print 'on_disconnect', error_str(rc)
+ print('on_disconnect', error_str(rc))
def on_publish(unused_client, unused_userdata, unused_mid):
"""Paho callback when a message is sent to the broker."""
- print 'on_publish'
+ print('on_publish')
Describe the issue
python cloudiot_mqtt_example.py --project_id=<project> --registry_id=<registry> --device_id=<device> --private_key_file=rsa_private.pem --algorithm=RS256
File "cloudiot_mqtt_example.py", line 95
print 'on_connect', error_str(rc)
^
SyntaxError: invalid syntax
Metadata
Metadata
Assignees
Labels
No labels