travisghansen / hass-opnsense

OPNsense integration with Home Assistant
194 stars 25 forks source link

InsecureRequestWarning: Unverified HTTPS request is being made to... #88

Closed heyitsyang closed 1 year ago

heyitsyang commented 1 year ago

This error started spamming my Home Assistant logs after updating to HA Ver 2023.6.1. It generates a lot of log entries.

Logger: py.warnings
Source: custom_components/opnsense/pyopnsense/__init__.py:167
Integration: OPNsense (documentation, issues)
First occurred: 8:09:13 PM (151 occurrences)
Last logged: 9:28:43 PM

/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py:1056: InsecureRequestWarning: Unverified HTTPS request is being made to host '10.27.0.1'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings warnings.warn(
travisghansen commented 1 year ago

87

heyitsyang commented 1 year ago

Thanks. I obviously didn't see #87. For reference this has been reported in the Home Assistant Core as #94243.

heyitsyang commented 1 year ago

Closing

alexdelprete commented 1 year ago

While they solve the issue, a workaround is this:

logger:
  default: info
  logs:
    requests.packages.urllib3.connectionpool: critical
vk2him commented 1 year ago

Apparently there's a better short term solution - add this to beneath logger:

filters: py.warnings: