Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nest Thermostat No Longer Responds to preset_mode: none or preset_mode: eco #90619

Closed
Blu53E opened this issue Mar 31, 2023 · 36 comments
Closed
Assignees

Comments

@Blu53E
Copy link

Blu53E commented Mar 31, 2023

The problem

To begin with, my apologies if this is already documented as an issue, a similar issue is already created, etc. This is my first time using GitHub and although I tried searching for similar issues, I'm not used to the interface. I just created my account within the last few hours.

Have an automation that sets my Nest Thermostats to either none or eco based on presence, etc. I have an automation the controls two Nest Thermostats. As of yesterday, the 1st Floor Nest Thermostat no longer responds to eco or none presets. The 2nd Floor Nest Thermostat works fine via the automation. The automation has been working flawlessly for a few months till yesterday.

Through exhaustive testing and troubleshooting the 1st Floor Nest Thermostat via Developer Tools: Services and directly interacting with the device via Settings: Devices & Services: Integrations, I cannot change the preset_mode. I am able to change everything else; ie: the temperature, the mode (cool, heat, heat / cool, turn on / off the fan) but when I try to set the preset, it doesn't change to the mode I want. Again, just for 1 of 2 Thermostat. The 1st Floor Thermostat reponds to all requests except for the preset_mode.

The 1st Floor Thermostat is a 1st Generation Nest Thermostat. The 2nd Floor is either a 2nd or 3rd Generation. Both worked fine till yesterday. I did however, upgrade HA Operating System and HA Core and I believe that's when it no longer worked. I tried restoring from a previous backup using my prior version of HA Core but without luck. Looks as though I can't restore the Operating System. I don't know if updating my HA caused this issue or if it was coincidence.

Here's an example of where I try to toggle the Preset via the interface. When changed, it flips back in about 2 seconds. Again, I can change the Operation, Fan Mode, Temp (up / down) and those all work fine.

image

Here's example YAML via Developer Tools. When I click "Call Service", I get a green check mark and nothing happens.

image

If I use the native Nest web app or the app on Android, I can set the preset mode.

I did set the following lines in configuration.yaml but not sure where the output is being logged. I did look in home-assistant.log but don't see much there but it may be due to my lack of understanding of what I'm trying to read. And under the Integrations Tab for Google Nest, I did turn on Enable debug logging and after a few attempts, I'm not really understanding the log output but nothing really sticks out.

logger:
default: info
logs:
homeassistant.components.nest: debug
google_nest_sdm.event: debug

This WYSIWYG isn't indenting the above correctly, screenshot:
image

What version of Home Assistant Core has the issue?

core-2023.3.6

What was the last working version of Home Assistant Core?

core-2022.12.8

What type of installation are you running?

Home Assistant OS

Integration causing the issue

nest

Link to integration documentation on our website

https://www.home-assistant.io/integrations/nest

Diagnostics information

config_entry-nest-20ee2783cd1f0b0c97fdf79072210691.json.txt

Example YAML snippet

service: climate.set_preset_mode
data:
  preset_mode: none
target:
  entity_id:
    - climate.1st_floor

Also -

service: climate.set_preset_mode
data:
  preset_mode: none
target:
  entity_id:
    - climate.1st_floor
    - climate.2nd_floor

In above example, 2nd floor works. 1st floor doesn't in either example. I've toggle the value from none to eco, back and forth, etc. 2nd floor always responded, 1st floor not.

Partial example of a longer automation:

        then:
          - device_id: [redacted]
            domain: climate
            entity_id: climate.1st_floor
            type: set_preset_mode
            preset_mode: eco
          - service: notify.mobile_app_pixel_6_pro
            data:
              title: Home Presence
              message: [redacted] & [redacted] not home. Turned on Eco Mode for 1st Floor.

The above snippet for 2nd floor Nest Thermostat works as expected.

Anything in the logs that might be useful for us?

No. I think I got everything noted above.

Actually, yes: if I set the mode (or any other options), via the web app, the android app or the physical device itself, Home Assistant shows the correct state of anything I change, including preset_mode. However, I can't set preset_mode via Home Assistant.

Additional information

Appreciate the assistance. Again, apologies if this is duplicative. New to GitHub and hope to master it soon.

