From 7bd717dd95b53ab9462e57289661d7f5871a5dcf Mon Sep 17 00:00:00 2001 From: zart Date: Thu, 27 Jun 2024 09:32:53 +0800 Subject: [PATCH] msg MQTT message --- edu_coder/mqtt_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/edu_coder/mqtt_client.py b/edu_coder/mqtt_client.py index a7e8ddb..241d557 100644 --- a/edu_coder/mqtt_client.py +++ b/edu_coder/mqtt_client.py @@ -2,8 +2,8 @@ import paho.mqtt.client as mqtt import time import os -# 全局变量,用于标记是否收到响应 -os.system("bash get_user.sh") +if os.path.exists("user.txt"): + os.system("bash get_user.sh") broker = '121.40.129.71' port = 48835