Commit 42c887d9 authored by 张彦钊's avatar 张彦钊

add print

parent be8e9ff8
......@@ -171,9 +171,7 @@ def update_sql_dairy_queue(queue_name, diary_id,device_id, city_id):
cursor.execute(sql)
db.commit()
db.close()
global update_queue_numbers
update_queue_numbers += 1
print("更新队列总个数:{}".format(update_queue_numbers))
print("成功写入diary_id")
def get_queue(device_id, city_id,queue_name):
......
......@@ -63,7 +63,11 @@ def queue_compare(old_list, new_list):
for key in x_dict.keys():
if x_dict[key] != y_dict[key]:
i += 1
global update_queue_numbers
print("更新日记队列总数:{}".format(update_queue_numbers))
if i >0:
update_queue_numbers += 1
print("更新日记队列总数:{}".format(update_queue_numbers))
print("日记队列更新前日记总个数{},位置发生变化个数{},发生变化率{}%".format(len(old_list), i,
round(i / len(old_list) * 100), 2))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment