@@ -45,9 +45,7 @@ async def send_message(
4545) -> int :
4646
4747 logger .warning (f"Message received '{ data } '" )
48- user_info = await check_permissions (
49- action = ActionType .CREATE , pilot_db = pilot_logs_db
50- )
48+ user_info = await check_permissions (action = ActionType .CREATE )
5149 pilot_id = 0 # need to get pilot id from pilot_stamp (via PilotAgentsDB)
5250 # also add a timestamp to be able to select and delete logs based on pilot creation dates, even if corresponding
5351 # pilots have been already deleted from PilotAgentsDB (so the logs can live longer than pilots).
@@ -93,7 +91,7 @@ async def get_logs(
9391) -> list [dict ]:
9492
9593 logger .warning (f"Retrieving logs for pilot ID '{ pilot_id } '" )
96- user_info = await check_permissions (action = ActionType .QUERY , pilot_db = db )
94+ user_info = await check_permissions (action = ActionType .QUERY )
9795
9896 # here, users with privileged properties will see logs from all VOs. Is it what we want ?
9997 search_params = [{"parameter" : "PilotID" , "operator" : "eq" , "value" : pilot_id }]
@@ -122,7 +120,7 @@ async def delete(
122120 Non-privileged users can only delete log files within their own VO.
123121 """
124122 message = "no-op"
125- user_info = await check_permissions (action = ActionType .DELETE , pilot_db = db )
123+ user_info = await check_permissions (action = ActionType .DELETE )
126124 non_privil_params = {"parameter" : "VO" , "operator" : "eq" , "value" : user_info .vo }
127125
128126 # id pilot_id is provided we ignore data.min and data.max
0 commit comments