Problem with Nest Binding

I’m running on 1.8.3 installed from apt-get, I’ve noticed that I’ve been getting errors with the nest binding. I even went as far as pulling all my nest items from items and sitemap and I’m still seeing this error. I even downloaded the addons zip file and replaced the JAR and still get the same warning.

2016-09-17 20:04:06.473 [WARN ] [.o.b.nest.internal.NestBinding] - Exception reading from Nest.
org.openhab.binding.nest.internal.NestException: Could not get data model.
	at org.openhab.binding.nest.internal.messages.AbstractRequest.newException(AbstractRequest.java:91) ~[na:na]
	at org.openhab.binding.nest.internal.messages.DataModelRequest.execute(DataModelRequest.java:66) ~[na:na]
	at org.openhab.binding.nest.internal.NestBinding.readNest(NestBinding.java:189) ~[na:na]
	at org.openhab.binding.nest.internal.NestBinding.execute(NestBinding.java:168) ~[na:na]
	at org.openhab.core.binding.AbstractActiveBinding$BindingActiveService.execute(AbstractActiveBinding.java:156) [org.openhab.core_1.8.3.jar:na]
	at org.openhab.core.service.AbstractActiveService$RefreshThread.run(AbstractActiveService.java:173) [org.openhab.core_1.8.3.jar:na]
Caused by: java.lang.NullPointerException: null
	at org.openhab.binding.nest.internal.messages.Structure.sync(Structure.java:313) ~[na:na]
	at org.openhab.binding.nest.internal.messages.DataModel.sync(DataModel.java:478) ~[na:na]
	at org.openhab.binding.nest.internal.messages.DataModelRequest.execute(DataModelRequest.java:62) ~[na:na]
	... 4 common frames omitted

The thread over here sounds like it might be the same as what you’re seeing. Can you try the solution that fixed the problem there?

1 Like

I’ve made a test JAR that ought to allow you to have incomplete device permissions at nest.com, and still not lead to a NullPointerException. Before changing your permissions, please give this JAR try. All that should happen is that the Nest devices for which you didn’t give permission in the Nest Product you set up, will simply not be retrieved and no NPE should result.

That was the fix, like dwaterson said I don’t know why I didn’t think of that first.

Thank you for your assistance.