I’m running beta units that can only be accessed via the nest.py setup.
How do I roll back to the old setup?
sudo pip3 install homeassistant==0.33.4
I just got everything fixed in Nest and may end up having to rollback because of other major issues.
I just want to roll back the nest component. Everything else seems ok.
My issue is not related to the update but with the way I get data from the nests.
You could just find the old next component and put it in the custom_components folder. It will override and use that one.
I have the one that was fixed for nest protects but still used the old authentication method - let me know if you need it.
i am going to try that right now.
thx
it’s kicking this back
ERROR:homeassistant.bootstrap:Error during setup of component nest
Traceback (most recent call last):
File "/srv/hass/lib/python3.5/site-packages/homeassistant/bootstrap.py", line 150, in _async_setup_component
None, component.setup, hass, config)
AttributeError: module 'custom_components.nest' has no attribute 'setup'
ERROR:homeassistant.bootstrap:Error during setup of component nest
Traceback (most recent call last):
File "/srv/hass/lib/python3.5/site-packages/homeassistant/bootstrap.py", line 150, in _async_setup_component
None, component.setup, hass, config)
AttributeError: module 'custom_components.nest' has no attribute 'setup'
ERROR:homeassistant.bootstrap:Component nest failed to setup
I think there is more than one file involved in rolling back; it looks like it’s still trying to initialize the setup configurator for the new method. I think you’re going to have to roll back completely in order to use the beta devices.
Either that or contact the beta team at Nest and have them update the authentication method of the beta devices to use client_id and client_secret (on Nest’s end that would be Product ID and Product Secret of course).
I knew it wasn’t gonna be that simple.
I doing a script to grab the data apart and dump it into MQTT to HASS.
then do some kind of script to set it…
I figured that too, that’s why I was holding off on rolling back on my other issues. Sorry, brother.
They don’t want any third party integration in the beta program. the pynest method has been an accepted workaround, but everyone is moving to the new api setup
this is where i am thus far (I’m not a coder, programmer or anything, I just copy and paste good )
i called it nester.sh if you have one thermo would be nester.sh 0, for second thermo nester.sh 1 and so on…
I have three running.
#!/bin/sh
# User -------------------------------------------------------------------------------- #
user="hass"
usernest=nest$1
# nest config ------------------------------------------------------------------------- #
thermostat=$1 # thermostat id - use if more than one - default is 0
nest_id="" # nest user
nest_pass="" # nest password
# file paths -------------------------------------------------------------------------- #
nesterroot="/home/$user/.homeassistant/nester" # path to nester root
dataroot="$nesterroot/data" # path to data files
pynest="/usr/local/bin/nest.py" # Location of nest.py
# mqtt setup -------------------------------------------------------------------------- #
mqtthost="vostro.local"
mqtttopic=$usernest
clear
echo Nester
echo Get $usernest Data
# echo "grab all data from nest.com into a file"
python $pynest --user $nest_id --password $nest_pass --index $thermostat show > $dataroot/$usernest-dump.txt
# echo "Parse auto_away|battery_level|current_humidity|current_temperature|hvac_heater_state|leaf|target_temperature|time_to_target into file"
# echo "parse what we need from dump"
egrep -wi 'auto_away|battery_level|current_humidity|current_temperature|hvac_heater_state|leaf|target_temperature|time_to_target' $dataroot/$usernest-dump.txt > $dataroot/$usernest-raw.txt
auto_away=$(egrep -wi 'auto_away' $dataroot/$usernest-dump.txt | cut -d':' -f2)
battery_level=$(egrep -wi 'battery_level' $dataroot/$usernest-dump.txt | cut -d':' -f2)
current_humidity=$(egrep -wi 'current_humidity' $dataroot/$usernest-dump.txt | cut -d':' -f2)
hvac_heater_state=$(egrep -wi 'hvac_heater_state' $dataroot/$usernest-dump.txt | cut -d':' -f2)
leaf=$(egrep -wi 'leaf' $dataroot/$usernest-dump.txt | cut -d':' -f2)
time_to_target=$(egrep -wi 'time_to_target' $dataroot/$usernest-dump.txt | cut -d':' -f2)
tc=$(egrep -wi 'current_temperature' $dataroot/$usernest-dump.txt | cut -d':' -f2)
tf=$(echo "scale=2;((9/5) * $tc) + 32" |bc)
ttc=$(egrep -wi 'target_temperature' $dataroot/$usernest-dump.txt | cut -d':' -f2)
ttf=$(echo "scale=2;((9/5) * $ttc) + 32" |bc)
# echo "Current Temperature $tc C = $tf F"
# echo "Target Temperature $ttc C = $ttf F"
# echo "auto_away = $auto_away"
# echo "battery_level = $battery_level"
# echo "current_humidity = $current_humidity"
# echo "hvac_heater_state = $hvac_heater_state"
# echo "leaf = $leaf"
# echo "time_to_target = $time_to_target"
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/auto_away -m $auto_away
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/battery_level -m $battery_level
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/current_humidity -m $current_humidity
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/hvac_heater_state -m $hvac_heater_state
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/leaf -m $leaf
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/time_to_target -m $time_to_target
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/tf -m $tf
mosquitto_pub -h $mqtthost -q 0 -t $mqtttopic/ttf -m $ttf
You have to know bash well to make that work though, so don’t shortchange yourself. That’s a nice way to get a tedious job done and it may helps someone else.
Ouch! I’m in the same situation (fieldtester Nest) and would just update the URL in the nest.py file when updating HASS in the past.
I still did not upgrade to 0.34.x because of this. I have below files in my nest folder (0.33.4). Did you put them all in the custom_compenents folder?
@rpitera @jpenyc Hi did you proceed this one? Did anyone try dumping all the 0.33.4 files into the custom_components folder to see if it overides the .34.x nest component?
I’m still on 33.4 and as it breaks my nest, I’m holding of on upgrading. Happy to provide all the files for the nest component in my .33.4 setup for you to try on .34.x.
No, that didn’t work out for me.
So what’s the deal with this? I just upgraded to latest, which from pip seems to be 0.34.4. Entered id and key in config, was asked to authenticate when first loading UI, logged in, entered code in hass frontend, and now it’s all gone. I also got this message, similar to above:
16-12-12 20:35:52 ERROR (MainThread) [homeassistant.components.climate] Error while setting up platform nest
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 150, in _async_setup_platform
entity_platform.add_entities, discovery_info
File "/usr/lib/python3.5/asyncio/futures.py", line 361, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.5/asyncio/tasks.py", line 296, in _wakeup
future.result()
File "/usr/lib/python3.5/asyncio/futures.py", line 274, in result
raise self._exception
File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/climate/nest.py", line 44, in setup_platform
True
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 299, in add_entities
entity.update()
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/climate/nest.py", line 227, in update
self._locked_temperature = self.device.locked_temperature
File "/home/josh/.homeassistant/deps/nest/nest.py", line 422, in locked_temperature
low = self._device[self._temp_key('locked_temp_min')]
KeyError: 'locked_temp_min_f'
16-12-12 20:35:52 ERROR (MainThread) [homeassistant.components.binary_sensor] Error while setting up platform nest
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 150, in _async_setup_platform
entity_platform.add_entities, discovery_info
File "/usr/lib/python3.5/asyncio/futures.py", line 361, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.5/asyncio/tasks.py", line 296, in _wakeup
future.result()
File "/usr/lib/python3.5/asyncio/futures.py", line 274, in result
raise self._exception
File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/binary_sensor/nest.py", line 100, in setup_platform
add_devices(sensors, True)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 299, in add_entities
entity.update()
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/binary_sensor/nest.py", line 113, in update
self._state = bool(getattr(self.device, self.variable))
File "/home/josh/.homeassistant/deps/nest/nest.py", line 418, in is_locked
return self._device['is_locked']
KeyError: 'is_locked'
I’ve been getting the same error with the 0.34. I kept seeing updates related to Nest, but even with the 0.34.5, I’m still getting those errors. I opened an issue about it as I didn’t see one already open for those specific errors
Very old topic but anyone ever made any progress on this?