Ecobee binding v2

Possibly, but I was assuming millibar. Except for visibility, which is in meters, all the other values returned by the API are Imperial units. Shouldn’t matter, though, as they are numerically identical as you point out. When OH converts to SI, you should get the hPa unit.

This will be fixed in the latest 3.0 snapshot. Please let me know if you believe the problem is resolved.

Ok, thanks. I am about a month away from migrating to 3.0.

Suddenly I’m getting the following error:

2020-12-23 07:42:07.381 [ERROR] [oauth2client.internal.OAuthConnector] - grant type refresh_token to URL https://api.ecobee.com/token failed with HTTP response code 404
2020-12-23 07:42:07.385 [INFO ] [inding.ecobee.internal.api.EcobeeApi] - API: Got exception trying to get access token from OAuth service
org.eclipse.smarthome.core.auth.client.oauth2.OAuthException: Bad http response, http code 404
        at org.eclipse.smarthome.auth.oauth2client.internal.OAuthConnector.doRequest(OAuthConnector.java:321) ~[?:?]
        at org.eclipse.smarthome.auth.oauth2client.internal.OAuthConnector.grantTypeRefreshToken(OAuthConnector.java:181) ~[?:?]
        at org.eclipse.smarthome.auth.oauth2client.internal.OAuthClientServiceImpl.refreshToken(OAuthClientServiceImpl.java:300) ~[?:?]
        at org.eclipse.smarthome.auth.oauth2client.internal.OAuthClientServiceImpl.getAccessTokenResponse(OAuthClientServiceImpl.java:333) ~[?:?]
        at org.openhab.binding.ecobee.internal.api.EcobeeApi.isAuthorized(EcobeeApi.java:150) ~[?:?]
        at org.openhab.binding.ecobee.internal.api.EcobeeApi.performThermostatSummaryQuery(EcobeeApi.java:197) ~[?:?]
        at org.openhab.binding.ecobee.internal.handler.EcobeeAccountBridgeHandler.refreshThermostats(EcobeeAccountBridgeHandler.java:233) ~[?:?]
        at org.openhab.binding.ecobee.internal.handler.EcobeeAccountBridgeHandler.refresh(EcobeeAccountBridgeHandler.java:225) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_252]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_252]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_252]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_252]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_252]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_252]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_252]

As far as I know nothing has changed except and update was applied via apt-get update and a reboot.

openhab> version
4.2.7
openhab> bundle:list | grep Ecobee
217 x Active x  80 x 2.5.11                  x openHAB Add-ons :: Bundles :: Ecobee Binding

Someone also saw this recently. I’ll see if I can find that post.

Have you reauthorized with Ecobee following the changes they made to their auth system on December 1?

Here’s the link to the other post.

I have reauthorized recently for this same error, but I don’t know if it was after December 1st or not. I didn’t know they made changes. I’ll check out the post and respond.

It isn’t giving me a pin as the documentation says it should be. It just keep throwing the 404 error and the account thing status shows: ‘Status: OFFLINE - CONFIGURATION_PENDING Checking authorization’.

I’m not sure why, but some people have needed to do this to resolve the issue.

1 Like

Well, it’s probably because the binding doesn’t know how to deal with a 404 response when requesting an access token, as that’s not an expected response when calling that API endpoint.

This fixed it. Thanks! Hopefully it won’t happen again anytime soon, that is twice in under 2 months or less (not sure exact amount of time)

@mhilbush just for your attention, Kai found some issues with the ecobee binding thread usage while we were going dumpster diving for a thread exhaustion problem. I opened a bug based on his notes. Just making sure you are aware of it.

@morph166955 I saw the issue. So it appears to me that the root cause of the problem is the Samsung binding, as it causes all other calls to thingDiscovered to block. If you remove that binding, I would expect your system to function correctly.

Agreed. The SamsungTV binding is the root cause here. I think Kai just noticed the issue on the ecobee binding as he was going through my thread dump from the failed state.

