Closed cokeman0 closed 2 years ago
So the 500 error here is a bug. It's actually receiving a 400 from Netatmo. So a bad request.
@cgtobi did we change the request?
Hey there @cgtobi, mind taking a look at this issue as it has been labeled with an integration (netatmo
) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)
netatmo documentation netatmo source (message by IssueLinks)
In pre 2022.10 we requested these scopes:
[
"access_camera",
"access_presence",
"read_camera",
"read_homecoach",
"read_presence",
"read_smokedetector",
"read_station",
"read_thermostat",
"write_camera",
"write_presence",
"write_thermostat",
]
After 2022.10 these are requested:
[
"access_camera", # Netatmo camera products
"access_doorbell", # Netatmo Smart Video Doorbell
"access_presence", # Netatmo Smart Outdoor Camera
"read_bubendorff", # Bubbendorf shutters
"read_camera", # Netatmo camera products
"read_carbonmonoxidedetector", # Netatmo CO sensor
"read_doorbell", # Netatmo Smart Video Doorbell
"read_homecoach", # Netatmo Smart Indoor Air Quality Monitor
"read_magellan", # Legrand Wiring device or Electrical panel products
"read_mx", # BTicino Classe 300 EOS
"read_presence", # Netatmo Smart Outdoor Camera
"read_smarther", # Smarther with Netatmo thermostat
"read_smokedetector", # Smart Smoke Alarm information and events
"read_station", # Netatmo weather station
"read_thermostat", # Netatmo climate products
"write_bubendorff", # Bubbendorf shutters
"write_camera", # Netatmo camera products
"write_magellan", # Legrand Wiring device or Electrical panel products
"write_mx", # BTicino Classe 300 EOS
"write_presence", # Netatmo Smart Outdoor Camera
"write_smarther", # Smarther products
"write_thermostat", # Netatmo climate products
]
Right, the scope changed. This shouldn't be an issue with individual dev accounts which I'd recommend anyway to make use of webhook events. We might have to update the scope access for the HA Cloud Link. I'll drop I dropped them an email.
After installing 2022.10.0b0 or 2022.10.0b1 the Netatmo integration required me to re-authenticate. However, I'm unable to do so. After logging on to the Netatmo website nothing happens when I click on 'Yes, I accept'. The page just refreshes and on Home Assistant there's no refresh taking place. Integration still states 'reconfigure'. Deleting the integration and re-adding it doesn't work either. It won't accept the authorization.
@FrancWest this is an issue related to Home Assistant Cloud. We try to resolve this ASAP. Depending on your devices I might advise you to use a Netatmo dev account to utilize webhook events.
After some investigation regarding the scopes, it seems that when access_doorbell
and read_doorbell
are in the requested scopes it fails and authentication is not possible, by omitting these 2 everything works as expected (at least for me as I do not have any doorbells 😄)
Why Netatmo treats this way and any other app differently, only Netatmo can answer.
Thanks for investigating @ludeeus. I'll submit a fix that excludes those when using HA cloud until we receive notice from Netatmo.
The problem
After upgrading to b0, netatmo wanted to reauth. after several failed attempts, I not get this message in the netatmo integration
Forsøger konfigurationen igen: 500, message='Internal Server Error', url=URL('https://account-link.nabucasa.com/refresh_token/netatmo')
What version of Home Assistant Core has the issue?
2022.10.0b0
What was the last working version of Home Assistant Core?
2022.09.x
What type of installation are you running?
Home Assistant OS
Integration causing the issue
Netatmo
Link to integration documentation on our website
No response
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
No response