@home-assistant
Copy link

Hey there @allenporter, mind taking a look at this issue as it has been labeled with an integration (nest) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of nest can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign nest Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


nest documentation
nest source
(message by IssueLinks)

@allenporter
Copy link
Contributor

Thank you for the detail. There really have been no home assistant code changes as far as I am aware, and the fact that it works on one and not the other makes me think there is a google nest API issue here.

@Blu53E
Copy link
Author

Blu53E commented Apr 1, 2023

OK - Thanks. That is kind of my thoughts as well. Just a little coincidence when I upgraded HA Operating System and HA Core. Just odd that one call is being "rejected" when called by Home Assistant. I think I'll just keep it as is and see if it ever corrects itself.

Feel free to close this issue? If I ever solve it or it solves itself, I can always add a follow-up comment.

@allenporter
Copy link
Contributor

Can you record here model information from the thermostat having the issue?

@Blu53E
Copy link
Author

Blu53E commented Apr 1, 2023

Let me know if this isn't the correct information you are looking for or if other details needed:

Model: Backplate-2.21
Software version: 4.2.8 / 3.1

@Blu53E
Copy link
Author

Blu53E commented Apr 1, 2023

From the web app:

Model | Display-2.8
Backplate model | Backplate-2.21
Software | 5.9.4-5
Updated | Sep 25, 2019 2:18 AM

Last contact | Just now
Battery | 3.96 volts

@Blu53E
Copy link
Author

Blu53E commented Apr 1, 2023

Quick update. I created a quick PowerShell script to test my thermostats.

With the script, I am able to: Set heat or cool, set the target temperature and set the mode to ECO or none.

To fully validate the script, I tested against my "good" thermostat. I was able to invoke a variety of commands and the thermostat responded as appropriate.

I next tested my 1st floor thermostat - the "bad" thermostat. It responded to changing between cool / heat and vice versa. It also responded correctly when I set the target temperature. However, it does not respond - just like in HA, when I try to set the preset_mode to eco or off.

