Jump to content

Discovery failed please check logs for a more detailed error.


jkosharek

Recommended Posts

Posted

I have gone through the setup process and entered the client_id, client_secret, user_id and it finds the Thermostat and seems to be working but displays 'Discovery failed please check logs for a more detailed error.' Seems to be working and added the nodes to in IoX. 

IoX Version: 5.5.5
PG3x Version 3.1.22
HoneywellHome Current Version: 2.0.1 [Production]

Posted

Did you check the node server log?  It should provide a bit more details on the error.

Are you using the eisy's wireless network for your network connection?  If so, the discovery process may not work with it.  If you can, switch to a wired connection and see if that works.

  • 1 month later...
Posted

same error, (all ethernet FYI).  Here are some of the log details:

 
2023-03-10 09:08:10,389 Thread-1 udi_interface ERROR honeywellhome-poly:discover: Discovery failed with error (500)
Reason: Internal Server Error
HTTP response headers: HTTPHeaderDict({'Date': 'Fri, 10 Mar 2023 17:08:10 GMT', 'Content-Type': 'text/plain; charset=utf-8', 'Content-Length': '92', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache', 'Pragma': 'no-cache', 'Expires': '-1', 'Access-Control-Allow-Origin': 'https://account.honeywellhome.com', 'Access-Control-Allow-Credentials': 'true', 'Access-Control-Allow-Headers': 'Content-Type, Accept, Pragma, Cache-Control, Authorization, RequestVerificationToken', 'Strict-Transport-Security': 'max-age=31536000;includeSubDomains'})
HTTP response body: Oops! Sorry! Something went wrong.Please contact chil@honeywell.com so we can try to fix it.
Traceback (most recent call last):
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywellhome-poly.py", line 80, in discover
locations = self._api.get_locations()
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 31, in get_locations
return self._call_api(lambda: self._api.v2_locations_get(self._client_id, self._user_id))
File "/var/polyglot/pg3/ns/0021b90260b8_5/retry.py", line 27, in f_retry
return f(*args, **kwargs)
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 69, in _call_api
return function()
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 31, in <lambda>
return self._call_api(lambda: self._api.v2_locations_get(self._client_id, self._user_id))
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api/default_api.py", line 866, in v2_locations_get
return self.v2_locations_get_with_http_info(apikey, user_ref_id, **kwargs) # noqa: E501
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api/default_api.py", line 941, in v2_locations_get_with_http_info
return self.api_client.call_api(
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 336, in call_api
return self.__call_api(resource_path, method,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 168, in __call_api
response_data = self.request(
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 360, in request
return self.rest_client.GET(url,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/rest.py", line 235, in GET
return self.request("GET", url,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/rest.py", line 229, in request
raise ApiException(http_resp=r)
honeywell_home.exceptions.ApiException: (500)
Reason: Internal Server Error
HTTP response headers: HTTPHeaderDict({'Date': 'Fri, 10 Mar 2023 17:08:10 GMT', 'Content-Type': 'text/plain; charset=utf-8', 'Content-Length': '92', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache', 'Pragma': 'no-cache', 'Expires': '-1', 'Access-Control-Allow-Origin': 'https://account.honeywellhome.com', 'Access-Control-Allow-Credentials': 'true', 'Access-Control-Allow-Headers': 'Content-Type, Accept, Pragma, Cache-Control, Authorization, RequestVerificationToken', 'Strict-Transport-Security': 'max-age=31536000;includeSubDomains'})
HTTP response body: Oops! Sorry! Something went wrong.Please contact chil@honeywell.com so we can try to fix it.
2023-03-10 09:08:10,389 Thread-1 udi_interface ERROR honeywellhome-poly:discover: Discovery failed with error (500)
Reason: Internal Server Error
HTTP response headers: HTTPHeaderDict({'Date': 'Fri, 10 Mar 2023 17:08:10 GMT', 'Content-Type': 'text/plain; charset=utf-8', 'Content-Length': '92', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache', 'Pragma': 'no-cache', 'Expires': '-1', 'Access-Control-Allow-Origin': 'https://account.honeywellhome.com', 'Access-Control-Allow-Credentials': 'true', 'Access-Control-Allow-Headers': 'Content-Type, Accept, Pragma, Cache-Control, Authorization, RequestVerificationToken', 'Strict-Transport-Security': 'max-age=31536000;includeSubDomains'})
HTTP response body: Oops! Sorry! Something went wrong.Please contact chil@honeywell.com so we can try to fix it.
Traceback (most recent call last):
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywellhome-poly.py", line 80, in discover
locations = self._api.get_locations()
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 31, in get_locations
return self._call_api(lambda: self._api.v2_locations_get(self._client_id, self._user_id))
File "/var/polyglot/pg3/ns/0021b90260b8_5/retry.py", line 27, in f_retry
return f(*args, **kwargs)
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 69, in _call_api
return function()
File "/var/polyglot/pg3/ns/0021b90260b8_5/api_helper.py", line 31, in <lambda>
return self._call_api(lambda: self._api.v2_locations_get(self._client_id, self._user_id))
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api/default_api.py", line 866, in v2_locations_get
return self.v2_locations_get_with_http_info(apikey, user_ref_id, **kwargs) # noqa: E501
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api/default_api.py", line 941, in v2_locations_get_with_http_info
return self.api_client.call_api(
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 336, in call_api
return self.__call_api(resource_path, method,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 168, in __call_api
response_data = self.request(
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/api_client.py", line 360, in request
return self.rest_client.GET(url,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/rest.py", line 235, in GET
return self.request("GET", url,
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywell_home/rest.py", line 229, in request
raise ApiException(http_resp=r)
honeywell_home.exceptions.ApiException: (500)
 
 
 
Also saw this floating around, but I don't think that is a problem as OAUTH should be setup correctly, but it gets past this anyway.
 
2023-03-10 09:08:10,056 MQTT udi_interface.interface INFO interface:_message: custom data response {'customparamsdoc': '<h2>Configuration</h2>\n\n<p>This node server uses uses OAuth client credentials to authenticate to the API. To configure the node server we need to follow the following steps</p>\n\n<ol>\n<li>Create API client</li>\n<li>Authorize API client to access thermostat(s) and get user ID</li>\n<li>Configure node server</li>\n</ol>\n\n<h3>Create API client</h3>\n\n<p>The first step is to go to <a href="https://developer.honeywell.com">https://developer.honeywell.com</a> and sign up for a developer account. This account is free.</p>\n\n<p><img src="docs/screen01.png" alt="Developer Signup" /></p>\n\n<p>Once your developer account is created we need to create the API client. This is done by clicking on MY APPS and then clicking the CREATE NEW APP button.</p>\n\n<p><img src="docs/screen02.png" alt="Create App" /></p>\n\n<p>You will now see the create application screen.</p>\n\n<p><img src="docs/screen03.png" alt="Create App" /></p>\n\n<p>Set the App Name name to whatever you like.</p>\n\n<p>For the Callback URL use https://udi-honeywellhome-auth.azurewebsites.net/auth. This is a web UI that will simplify the authorization part as well as retrieving the user ID. The code for this UI is here <a href="https://github.com/dbarentine/udi-honeywellhome-auth">udi-honeywellhome-auth</a>. This UI could be run locally as well you would just need to modify the callback url to use the localhost URL.</p>\n\n<p>When finished click the Save Changes button.</p>\n\n<h3>Authorize API client</h3>\n\n<p>We now need to authorize the client created above to allow it to access our thermostats. Click on the client\'s name which should display the Consumer Key (client ID) and Consumer Secret (client secret). We will need those for the next step.</p>\n\n<p><img src="docs/screen04.png" alt="Client Credentials" /></p>\n\n<p>Open another tab and go to <a href="https://udi-honeywellhome-auth.azurewebsites.net">https://udi-honeywellhome-auth.azurewebsites.net</a>.</p>\n\n<p><strong>One thing to note, I am hosting this UI in a free Azure App Service. It is limited to 60 minutes of compute each day. So, if a lot of people are using it then it may be unavailable until the next day.</strong></p>\n\n<p>Enter your Client ID (Consumer Key) and Client Secret (Consumer Secret) in the form and click Log in.</p>\n\n<p><img src="docs/screen05.png" alt="Client Credentials" /></p>\n\n<p>This will intiate a login process with Honeywell Home. You will need to enter your Honeywell Home user (email) and password.</p>\n\n<p><img src="docs/screen06.png" alt="Login" /></p>\n\n<p>After the login it will ask that you allow your client access to Honeywell Home. Click ALLOW.</p>\n\n<p><img src="docs/screen07.png" alt="Authorize" /></p>\n\n<p>The next screen will ask which devices you want it to have access to. This is mostly up to you but obviously if we don\'t have access to the thermostats this won\'t work. Click CONNECT once you\'ve checked the devices you wish to connect.</p>\n\n<p><img src="docs/screen08.png" alt="Authorize" /></p>\n\n<p>At this point you will be redirected back to the UI. It may take a few seconds for it to refresh the page as it has to make some API calls in the background.</p>\n\n<p>Once it\'s finished you should see a table with your user and some JSON below. This is how we know everything is working correctly. Keep track of the User ID as we will need it in the next step.</p>\n\n<p><img src="docs/screen09.png" alt="User ID" /></p>\n\n<h3>Configure node server</h3>\n\n<p>The last step is to go into Polyglot and configure the Honeywell Home node server.</p>\n\n<p>We need the client ID and client secret from the client we created as well as the user ID from the previous page.</p>\n\n<p><img src="docs/screen10.png" alt="Node server" /></p>\n\n<p>Save Changes and restart the node server and it should discover any thermostats and sensors.</p>\n'}
Posted

The error is coming from the Honeywell Home server.  A 500 error code means that the something went wrong on the server side.  The response was:

Oops! Sorry! Something went wrong.Please contact chil@honeywell.com so we can try to fix it.

There's nothing wrong with the node server.  However, it is possible that Honeywell changed the API and that the node server will no longer work with it. 

I didn't write the node server and don't have any idea how it works with the Honeywell servers.

Posted

I decided to start over a now I am getting a different error, which doesn't make any sense?  (By the way, I think the other error was due to me grabbing the wrong number as the user_id)

Now I am on to this:

 
2023-03-11 14:38:42,951 Thread-1 udi_interface ERROR honeywellhome-poly:discover: Discovery failed with error 'macID'
Traceback (most recent call last):
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywellhome-poly.py", line 87, in discover
self.add_thermostat(location.location_id, location.name, thermostat, update)
File "/var/polyglot/pg3/ns/0021b90260b8_5/honeywellhome-poly.py", line 97, in add_thermostat
t_addr = thermostat['macID'].lower()
KeyError: 'macID'

 

Posted

From the looks of it, macID is something that is supposed to be returned from the server when it queries for devices.

Guest
This topic is now closed to further replies.

×
×
  • Create New...