Skip to content

Commit 04d55f5

Browse files
committed
refactor: remove TODO and the debugging print statements
1 parent 6b9b535 commit 04d55f5

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

deluge_web_client/client.py

+1-11
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,6 @@
1010
from deluge_web_client.types import ParamArgs
1111

1212

13-
# TODO: remove all print statements
14-
15-
1613
class DelugeWebClient:
1714
HEADERS = {"Content-Type": "application/json", "Accept": "application/json"}
1815
ID = 0
@@ -274,7 +271,7 @@ def _upload_helper(
274271
with self.session.post(
275272
self.url, headers=self.HEADERS, json=payload, timeout=timeout
276273
) as response:
277-
self.ID += 1
274+
self.ID += 1
278275
if response.ok:
279276
result = response.json()
280277
info_hash = str(result["result"])
@@ -597,26 +594,19 @@ def execute_call(
597594
self.url, headers=self.HEADERS, json=payload, timeout=timeout
598595
) as response:
599596
self.ID += 1
600-
print("IN HERE LOWER POST")
601-
print(response.status_code)
602-
print(response.ok)
603597
if response.ok:
604-
print(response.json())
605598
response_json = response.json()
606599
data = Response(
607600
result=response_json.get("result"),
608601
error=self._normalize_exception(response_json.get("error")),
609602
id=response_json.get("id"),
610603
)
611604
if handle_error and data.error:
612-
# print('in here')
613605
raise DelugeWebClientError(
614606
f"Payload: {payload}, Error: {data.error}"
615607
)
616-
# print('returning data')
617608
return data
618609
else:
619-
# print('in here 2')
620610
raise DelugeWebClientError(
621611
f"Failed to execute call. Response code: {response.status_code}. Reason: {response.reason}"
622612
)

0 commit comments

Comments
 (0)