I'm trying to convert this line of code :
array_of_power1.append(dict(measurement=topic_mqtt_power1,timestamp=int(epoch_time_stamp * 1000000000),fields=dict(power=power1),tags=dict(MachineType=Machine_type,MachineName=Machine_name)))
into
array_of_power1.append({'measurement' : 'topic_mqtt_power1', 'timestamp' : 'epoch_time_stamp' * 1000000000, fields: {'power' : 'power1'}, tags: {MachineType : Machinetype, MachineName : Machine_name}})
and I'm getting
Traceback (most recent call last): File "", line 1, in OverflowError: repeated string is too long
The reason why I'm changing from the dict struct to the other method is that the dict struct "dict()" doesnt work in micropython.
'epoch_time_stamp' * 1000000000you are writing epoch_time_stamp 1000000000 time, remove the*- Matteo Peluso