[P] Send only visible records from store on websocket connection
All checks were successful
Component testing / Hub testing (push) Successful in 21s
Component testing / Store testing (push) Successful in 26s
Component testing / Integration smoke testing (push) Successful in 2m36s

This commit is contained in:
2026-03-27 18:38:22 +02:00
parent 5c3010dcfe
commit ad3c336ecf

View File

@@ -47,7 +47,10 @@ async def websocket_endpoint(websocket: WebSocket):
try:
# send already available data
r = processed_agent_data.select().order_by(processed_agent_data.c.timestamp)
r = processed_agent_data.select() \
.where(processed_agent_data.c.visible == True) \
.order_by(processed_agent_data.c.timestamp)
session = SessionLocal()
stored_data = session.execute(r).fetchall()
session.close()