no plugin info avilable until ingress happened for any asset
@@ -88,7 +88,11 @@ async def _get_tracked_plugin_assets_and_readings(storage_client, svc_name):
try:
result = await storage_client.query_tbl_with_payload('asset_tracker', payload)
asset_records = result['rows']
- plugin = result['rows'][0]
+
+ plugin = ''
+ if len(result['rows']):
+ plugin = result['rows'][0]['plugin']
+
_readings_client = connect.get_readings_async()
for r in asset_records:
payload = PayloadBuilder().SELECT("value").WHERE(["key", "=", r["asset"].upper()]).payload()