What's interesting though, is that it appears the 1st floor thermostat is aware and received the command. Reason, if I have the thermostat in ECO mode and send the command "none", it does nothing (although it should turn off). However, if I send the command to set it to ECO and it's already in ECO mode, I get a response of "Invoke-RestMethod : The remote server returned an error: (400) Bad Request." Same error if thermostat is not in ECO mode (off) and I try to send the to turn off ECO, I get a 400 bad request. It appears I get an empty response if the request is good (although the 1st floor thermostat doesn't set it).

So I guess I'm trying to say is that it's aware, responds but doesn't set - on or off, eco mode.

Thought I may have a bad thermostat, but I can set ECO mode (on / off) via the web app and the android app.

Some examples of the test cases I tried with PowerShell (truncated):

$body = @{
    "command" = "sdm.devices.commands.ThermostatEco.SetMode"
    "params" = @{
        "mode" = "MANUAL_ECO"
        #"mode" = "OFF"
    }
} | ConvertTo-Json


<#
$body = @{
    "command" = "sdm.devices.commands.ThermostatMode.SetMode"
    "params" = @{
        "mode" = "HEAT"
    }
} | ConvertTo-Json

<#
$body = @{
    "command" = "sdm.devices.commands.ThermostatTemperatureSetpoint.SetHeat"
    "params" = @{
        "heatCelsius" = 22.0 # I now know 22C is 72F.
    }
} | ConvertTo-Json
#>

@Babdef
Copy link

Babdef commented Apr 2, 2023

Seems you're not alone. I'm experiencing the same problem since two days. I cannot set preset mode from HA.
Display-3.6
Backplate-6.5
Software version 5.9.5-2
Last contact: just now

@omarelmarajie
Copy link

Same isseu here, my automations are broken now

@allenporter
Copy link
Contributor

@omarelmarajie can you also give the device information that others have as well?

This isn't a home assistant issue but I can point Google engineers at a fix and having that info helps.

@omarelmarajie
Copy link

Display-3.4
backplate-6.5
Software version 5.9.5-2

@bgeijtenbeek
Copy link

bgeijtenbeek commented Apr 2, 2023

+1, experiencing the same issue since a couple of days.
All works fine except for the preset_mode setting. I have no issue turning eco mode on or off via Google Home App or the thermostat itself.

Home Assistant tells me the command has been successfully sent but no action on the thermostat.
Basically same story as Blu53E told.

@bgeijtenbeek
Copy link

Display-3.4 backplate-6.5 Software version 5.9.5-2

same btw

@Satyriconhu
Copy link

Satyriconhu commented Apr 3, 2023

Same issue. Few days ago (noticed on 1st Apr) only on/off function works, but no preset.

Display-3.6
Backplate-6.5
Software 5.9.5-2

HA version 2023.3.6 (updated yesterday (2nd Apr.) from 2023.3.3)
Supervisor 2023.03.3

@pbranly
Copy link

pbranly commented Apr 5, 2023

Same issue for me

@CrazyDog43
Copy link

Same issue.

Software 5.9.5-2

Home Assistant 2023.3.6

@omarelmarajie
Copy link

@omarelmarajie can you also give the device information that others have as well?

This isn't a home assistant issue but I can point Google engineers at a fix and having that info helps.

tnx

@tivoo
Copy link

tivoo commented Apr 5, 2023

Affecting me and my thermostat as well now. Thank you for putting up this issue. Definitely watching this. Hope it can get fixed soon!

Display-3.4
Backplate-6.5
Software 5.9.5-2

Home Assistant 2023.3.5

@pbranly
Copy link

pbranly commented Apr 5, 2023

I have exactly the same configuration

@Morriz
Copy link

Morriz commented Apr 6, 2023

Exact same issue: only preset mode request not honored

@danielduerr
Copy link

+1 here. Issue started a few days ago when I was still on Home Assistant 2023.3.6. The issue still occurs after I just upgraded to Home Assistant 2023.4.0.

I have two separate homes with Nest Thermostats controlled by Home Assistant. One home works as expected while the other home does not. In the home that does not, changing the preset via Home Assistant from Eco to None works, but changing it from None to Eco does not work. Changing the preset externally via Nest app works and shows up in Home Assistant.

Info on the Thermostat exhibiting these symptoms:

Display-2.12
Backplate-2.21
5.9.4-5

@brinkgit
Copy link

brinkgit commented Apr 7, 2023

More or less fixed the problem, at least for my thermostat.
Installed the google assistant sdk integration. With the text command 'set thermostat to eco', the thermostat goes to eco and HA detects that.
Return to normal operation with HVAC command 'heat', or send text command ‘set thermostat to on’

@pbranly
Copy link

pbranly commented Apr 7, 2023

IMG_3445
What is surprising is that if you change the status in that menu , it works .
So HA is able to send a change to the NEST
But the command climate.set_preset_mode does not work.
Is it really a nest issue ?
phil

@allenporter
Copy link
Contributor

@pbranly can you elaborate on what "if you change the status in that menu , it works " means? It sounds like you're saying that is editing the attribute. climate.set_preset_mode is the only way that home assistant can changes to nest for preset mode.

@pbranly
Copy link

pbranly commented Apr 7, 2023

Hi
I mean that if I change none to eco and refresh, and go to my nest, the status has changed and is in eco mode.
The same if I revert to none
So ha is able to change this status.

first photo: nest is none mode at 19 deg
Second photo: I change the status from none to eco
Third photo: nest is in eco mode at 16 deg
IMG_3446
IMG_3447
IMG_3448

@pbranly
Copy link

pbranly commented Apr 7, 2023

So it means that it seems that there is another way to drive the nest from HA. But this way cannot be used .
This is just to show that there is some protocol that is working

@duncanbarnes
Copy link

duncanbarnes commented Apr 7, 2023

This doesn't work for me, just tested it, I seem to have the same as others have, changing the status from the nest app is reflected in HA, both changing from eco to none and none to eco. If I try and change from HA then after a few seconds it changes back to the original value and there is no change observed on the Nest app.

Model: Display-2.14
Back Plate Model: Backplate-3.2
Software: 5.9.4-5

@pbranly What version nest do you have, perhaps this is relevant to certain models only?

@tjl10
Copy link

tjl10 commented Apr 7, 2023

Just to emphasize, I don't think there's anything Home Assistant can do here. One can use any app to try to call the SDM API ThermostatEco.SetMode, and it does nothing - the server returns 200 (see log below) but the eco mode never changes.

The problem appears to be entirely with Google / Nest.

Model: Display-3.4
Software: 5.9.5-2
Backplate model: Backplate-6.5
Base software: 2.3.23 / 3.1

> POST /v1/enterprises/***redacted***/devices/***redacted***:executeCommand HTTP/2
> Host: smartdevicemanagement.googleapis.com
> user-agent: insomnia/2023.1.0
> content-type: application/json
> authorization: Bearer ya29.***redacted***
> accept: */*
> content-length: 99
| {
| 	"command":"sdm.devices.commands.ThermostatEco.SetMode",
| 	"params": {
| 		"mode": "MANUAL_ECO"
| 	}
| }

< HTTP/2 200 
< user-id: AVPHwEuw4HqPadF3rnvxvVKa4EQuQ-A5njbkvECRcSaC
< content-type: application/json; charset=UTF-8
< vary: X-Origin
< vary: Referer
< vary: Origin,Accept-Encoding
< date: Fri, 07 Apr 2023 15:55:42 GMT
< server: ESF
< cache-control: private
< x-xss-protection: 0
< x-frame-options: SAMEORIGIN
< x-content-type-options: nosniff
< alt-svc: h3=":443"; ma=2592000,h3-29=":443"; ma=2592000
< accept-ranges: none

@Blu53E
Copy link
Author

Blu53E commented Apr 7, 2023

I just finished trying this and couldn't get it - what pbranly wrote, to reproduce successfully. As noted above, I did create a separate PowerShell script and it has the same symptoms as Home Assistant.

As I noted when I opened this ticket a week ago, I have two Nest Thermostats. One is not setting the preset mode and the 2nd one continues to work. I thought maybe it would be a matter of time before the 2nd one quit responding to preset mode requests, but it's still respecting all the Home Assistant automations, requests, etc.

@allenporter
Copy link
Contributor

I think we have enough information on this issue. Thanks folks.

@mvereecken
Copy link

As a workaround, I changed the preset_mode toggle in my automations to a less elegant, but simpler and more stable temperature change.

@brinkgit
Copy link

brinkgit commented Apr 7, 2023

Problem might be that the thermostat returns to it's schedule when a new set-moment is reached. When you set eco manualy it will not do so.

@home-assistant home-assistant locked as off-topic and limited conversation to collaborators Apr 7, 2023
@home-assistant home-assistant unlocked this conversation Jul 6, 2023
@Blu53E
Copy link
Author

Blu53E commented Jul 6, 2023

Hello everyone!

It appears the issue has been resolved.

I originally opened this issue back in March. Issue was that one of Nest Thermostats was no longer responding / respecting the commands to set it in eco mode or not.

As of today, it appears to be respecting the eco mode via Home Assistant. I noticed the change as I left and entered my zone and the thermostat responded as appropriate versus doing nothing.

So, please check your automations to determine if the issue no longer exists.

As per the thread, this had nothing to do with the Home Assistant Nest integration created and provided by Allen Porter. But, he did provide assistance in raising it internally to his Google counterparts.

As well, thanks to tjleigh on Stack Overflow for posting this issue which caught the attention of Siddhant Priyadarshi (Software Engineer at Google) who led him to open a ticket on Google Issue Tracker.

Related links:
https://stackoverflow.com/questions/75956536/why-has-thermostateco-setmode-stopped-working?newreg=810c76bd2b0c4b9da59b47bcbdc4645e

https://issuetracker.google.com/issues/288913306

So, my thanks and thanks to everyone that contributed and helped solve this problem. 👍🏻 But as noted, I'd like to hear if others on this thread the same positive outcome so that we / I can close this issue.

@tjl10
Copy link

tjl10 commented Jul 6, 2023

Working for me too now 👍

@Babdef
Copy link

Babdef commented Jul 6, 2023

I can confirm it is working here as well now 😃

@allenporter
Copy link
Contributor

Thanks all. If folks see additional issues we can open in a new issue.

@github-actions github-actions bot locked and limited conversation to collaborators Aug 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests