nhorvath / python-thermoworks-smoke

Pull data for your thermoworks smoke thermometer
GNU General Public License v3.0
9 stars 8 forks source link

Cannot login #3

Open JRandomHacker opened 3 years ago

JRandomHacker commented 3 years ago

Cannot login from Home Assistant or from python. Error from HA: ERROR (SyncWorker_0) [homeassistant.components.thermoworks_smoke.sensor] Invalid email and password combination Error from calling thermoworks_smoke.initialize_app() directly:

Traceback (most recent call last):
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\pyrebase\pyrebase.py", line 503, in raise_detailed_error
    request_object.raise_for_status()
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\requests\models.py", line 941, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://www.googleapis.com/identitytoolkit/v3/relyingparty/verifyPassword?key=<removed>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\thermoworks_smoke\thermoworks_smoke.py", line 23, in initialize_app
    return ThermoworksDataMgr(email, password, init, exclude_serials)
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\thermoworks_smoke\thermoworks_smoke.py", line 65, in __init__
    self.login()
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\thermoworks_smoke\thermoworks_smoke.py", line 122, in login
    self._email, self._password)
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\pyrebase\pyrebase.py", line 85, in sign_in_with_email_and_password
    raise_detailed_error(request_object)
  File "C:\Users\Justin\AppData\Local\Programs\Python\Python36\lib\site-packages\pyrebase\pyrebase.py", line 507, in raise_detailed_error
    raise HTTPError(e, request_object.text)
requests.exceptions.HTTPError: [Errno 400 Client Error: Bad Request for url: https://www.googleapis.com/identitytoolkit/v3/relyingparty/verifyPassword?key=<removed>] {
  "error": {
    "code": 400,
    "message": "EMAIL_NOT_FOUND",
    "errors": [
      {
        "message": "EMAIL_NOT_FOUND",
        "domain": "global",
        "reason": "invalid"
      }
    ]
  }
}

I'm going to hazard a guess and say this is probably because Thermoworks completely redid their app - do you know if this module is compatible with the new app?

JRandomHacker commented 3 years ago

I attempted decompiling the new app and setting up a new Firebase config, and now I'm getting 401s instead. I suspect I may be missing something in my decompilation.