Yeah, I’m working on that now. :wink:

I updated to 2.5.11 about a week ago due to the ecobee auth changes and I just noticed that the settings fanMinOnTime channel is not working (at least for my setup). Looking at the things discovery in paper ui, the fanMinOnTime channel is missing (yet in ecobee developer api docs, it should still exist).

It appears it is not being enumerated for some reason with 2.5.11. Are others seeing this issue?

Thanks

I just updated to Openhab3 and I can’t get past the ‘Status: OFFLINE - CONFIGURATION_PENDING Checking authorization’. Deleting the StorageHandler.For.OAuthClientService.json in the Openhab folder didn’t make any difference. My openhab.log is full of this:

2020-12-24 19:13:32.586 [INFO ] [inding.ecobee.internal.api.EcobeeApi] - API: The Ecobee authorization process threw an exception
org.openhab.binding.ecobee.internal.api.EcobeeAuthException: invalid_grant: The authorization grant, token or credentials are invalid, expired, revoked, do not match the redirection URI used in the authorization request, or was issued to another client.
	at org.openhab.binding.ecobee.internal.api.EcobeeAuth.authorize(EcobeeAuth.java:137) ~[bundleFile:?]
	at org.openhab.binding.ecobee.internal.api.EcobeeAuth.doAuthorization(EcobeeAuth.java:100) ~[bundleFile:?]
	at org.openhab.binding.ecobee.internal.api.EcobeeApi.isAuthorized(EcobeeApi.java:168) [bundleFile:?]
	at org.openhab.binding.ecobee.internal.api.EcobeeApi.performThermostatSummaryQuery(EcobeeApi.java:199) [bundleFile:?]
	at org.openhab.binding.ecobee.internal.handler.EcobeeAccountBridgeHandler.refreshThermostats(EcobeeAccountBridgeHandler.java:233) [bundleFile:?]
	at org.openhab.binding.ecobee.internal.handler.EcobeeAccountBridgeHandler.refresh(EcobeeAccountBridgeHandler.java:225) [bundleFile:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) [?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
	at java.lang.Thread.run(Thread.java:834) [?:?]

@SRGDamiano I did a new install of OH3 yesterday and got this message in the log. If you are not seeing this, may be try delete and reinstall the binding? Once I authorize this on the Ecobee site, everything seems to be working fine.

2020-12-21 16:31:59.037 [INFO ] [nding.ecobee.internal.api.EcobeeAuth] - #################################################################
2020-12-21 16:31:59.037 [INFO ] [nding.ecobee.internal.api.EcobeeAuth] - # Ecobee: U S E R   I N T E R A C T I O N   R E Q U I R E D !!
2020-12-21 16:31:59.037 [INFO ] [nding.ecobee.internal.api.EcobeeAuth] - # Go to the Ecobee web portal, then:
2020-12-21 16:31:59.037 [INFO ] [nding.ecobee.internal.api.EcobeeAuth] - # Enter PIN 'XXXX-XXXX' in My Apps within 900 minutes.
2020-12-21 16:31:59.037 [INFO ] [nding.ecobee.internal.api.EcobeeAuth] - # NOTE: All API attempts will fail in the meantime.

I got it to work, and got the pin from the web ui like the documentation said. I just had to delete the ecobee account “thing” that had been imported from openHab2 and create a new one. I also uninstalled and reinstalled the binding and cleared the cache a few times, but I think it was just that I needed to create a new thing.

I was really trying to delete and re-create any “things” because I didn’t want to have to go through all of the adding items and channels again and all the other imported things came through ok. I shouldn’t have been afraid; because the account is just a bridge to the thermostat and the thermostat to the sensors, even though I deleted the account, I could re-link all those things to the new bridge and they came online right away. So I didn’t have to link any new channels after all. Whew. Thank you!

The fanMinOnTime channel is defined as advanced, so you need to click “Show More” in Paper UI to see it.