Skip to content

Commit 5195bec

Browse files
author
Dympna Laverty
committed
Removed unnecessary debug
1 parent 5977a50 commit 5195bec

File tree

2 files changed

+3
-6
lines changed
  • plugins/duo_admin/komand_duo_admin

2 files changed

+3
-6
lines changed

plugins/duo_admin/komand_duo_admin/tasks/monitor_logs/task.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,6 @@ def run(self, params={}, state={}): # noqa: C901
189189

190190
if new_admin_log_hashes:
191191
state[self.PREVIOUS_ADMIN_LOG_HASHES] = new_admin_log_hashes
192-
self.logger.info(f"{admin_logs_next_page_params} admin_logs_next_page_params DL DEBUG NEW")
193192
if admin_logs_next_page_params:
194193
state[self.ADMIN_LOGS_NEXT_PAGE_PARAMS] = admin_logs_next_page_params
195194
has_more_pages = True

plugins/duo_admin/komand_duo_admin/util/api.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,13 +160,13 @@ def make_request(self, method: str, path: str, params: dict = {}) -> requests.Re
160160
params=params,
161161
headers=self.get_headers(method=method.upper(), host=self.hostname, path=path, params=params),
162162
)
163-
self.logger.info(f"Response data returned in make request: {response.json()}")
163+
164164
#TODO Update to 403
165165
if response.status_code == 401 and path in TASK_PATHS_ALLOW_403:
166166
# Special case: A task user who only has permissions for certain endpoints should not error out.
167-
# Log and return empty response instead
167+
# Log and return an empty response instead
168168
self.logger.info(f"Request to {path} returned 403 unauthorized. Not raising exception as may be authorized to hit other endpoint(s)")
169-
self.logger.info(f"Response data returned: {response.json()}")
169+
self.logger.info(f"403 Response data returned for reference: {response.json()}")
170170
return {}
171171
self._handle_exceptions(response, path)
172172
self.logger.info(f"Response data returned: {response.text}")
@@ -229,8 +229,6 @@ def make_json_request(self, method: str, path: str, params: dict = {}) -> dict:
229229
self.logger.info(f"Request to path: {path}")
230230
response = self.make_request(method=method, path=path, params=params)
231231
if isinstance(response, requests.Response):
232-
self.logger.info(f"response returned DL DEBUG: {response}")
233-
self.logger.info(f"response.json(): {response.json()}")
234232
return response.json()
235233
else:
236234
return response

0 commit comments

Comments
 (0)