feat(node): push USB changes and preserve sensor setup across sessions
This commit is contained in:
@@ -27,6 +27,9 @@ class FleetRegistry:
|
||||
self.started_at = time.time()
|
||||
self.root = root
|
||||
self.lock = threading.RLock()
|
||||
from .events import FleetEvents
|
||||
|
||||
self.events = FleetEvents()
|
||||
self.trust = CoreTrust(root)
|
||||
path = root / "fleet.sqlite3"
|
||||
if path.is_symlink():
|
||||
@@ -58,6 +61,7 @@ class FleetRegistry:
|
||||
"ON CONFLICT(id) DO UPDATE SET body=excluded.body",
|
||||
(row["id"], row["node_id"], json.dumps(row)),
|
||||
)
|
||||
self.events.notify()
|
||||
|
||||
def find(self, identifier):
|
||||
result = self.db.execute("SELECT body FROM vehicles WHERE id=?", (identifier,)).fetchone()
|
||||
|
||||
Reference in New Issue
Block a user