Commit Graph

94 Commits (a22aa285d338425406f1526779d7135a8b0c701c)

Author SHA1 Message Date
Erik Montnemery 937ebb374c
Enable strict type checks of cloud (#92576)
* Enable strict type checks of cloud

* Fix circular import

* Address review comments

* Apply suggestions from code review
2023-05-24 11:46:11 +02:00
Erik Montnemery f089f52504
Update cloud WS API for getting entity (#92409)
* Update cloud WS API for getting entity

* Adjust comment
2023-05-03 17:06:42 +02:00
Erik Montnemery b71f98e8b7
Include all entities in cloud lists (#92406) 2023-05-03 16:14:04 +02:00
Erik Montnemery 31de1b17e8
Allow setting google disable 2fa flag on any entity (#92403)
* Allow setting google disable 2fa flag on any entity

* Fix test

* Include disable_2fa flag in cloud/google_assistant/entities/get
2023-05-03 09:55:38 -04:00
Erik Montnemery 2522c6d697
Add WS command cloud/alexa/entities/get (#92121)
* Add WS command cloud/alexa/entities/get

* Fix bugs, add test
2023-04-27 17:10:29 +02:00
Erik Montnemery 904ce226fb
Tweak response of /api/cloud/login (#92058) 2023-04-26 15:28:08 +02:00
Erik Montnemery 2750a5c3e6
Make assist_pipeline an after dependency of cloud (#92057) 2023-04-26 13:45:32 +02:00
Erik Montnemery ed737f306b
Remove cloud assist pipeline setup from cloud client (#92056) 2023-04-26 06:53:58 -04:00
Erik Montnemery 57a59d808b
Automaticially create an assist pipeline using cloud stt + tts (#91991)
* Automaticially create an assist pipeline using cloud stt + tts

* Return the id of the cloud enabled pipeline

* Wait for platforms to load

* Fix typing

* Fix startup race

* Update tests

* Create a cloud pipeline only when logging in

* Fix tests

* Tweak _async_resolve_default_pipeline_settings

* Improve assist_pipeline test coverage

* Improve cloud test coverage
2023-04-25 20:40:01 -05:00
Joakim Sørensen 2c8b704a6d
Add certificate status for cloud remote (#91277) 2023-04-13 00:38:32 +02:00
Erik Montnemery 44c89a6b6c
Refactor handling of exposed entities for cloud Alexa and Google (#89877)
* Refactor handling of exposed entities for cloud Alexa

* Tweak WS API

* Validate assistant parameter

* Address some review comments

* Refactor handling of exposed entities for cloud Google

* Raise when attempting to expose an unknown entity

* Add tests

* Adjust cloud tests

* Allow getting expose new entities flag

* Test Alexa migration

* Test Google migration

* Add WS command cloud/google_assistant/entities/get

* Fix return value

* Update typing

* Address review comments

* Rename async_get_exposed_entities to async_get_assistant_settings
2023-04-06 13:09:45 -04:00
Erik Montnemery f55aaf7664
Drop unused Google entity settings from cloud (#89786) 2023-03-16 11:15:38 +01:00
Franck Nijhof b0cee0bc46
String formatting and max line length - Part 1 (#84390)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-12-22 10:12:50 +01:00
Joakim Sørensen 63807e443a
Skip client metadata values that are None (#84293) 2022-12-20 09:32:27 -05:00
Joakim Sørensen 7c82b78f8c
Add repair for legacy subscription to cloud integration (#82621) 2022-11-28 23:35:24 +01:00
epenet 2c43606922
Add websocket type hints in components (#80654)
* Add websocket type hints in components

* Adjust

* Apply suggestion

Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>

Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
2022-10-20 13:41:14 +02:00
epenet 60640b4436
Add websocket type hints in components (#80533) 2022-10-18 22:15:23 -04:00
epenet 416a5cb279
Import constants from component root (#78395) 2022-09-14 00:12:54 +02:00
epenet 911402e747
Remove cloud from mypy ignore list (#74449) 2022-07-15 10:47:30 +02:00
Paulus Schoutsen aabfa08834
Add if subscription is active to cloud status (#68266) 2022-03-17 09:51:07 +01:00
Paulus Schoutsen d3bb622a3c
Bump hass-nabucasa to 0.53.0 (#66826) 2022-02-18 11:53:02 -08:00
Paulus Schoutsen cd5b69d02e
Add Google local indicator (#66610) 2022-02-16 07:54:59 -08:00
Paulus Schoutsen 9cbdd36082
Expose if HTTP is configured for SSL (#64940) 2022-01-26 09:34:48 +01:00
Erik Montnemery e6899416e1
Suppress Alexa state reports when not authorized (#64064) 2022-01-17 09:14:26 -08:00
Erik Montnemery aa40476b49
Fix comments, improve readability in Cloud (#64291) 2022-01-17 14:19:11 +01:00
Erik Montnemery be628a7c4d
Keep track of Alexa authorization status (#63979) 2022-01-13 09:47:31 -08:00
Erik Montnemery 9c9dc4cb8c
Import websocket_api (part 1) (#63905) 2022-01-11 18:24:08 +01:00
Franck Nijhof 20bdcc7fff
Replace hass.helpers: async_get_clientsession() (#63910) 2022-01-11 17:33:50 +01:00
Joakim Sørensen d1bb916070
Add client metadata to cloud register (#63794) 2022-01-10 14:49:25 +01:00
Erik Montnemery dec54488e8
Enable basic type checking for cloud (#55337)
* Enable basic type checking for cloud

* Update mypy settings

* Address review comment

* Fix rebase mistakes

* Correct decorator order
2021-11-17 09:07:01 +01:00
Paulus Schoutsen afa7ca1222
Drop block on local proxies from HA Cloud (#59334) 2021-11-14 08:11:12 -08:00
J. Nick Koston 10d6247fee
Bump to aiohttp 3.8.0 (#58974) 2021-11-04 10:07:50 -05:00
Ville Skyttä 73d192b3f3
Use HTTPStatus instead of HTTP_ consts and magic values in comp.../[bc]* (#57989) 2021-10-22 19:43:40 +02:00
Paulus Schoutsen e34c985534
Simplify cloud request connection handling (#56243)
Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2021-09-22 07:51:31 -07:00
Paulus Schoutsen 93083513b4
Bump hass-nabucasa 49 (#55823) 2021-09-06 16:05:33 -07:00
Bram Kragten 03b7b1305c
Cloud: Expose if google is registered in status + check on login (#48260)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-03-29 19:26:51 +02:00
Paulus Schoutsen 82746616fa
Cloud: Add web socket API to pick default TTS language (#45064)
* Allow picking default TTS language

* Fix test

* Fix coroutine function

* Improve test coverage

* Remove stale import

* Clean up hass

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-01-13 00:05:30 +01:00
Paulus Schoutsen 69b5176730
Make Alexa custom ID unique (#44839)
* Make Alexa custom ID unique

* Lint

* Lint
2021-01-05 17:35:28 +01:00
springstan db582bdc1b
Use http status constants more, add HTTP_ACCEPTED and HTTP_BAD_GATEWAY (#39993)
* Use http status codes and add HTTP_BAD_GATEWAY constant

* Address review comments:
 - using constants in tado integration
 - using constant in media_player init.py

* Add and use HTTP_ACCEPTED constant
2020-09-15 20:01:07 +03:00
Paulus Schoutsen 5217139e0b
Allow exposing domains in cloud (#39216) 2020-08-28 16:49:17 +02:00
Franck Nijhof 1c2ebdf307
Upgrade black to 20.8b1 (#39287) 2020-08-27 13:56:20 +02:00
Paulus Schoutsen a8e9ccbf1a
Improve cloud error handling (#36670) 2020-06-11 22:56:00 -07:00
Paulus Schoutsen 1ac8442c63
Fix Cloud UI bug preventing managing Google 2FA (#34241)
* Fix Cloud UI bug preventing managing Google 2FA

* Update comment
2020-04-15 08:43:43 -07:00
springstan 4c38e6cfa5
Use HTTP_BAD_REQUEST constant (#33797) 2020-04-09 21:43:42 +02:00
springstan fb8f8133a0
Use HTTP_INTERNAL_SERVER_ERROR constant (#33832) 2020-04-08 23:20:03 +02:00
springstan 8d61893c39
Use HTTP_OK constant (#33798)
* Use http ok constant

* Remove incorrect use

* Run isort

* Fix pylint by adding missing imports

* Fix pylint by fixing one import
2020-04-08 11:47:38 -05:00
Paulus Schoutsen 8a46d93be4
Upgrade hass_nabucasa to 0.32.2 (#32522)
* Upgrade hass_nabucasa to 32.1

* Fix tests

* Update hass-nabucasa to 0.32.2

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-03-09 17:42:26 -07:00
Paulus Schoutsen 05374d7c85
Fix google sync (#30524) 2020-01-06 22:00:39 +01:00
Ville Skyttä e6388e186c
Remove unnecessary string literal concatenations (#30360) 2020-01-02 21:17:10 +02:00
Joakim Plate 2569c4ae37 Google assistant storage of connected agents (#29158)
* Make async_report_state take agent_user_id

* Attempt to store synced agents

* Drop now not needed initialization

* Make sure cloud uses the all sync on changed preferences

* Some more places to use all version of sync

* Get the agent_user_id from the request context if available

* Minor cleanup

* Remove the old fixed agent_user_id for cloud

Instead pass along cloud_user where appropriate.

* async_delay_save takes a function

* Adjust test for delayed store

* Remove unused save function

* Add login check.
2019-12-02 22:05:59 -08:00