simbaja / ha_gehome

GE Home Appliances (SmartHQ) for Home Assistant
MIT License
332 stars 79 forks source link

Failed to setup "Check the logs" after adding custom component #29

Closed joshewing02 closed 2 years ago

joshewing02 commented 3 years ago

I see this in the log and it never populates with any devices. Sets up when entering credentials each time.

Logger: gehomesdk.clients.async_login_flows Source: /usr/local/lib/python3.9/site-packages/gehomesdk/clients/async_login_flows.py:66 First occurred: 7:21:27 AM (1 occurrences) Last logged: 7:21:27 AM

There was a problem getting the authorization code, response details: {'method': 'POST', 'cookies': , '_real_url': URL('https://accounts.brillion.geappliances.com/oauth2/g_authenticate'), '_url': URL('https://accounts.brillion.geappliances.com/oauth2/g_authenticate'), '_body': b'\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n<!DOCTYPE html>\n\n\n OAuth Login\n\n\n\n\n\t\n\t\n\n\n\n\n\n<link\n\thref="/resources/scripts/css/bootstrap.min.css"\n\trel="stylesheet" />\n<link\n\thref="/resources/scripts/css/desktop.css"\n\trel="stylesheet" />\n\n\t<link href="https://fonts.googleapis.com/css?family=Poppins:400,500,600,700,900&display=swap"\n \trel="stylesheet">\n<script\n\tsrc="/resources/scripts/jquery-3.5.1.min.js">\n\n\n\n\n\n\n\n\n \n

\n
\n \n \t\t \n\n\n\n\n\n\n\n\n\t
\n\t
\n\t \n\t
\n\t
\n\t
\n
\n \n

Sign In

\n \n One account across our brands.
\n \n
\n\n\n
\n\n\n\n\n
\n\t\n\t\t
\n\t\t\t\t<input type="hidden" id="client_id" value="564c31616c4f7474434b307435412b4d2f6e7672"\n\t\t\t\t\tname="client_id" />\n\t\t\t\t<input type="hidden" id="response_type" value="code"\n\t\t\t\t\tname="response_type" />\n\t\t\t\t<input type="hidden" id="access_type" value="offline"\n\t\t\t\t\tid="access_type" />\n\t\t
\n\t\t
\n\t\t\t
\n\t\t\t\t<input type="hidden" id="signature" name="signature"\n\t\t\t\t\tvalue="vVLoPdzS242Elr8Q7VEjLwtnFvSSY62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YOvG8sHYlM5Nw8/OyJZf7dsohBZBHCHhq+QvMsQHX28Zx6PP+8YMGhtfpGUBOyI2F2xuEfb91JhxI2caV3ymavlOzTJRbSGjKKaIKt1ML3vVLqyAq0O430C27u+LJp+5GfeCN8+mZcf6Qh1ZClZnaUh/UKWuZc1kMFjoOm77YO8XBcyT1Nq641+2qj44a28SGAU5xe/DCF67KjWcA7tM9oyfhneZLcGypiW66eqGsOpSZp7xbQ/dVNuoUgNEl1pM+g+o041uf9ueVoeLpF5eIIOTEDEPK3/uOePyLrbu6SPtx0BzTlmmnwDiRleqGyRNvluju6WcwkCO4hyh5z+SEojKB2fHlwpw+PVpKLr6FebiPqavGyTfjU72Lr38fuQkmByw/A+YIgS73VN5qb+HHEhiG8NvEKE52Xw1NaLQjAKKkaGc90Oe5bEe0M9oIZPT67JWyxDMewxcVX+Qcno56F+I+SRNNinQRDtZJac4nLwS3/jP0P3tYOQfpVlQX6Ftb6pBBAxJyGwGMM5zT3ujtk4ewiAAqbLOIWIjOjz+aorzhvltBvcaXcUMPvV9tgnYb9YLFKj1oQSq5HNEdUo+ksXXf9n17nb439eNaBMYP7DCUTkccKwJhryLy3X5ZcHv5bDBA==" />\n\t\t\t
\n\t\t\t
\n\t\t\t\t<input type="email" class="form-control" id="username"\n\t\t\t\t\tname="username" placeholder="Username" autocapitalize="off"\n\t\t\t\t\tvalue="joshewing02@hotmail.com" tabindex="1" />\n\t\t\t\t
\n\t\t\t
\n\t\t\t
\n\t\t\t\t<input type="password" class="form-control" id="password"\n\t\t\t\t\tname="password" placeholder="Password" tabindex="2" maxlength="20" />\n\t\t\t\t Show Password
\n\t\t\t\t
\n\t\t\t
\n\t\t\t\n\t\t\t\n\t\t\t
\n\t\t\t<button type="button" id="signin_btn" name="signin_btn" class="btn_signIn btn btn-default btn-primary"\n\t\t\t\tonClick="javascript:oauthLogin()" tabindex="4">\n\t\t\t\t\tSIGN IN\n\t\t\t\t\n\t\t\t
\n\t\t\t
\n
\n
\n
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t\t
Don\'t have an account? Sign up here
\n\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\t\t\t\n\t\t
\n
\n\n\n\n\n\n\n\n\n\n\n\t\n\n\n
\n\t\t
\n\t
\n\n\t\n \t
\n \t
\n
\n
\n
\n

\n Copyright 2020 GE Appliances, a Haier company GE is trademark of General Electric Company.Manufactured under trademark license.\n

\n
\n
\n
\n
\n \t \n\t
\n\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n<script\r\n\tsrc="/resources/scripts/js/bootstrap.min.js">\r\n<script\r\n\tsrc="/resources/scripts/js/bootstrap-show-password.min.js">\r\n<script\r\n\tsrc="/resources/scripts/common.js">\r\n\r\n\r\n\r\n\r\n\n\n', '_writer': None, '_continue': None, '_closed': True, '_history': (), '_request_info': RequestInfo(url=URL('https://accounts.brillion.geappliances.com/oauth2/g_authenticate'), method='POST', headers=<CIMultiDictProxy('Host': 'accounts.brillion.geappliances.com', 'User-Agent': 'HomeAssistant/2021.8.3 aiohttp/3.7.4.post0 Python/3.9', 'Accept': '/', 'Accept-Encoding': 'gzip, deflate', 'Cookie': 'JSESSIONID=70C4F7C40BE2D69ADA526461F962DEEB', 'Content-Length': '1982', 'Content-Type': 'application/x-www-form-urlencoded')>, real_url=URL('https://accounts.brillion.geappliances.com/oauth2/g_authenticate')), '_timer': <aiohttp.helpers.TimerContext object at 0x7fb00295ea90>, '_cache': {'headers': <CIMultiDictProxy('Content-Type': 'text/html;charset=ISO-8859-1', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Date': 'Sat, 07 Aug 2021 14:21:27 GMT', 'X-Amzn-Trace-Id': 'Root=1-610e96e6-4f8930cd12a6cb347a7b4b96;', 'X-Frame-Options': 'SAMEORIGIN', 'X-Content-Type-Options': 'nosniff', 'X-XSS-Protection': '1; mode=block', 'X-Cache': 'Miss from cloudfront', 'Via': '1.1 bc026bbeb6351b9fc6315a678d5987e7.cloudfront.net (CloudFront)', 'X-Amz-Cf-Pop': 'LAX3-C4', 'X-Amz-Cf-Id': 'yB0Cg-z7c0Z_YvcJWaBVnWG3OkJ_63ieOZoCNd_vB0FECi-4W8TxTg==')>, 'url': URL('https://accounts.brillion.geappliances.com/oauth2/g_authenticate')}, '_traces': [], '_loop': <_UnixSelectorEventLoop running=True closed=False debug=False>, '_session': None, '_protocol': <aiohttp.client_proto.ResponseHandler object at 0x7fb002b3ee20>, '_connection': None, 'version': HttpVersion(major=1, minor=1), 'status': 200, 'reason': '', '_headers': <CIMultiDictProxy('Content-Type': 'text/html;charset=ISO-8859-1', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Date': 'Sat, 07 Aug 2021 14:21:27 GMT', 'X-Amzn-Trace-Id': 'Root=1-610e96e6-4f8930cd12a6cb347a7b4b96;', 'X-Frame-Options': 'SAMEORIGIN', 'X-Content-Type-Options': 'nosniff', 'X-XSS-Protection': '1; mode=block', 'X-Cache': 'Miss from cloudfront', 'Via': '1.1 bc026bbeb6351b9fc6315a678d5987e7.cloudfront.net (CloudFront)', 'X-Amz-Cf-Pop': 'LAX3-C4', 'X-Amz-Cf-Id': 'yB0Cg-z7c0Z_YvcJWaBVnWG3OkJ_63ieOZoCNd_vB0FECi-4W8TxTg==')>, '_raw_headers': ((b'Content-Type', b'text/html;charset=ISO-8859-1'), (b'Transfer-Encoding', b'chunked'), (b'Connection', b'keep-alive'), (b'Date', b'Sat, 07 Aug 2021 14:21:27 GMT'), (b'X-Amzn-Trace-Id', b'Root=1-610e96e6-4f8930cd12a6cb347a7b4b96;'), (b'X-Frame-Options', b'SAMEORIGIN'), (b'X-Content-Type-Options', b'nosniff'), (b'X-XSS-Protection', b'1; mode=block'), (b'X-Cache', b'Miss from cloudfront'), (b'Via', b'1.1 bc026bbeb6351b9fc6315a678d5987e7.cloudfront.net (CloudFront)'), (b'X-Amz-Cf-Pop', b'LAX3-C4'), (b'X-Amz-Cf-Id', b'yB0Cg-z7c0Z_YvcJWaBVnWG3OkJ_63ieOZoCNd_vB0FECi-4W8TxTg==')), 'content': } Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/gehomesdk/clients/async_login_flows.py", line 60, in async_get_authorization_code code = await async_handle_ok_response(session, await resp.text()) File "/usr/local/lib/python3.9/site-packages/gehomesdk/clients/async_login_flows.py", line 95, in async_handle_ok_response raise GeAuthFailedError(f"Authentication failed, reason: {reason}") gehomesdk.exception.ge_auth_failed_error.GeAuthFailedError: Authentication failed, reason: Invalid credentials

joshewing02 commented 3 years ago

Also getting this

Logger: homeassistant.config_entries Source: custom_components/ge_home/update_coordinator.py:174 Integration: GE Home (documentation) First occurred: 7:22:18 AM (1 occurrences) Last logged: 7:22:18 AM

Error setting up entry GE Home (joshewing02@hotmail.com) for ge_home Traceback (most recent call last): File "/config/custom_components/ge_home/update_coordinator.py", line 172, in async_setup await self.initialization_future asyncio.exceptions.CancelledError

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/config/custom_components/ge_home/update_coordinator.py", line 172, in async_setup await self.initialization_future File "/usr/local/lib/python3.9/site-packages/async_timeout/init.py", line 45, in exit self._do_exit(exc_type) File "/usr/local/lib/python3.9/site-packages/async_timeout/init.py", line 92, in _do_exit raise asyncio.TimeoutError asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 293, in async_setup result = await component.async_setup_entry(hass, self) # type: ignore File "/config/custom_components/ge_home/init.py", line 26, in async_setup_entry if not await coordinator.async_setup(): File "/config/custom_components/ge_home/update_coordinator.py", line 174, in async_setup raise HaCannotConnect("Initialization timed out") custom_components.ge_home.exceptions.HaCannotConnect: Initialization timed out

simbaja commented 3 years ago

Hmm... the first error is saying "Invalid Credentials", can you confirm you've entered the right email/password?