Skip to content

Commit

Permalink
as dict
Browse files Browse the repository at this point in the history
  • Loading branch information
cnheider committed May 27, 2024
1 parent 3c02f64 commit 44accb7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion heimdallr/entry_points/publisher.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,12 @@ def job():
"""description"""
sensor_data[HOSTNAME]["gpu_stats"] = pull_gpu_info()
sensor_data[HOSTNAME]["du_stats"] = pull_disk_usage_info()

a = sensor_data.as_dict()
assert a is dict
client.publish(
ALL_CONSTANTS.MQTT_TOPIC,
json.dumps(sensor_data.as_dict()),
json.dumps(a),
ALL_CONSTANTS.MQTT_QOS,
)

Expand Down

0 comments on commit 44accb7

Please sign in to comment.