mirror of
https://github.com/khoj-ai/khoj.git
synced 2025-02-17 16:14:21 +00:00
Update server to log new server version field to telemetry db
This commit is contained in:
parent
bb2363f324
commit
139a3ba060
1 changed files with 2 additions and 1 deletions
|
@ -53,7 +53,7 @@ def v1_telemetry(telemetry_data: List[Dict[str, str]]):
|
|||
# Log telemetry data
|
||||
for item in telemetry_data:
|
||||
cur.execute(
|
||||
"INSERT INTO usage (time, type, server_id, os, api, client) VALUES (?, ?, ?, ?, ?, ?)",
|
||||
"INSERT INTO usage (time, type, server_id, os, api, client, server_version) VALUES (?, ?, ?, ?, ?, ?, ?)",
|
||||
(
|
||||
item["timestamp"],
|
||||
item["telemetry_type"],
|
||||
|
@ -61,6 +61,7 @@ def v1_telemetry(telemetry_data: List[Dict[str, str]]):
|
|||
item["os"],
|
||||
item.get("api"),
|
||||
item.get("client"),
|
||||
item.get("server_version", None),
|
||||
),
|
||||
)
|
||||
# Commit the changes
|
||||
|
|
Loading…
Add table
Reference in a new issue