Update import.py
All checks were successful
/ test (push) Successful in 9m38s

This commit is contained in:
frank 2024-08-10 14:58:05 +00:00
parent b1d1f1f50b
commit 8ebb0f7cb7

View file

@ -69,7 +69,7 @@ def send_tsdb(sensor:str, data: dict[str, dict[int, float]]) -> None:
params = {
'token': tsdb_token
}
print(f'SAVE {sensor}/{metric} @{ts} ={value}')
#print(f'SAVE {sensor}/{metric} @{ts} ={value}')
r = requests.post(url, json=d, params=params)
r.raise_for_status()
@ -84,7 +84,7 @@ if __name__ == '__main__':
]
ts_end = int(time.time())
ts_start = ts_end - 3600*28
ts_start = ts_end - 3600*32
for (sensor, (device_id, module_id), metrics) in sensors:
print(f'Will import {sensor} with {device_id}/{module_id} and {metrics}')