From f820d1e03cf8d0b13830da8138e26497804345ec Mon Sep 17 00:00:00 2001 From: Garulf <535299+Garulf@users.noreply.github.com> Date: Wed, 22 Feb 2023 11:39:16 -0500 Subject: [PATCH 1/2] Minor version bump --- plugin.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin.json b/plugin.json index cc2f0fd..9e52fba 100644 --- a/plugin.json +++ b/plugin.json @@ -4,7 +4,7 @@ "Name": "HA-Commander", "Description": "Search, and interact with Home Assistant using Wox or Flow Launcher.", "Author": "Garulf", - "Version": "5.0.1", + "Version": "5.1.0", "Language": "python", "Website": "https://github.com/Garulf/HA-Commander", "IcoPath": "icons\\home-assistant.png", From 61241db1f4cca9b063414868bc67134e6133820b Mon Sep 17 00:00:00 2001 From: Garulf <535299+Garulf@users.noreply.github.com> Date: Wed, 22 Feb 2023 11:40:34 -0500 Subject: [PATCH 2/2] Stop warning from printing to console While this warning is important and helpful it causes error with Launcher's expecting STDOUT to be JSON only. --- plugin/homeassistant.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugin/homeassistant.py b/plugin/homeassistant.py index ea88081..7c4b5c7 100644 --- a/plugin/homeassistant.py +++ b/plugin/homeassistant.py @@ -3,6 +3,8 @@ from functools import partial, wraps import webbrowser import logging +import urllib3 +from urllib3.exceptions import InsecureRequestWarning import requests from requests.exceptions import ConnectionError, HTTPError @@ -10,6 +12,8 @@ from icons import DEFAULT_ICONS log = logging.getLogger(__name__) +# This warning prints to stdout and is not catchable so we need to disable it +urllib3.disable_warnings(InsecureRequestWarning) COLORS_FILE = "./plugin/colors.json" META_FILE = "./meta.json"