Skip to content

Commit

Permalink
Move some logs to debug
Browse files Browse the repository at this point in the history
  • Loading branch information
pipiche38 committed Dec 5, 2024
1 parent 40d28f3 commit ad12b2c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Classes/DomoticzDB.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ def open_and_read(self, url):
:param url: The URL to open.
:return: Response content or None if the request fails.
"""
self.logging("Log", f"Opening URL: {url}")
self.logging("Debug", f"Opening URL: {url}")

# Set up SSL context if necessary
ssl_context = None
Expand All @@ -124,7 +124,7 @@ def open_and_read(self, url):

for retries in range(3, 0, -1):
try:
self.logging("Log", f"Opening URL: {url} with SSL context: {ssl_context} and REQ_TIMEOUT timeout")
self.logging("Debug", f"Opening URL: {url} with SSL context: {ssl_context} and REQ_TIMEOUT timeout")
with urllib.request.urlopen(url, context=ssl_context, timeout=REQ_TIMEOUT) as response:
return response.read()

Expand Down Expand Up @@ -174,7 +174,7 @@ def domoticz_request(self, url):

# Open the URL with a 750ms timeout
try:
self.logging("Status", f"Opening URL: {url} with SSL context: {ssl_context} and REQ_TIMEOUT timeout")
self.logging("Debug", f"Opening URL: {url} with SSL context: {ssl_context} and REQ_TIMEOUT timeout")
with urllib.request.urlopen(request, context=ssl_context, timeout=REQ_TIMEOUT) as response:
return response.read()
except urllib.error.URLError as e:
Expand Down

0 comments on commit ad12b2c

Please sign in to comment.