Dymerz / SMA-SunnyBoy

A simple data retrieving from SMA SunnyBoy
https://sma-sunnyboy.readthedocs.io/en/latest/sma_sunnyboy.html
MIT License
39 stars 9 forks source link

[BUG] Insequre HTTPS reques warning, and not working connection #24

Open kollokollo opened 1 year ago

kollokollo commented 1 year ago

Describe the bug The function client.auth() produces errors/warnings in an infinite loop. No connection to Inverter prossible.

To Reproduce Code causing the bug:

from sma_sunnyboy import *
client = WebConnect("192.168.188.47", Right.USER, "password")
client.auth()

Error Message:

  warnings.warn(
/usr/lib/python3/dist-packages/urllib3/connectionpool.py:999: InsecureRequestWarning: Unverified HTTPS request is being made to host '192.168.188.47'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  1. See error

Expected behavior

authentificate and continue with python script reading values etc...

Actual behavior

Script procudes 10 times this warning and then hangs.

Hardware (please complete the following information):

bfaucon commented 1 year ago

Hello, I've the same issue. Warning about https, retry then Hang. I try to remove the https warning but without success...

frankusb commented 1 year ago

Try client = WebConnect("192.168.188.47", Right.USER, "password", 443, True)

For me It required setting the port and useSSL.