* Remove unused hass parameter for SolarEdgeData
* Add factory to create different types of sensors
Rename SolarEdgeSensor to SolarEdgeOverviewSensor
Rename SolarEdgeData to SolarEdgeOverviewDataService
Remove unused hass parameter in SolarEdgeOverviewDataService
* Add SolarEdgeDetailsDataService to retrieve details data
Add SolarEdgeDetailsSensor to report details data
Add abstract class SolarEdgeSensor
Add details sensor types
* Combine multiple details sensor into one sensor with attributes
* Fix pylint and flake8 errors
* Resolve conflict with solaredge component update
* Add SolarEdgeInventoryDataService to retrieve inventory information
Add SolarEdgeInventorySensor to view inventory information
Add inverters to monitored_conditions
* Fix pylint and flake8 errors
* Add additional monitored variables for solaredge
* Add new sensors to solaredge component
* Add SolarEdgePowerFlowDataService
Add SolarEdgePowerFlowSensor
Add new monitored_conditions for power consumption and grid, load and
solar power production/consumption
* Set entity_id for each sensor based on platform and sensor type
* Fix flake8 and pylint errors
* Add check for connections in return data
* Fix pylint and flake8 errors
* Renamed state_attributes to device_state_attributes
Moved request import to top
* Remove explicit definition of entity_id
* Fix pylint and flake8 errors
* Add check for None before adding sensor
* Update SolarEdgeSensorFactory with initial dict which maps sensor_key to
entity class and data service
* Update attribute values to snakecase
Added stingcase as requirement
* Update requirements_all.txt to include stringcase for solaredge
* Update some initial values for data and unit_of_measurement
Update sensor factory
* initial commit for camera preferences and preload stream
* cleanup and add tests
* respect camera preferences on each request stream call
* return the new prefs after update
* Set default parallel_update value should base on async_update
* Set default parallel_update value should base on async_update
* Delay the parallel_update_semaphore creation
* Remove outdated comment
* Add import_events(), small refactoring, traccar_id
I isolated the code that imports traccar tracking data and added a new function that imports the traccar events to make them run in parallel and reduce delay. The events that are imported in hass, will be fired with the prefix "traccar_". Furthermore a traccar_id is now imported in hass entities, useful for matching the traccar hass entities with the traccar hass events in the most accurate way.
* bump pytraccar version
* Code format fix
* Code format fix 2
* Code format fix 3
* Implement requested changes
* Add new traccar dependency
* Fix line too long
* Update device_tracker.py
* Update requirements_all.txt
Catch RequestException instead of ConnectionError
In some cases TpLinkDeviceScanner throws various successors of
RequestException. They should be caught.
* Allow panels to indicate they are meant for admins
* Panels to indicate when they require admin access
* Do not return admin-only panels to non-admin users
* Fix flake8
## Description:
This is a follow up to #22171. There we set the name of an entity based on the `accessory-information` homekit service, rather than using the zeroconf/avahi name metadata. Unfortunately Lock also sets its name from zeroconf directly, rather than picking it up from the base class. This test updates it to be like the other homekit entities and use the base class.
(This is from my ongoing homekit_controller configentry branch).
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
* removed "from" parameter from ClickSend API call
Removed "from" parameter from API call to let ClickSend choose a random number and be more compliant with some cellular networks that do not allow incoming calls from the same recipient number.
* fixed "line too long (94 > 79 characters)" houndci code review
fixed "line too long (94 > 79 characters)" houndci code review
* Added new component optional parameter "caller".
If defined is used to override default logic that uses recipient phone number in "from" API call parameter
* Removed default value for CALLER parameter. If not defined then will take the RECIPIENT value.
* ecobee: expose detailed equipment status
* Fix#18244 for ecobee by moving current_operation property to current_operation_mode which is more accurate and defining current_operation properly, thanks @ZetaPhoenix
* fix docstring and lint issue
* Revert "fix docstring and lint issue"
This reverts commit d3a645f075.
* Revert "Fix #18244 for ecobee by moving current_operation property to current_operation_mode which is more accurate and defining current_operation properly, thanks @ZetaPhoenix"
This reverts commit bfd90551ef.
* Check if mac is set when more than 2 gateways
When more than 2 gateways mac is required for each of them. Now voluptuous will require it.
* fix line length
* remove trailing whitespace
* Make it more readable
## Description:
Add support for AC-models that follows the Tfiac protocol. Built together with @mellado.
**Pull request in [home-assistant.io](https://github.com/home-assistant/home-assistant.io) with documentation (if applicable):** home-assistant/home-assistant.io#8910
## Example entry for `configuration.yaml` (if applicable):
```yaml
climate:
platform: tfiac
host: 192.168.10.26
```
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
If user exposed functionality or configuration variables are added/changed:
- [x] Documentation added/updated in [home-assistant.io](https://github.com/home-assistant/home-assistant.io)
If the code communicates with devices, web services, or third-party tools:
- [x] New dependencies have been added to the `REQUIREMENTS` variable ([example][ex-requir]).
- [x] New dependencies are only imported inside functions that use them ([example][ex-import]).
- [x] New or updated dependencies have been added to `requirements_all.txt` by running `script/gen_requirements_all.py`.
- [x] New files were added to `.coveragerc`.
[ex-requir]: https://github.com/home-assistant/home-assistant/blob/dev/homeassistant/components/keyboard/__init__.py#L14
[ex-import]: https://github.com/home-assistant/home-assistant/blob/dev/homeassistant/components/keyboard/__init__.py#L23
Co-authored-by: Robbie Trencheny <me@robbiet.us>
* Properly connect sensors to hub
Refs #20958
* Don't connect (merge) with main device
* Provide manufacturer
* Linting
* Do connect upnp-sensors to main device
* Linting
* Fix requirements_all.txt
* Turn the TV on via remote
* Turn the TV on via remote
* Use turn_on() from panasonic-viera==0.3.2
* make power option configurable
* add app_power as argument
* formatting
## Description:
For RTSP streams, set the `prefer_tcp` FFMPEG flag. This should resolve some of the "green feed" issues that some users are reporting, likely due to packets being lost over UDP on their network.
Resources: [FFMPEG protocols documentation](https://ffmpeg.org/ffmpeg-protocols.html#rtsp)
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
* Initial draft
* Add tests for init
Fix hound comments
* Add tests for device
Change parameter handling to make device easier to test
* Remove superfluous functionality per Martins request
* Fix hound comments
* Embedded platforms
* Fix device import
* Config flow retry
* Options default values will be set automatically to options in config entry before component can be used
* Clean up init
Add populate options
Fix small issues in config flow
Add tests covering init
* Improve device tests
* Add config flow tests
* Fix hound comments
* Rebase miss
* Initial tests for binary sensors
* Clean up
More binary sensor tests
* Hound comments
* Add camera tests
* Fix initial state of sensors
* Bump dependency to v17
* Fix pylint and flake8
* Fix comments
## Description:
Passing in a configuration for the embedded MQTT server has been broken for a while. This fixes that. See related issue number for further details.
**Related issue (if applicable):** fixes#18228
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
## Description:
Switches elevation helper to use [Open Elevation](https://open-elevation.com/) instead of Google Maps API which now requires a API key. It's a drop in replacement for Google Maps too!
**Related issue (if applicable):** fixes#19860
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
## Description:
Fix Prometheus casting issues
**Related issue (if applicable):** fixes#8659.
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
* Return current position and last updated timestamp needed by UI
* Add throttling to position updating
* Simplify logic, don't clear position when refreshing
* Use seconds
* Update homeassistant/components/plex/media_player.py
Co-Authored-By: jjlawren <jjlawren@users.noreply.github.com>
* Add throttling to position updating
* Simplify logic, don't clear position when refreshing
* Fire events with websocket messages.
* Added tests to validate
* Fixed api_streams sensor to use new sensor
* Delete from coverageac as now works.
* Removed websocket request event.
* Use dispatcher instead of events.
* Moved sensor to under websocket_api
* Changes as per code review
* Fixed tests.
* Modified test
* Patch
* Bump python-miio version
* Rename speed property to motor_speed
* Enable set_led service of the Air Humidifier
* Allow a favorite level in [0...17]
* Allow a scene in [0...6]
* Fix breaking on HTML email without images
If using html emails with no images the code breaks since it is not tested for empty (uninitialized) key images.
* fixed long line
* Implemented suggested better solution
Better solution to allow data -> html email without images.
* Protecting data -> without html key from crashing
If the data key does not contain the html key, sending the email would crash this "script". Preventing this by returning an default empty array.
* Moved climate components with tests into platform dirs.
* Updated tests from climate component.
* Moved binary_sensor components with tests into platform dirs.
* Updated tests from binary_sensor component.
* Moved calendar components with tests into platform dirs.
* Updated tests from calendar component.
* Moved camera components with tests into platform dirs.
* Updated tests from camera component.
* Moved cover components with tests into platform dirs.
* Updated tests from cover component.
* Moved device_tracker components with tests into platform dirs.
* Updated tests from device_tracker component.
* Moved fan components with tests into platform dirs.
* Updated tests from fan component.
* Moved geo_location components with tests into platform dirs.
* Updated tests from geo_location component.
* Moved image_processing components with tests into platform dirs.
* Updated tests from image_processing component.
* Moved light components with tests into platform dirs.
* Updated tests from light component.
* Moved lock components with tests into platform dirs.
* Moved media_player components with tests into platform dirs.
* Updated tests from media_player component.
* Moved scene components with tests into platform dirs.
* Moved sensor components with tests into platform dirs.
* Updated tests from sensor component.
* Moved switch components with tests into platform dirs.
* Updated tests from sensor component.
* Moved vacuum components with tests into platform dirs.
* Updated tests from vacuum component.
* Moved weather components with tests into platform dirs.
* Fixed __init__.py files
* Fixes for stuff moved as part of this branch.
* Fix stuff needed to merge with balloob's branch.
* Formatting issues.
* Missing __init__.py files.
* Fix-ups
* Fixup
* Regenerated requirements.
* Linting errors fixed.
* Fixed more broken tests.
* Missing init files.
* Fix broken tests.
* More broken tests
* There seems to be a thread race condition.
I suspect the logger stuff is running in another thread, which means waiting until the aio loop is done is missing the log messages.
Used sleep instead because that allows the logger thread to run. I think the api_streams sensor might not be thread safe.
* Disabled tests, will remove sensor in #22147
* Updated coverage and codeowners.
* Consolidate
* Fix tests
* Update imports
* Fix import
* Use importlib because integration and package share name
* Fix more tests
* Update .coveragerc and CODEOWNERS
* Improve fix in c90f0d5 (#22106). Schedule connect coroutine directly on the loop rather than waiting for EVENT_HOMEASSISTANT_START.
* Remove unused import.
amcrest 1.2.7 now includes camera's configured RTSP port in generated URL. Necessary to make new stream component work correctly if camera does not use default RTSP port.
* Telegram_bot: Allow fetching data from unverified SSL endpoints (#22067)
This patch adds an extra option to the payload that describes the
resource to send to disable the SSL server verification when polling
data from URLs.
* Use the boolean interpretation of the variable directly
Co-Authored-By: nbarrientos <nacho@criptonita.com>
## Description:
**Related issue (if applicable):** fixes#21782
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
* Register devices into the registry
* Switch to device ID instead of webhook ID
* Rearchitect mobile_app to support config entries
* Kill DATA_REGISTRATIONS by migrating registrations into config entries
* Fix tests
* Improve how we get the config_entry_id
* Remove single_instance_allowed
* Simplify setup_registration
* Move webhook registering functions into __init__.py since they are only ever used once
* Kill get_registration websocket command
* Support description_placeholders in async_abort
* Add link to mobile_app implementing apps in abort dialog
* Store config entry and device registry entry in hass.data instead of looking it up
* Add testing to ensure that the config entry is created at registration
* Fix busted async_abort test
* Remove unnecessary check for entry is None
* Update location schema
* Generate a random device ID at registration time for later use with device_tracker.see
* Remove host name from device_tracker.see payload
* Drop consider_home from the payload
* Remove stale consider_home in schema
* Remove source_type
## Description:
**Related issue (if applicable):** fixes#21758
## Checklist:
- [x] The code change is tested and works locally.
- [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
For example Discord webhooks returns a 204 success code as response, which gets logged as an error in the log, even though it is successful.
Update the allowed statuses to accept all 2xx responses as successful.
* Cleaned up named sensor handling for future
Breaking change for tellstick sensor configuration.
* Fixed linting of long lines and closing bracket
Linting warning for long line and not using best practice for visual indentation of closing bracket.
Who's a good boy..
* Whitespace on line was not cleaned.
* Removed spaces to clean up
* More.. whitespace. Sloppy.
* Constants from const, altered loops, added dictionary for sensor names.
* Fixed whitespace
* Inverted condition and created guard clause
* Changed condition from not ... in to not in.
* Fixed bad indentation on L91 and 92
* Working on adding androidtv functionality to firetv component
* 'should_poll' must return True
* Change 'properties' to 'device_properties'
* Also mention 'Android TV' in services.yaml
* Use GitHub for 'androidtv' requirement
* Add 'androidtv==0.0.10' to requirements, remove 'firetv==1.0.9'
* Add 'GET_PROPERTIES' adb command option; use pypi for REQUIREMENTS
* Rename integration from 'firetv' to 'androidtv'
* Change default name to 'Android TV'
* Rename integration from 'firetv' to 'androidtv'
* Change firetv to androidtv in .coveragerc
* Change firetv to androidtv in requirements_all.txt
* Remove 'DEFAULT_APPS'
* Update registration schema to add os_name (required) and make app_name required
* Ensure that a provided app_component is valid and available
* Ensure that component DEPENDENCIES declares mobile_app
* Update homeassistant/helpers/config_validation.py
* Standardize error responses
* Dont generalize REGISTER_BAD_COMPONENT
* Fix tests after merge
* bug fixing for MagicHome LEDs with flux_led component.
* corrections of the fixes for flux_led
* now asyncio sleep and turn on with brigthness possible
* indention fix with flux_led
* async now works
* houndci fixes
* little fixes for flux_led
* self._color fix for flux_led
* Add docstring
Assume a snapshot state with three speakers in two groups, AB and C. They will
be playing the A and C queues, respectively. The B queue exists but is hidden
in this topology.
Unjoin B and form a new group BC, playing the B queue (now with the C queue
hidden).
To restore the snapshot we would join B back to A. The BC group would now only
contain the C speaker, still playing the B queue. The C queue has been lost :-(
The problem is that unjoining a coordinator will elect a new coordinator that
inherits the group queue and thus has its hidden queue overwritten.
This commit avoids the situation by having restore unjoin all slaves. Above, C
would be unjoined before joining B to A. This restores the C queue and since B
is then alone, it can be joined to A without having to transfer its playing
queue to remaining speakers.
* initial commit of streams
* refactor stream component
* refactor so stream formats are not considered a platform
* initial test and minor refactor
* fix linting
* update requirements
* need av in tests as well
* fix import in class def vs method
* fix travis and docker builds
* address code review comments
* fix logger, add stream start/stop logs, listen to HASS stop
* address additional code review comments
* beef up tests
* fix tests
* fix lint
* add stream_source to onvif camera
* address pr comments
* add keepalive to camera play_stream service
* remove keepalive and move import
* implement registry and have output provider remove itself from stream after idle, set libav log level to error
Nanoleaf component now supports both nanoleaf lights, Aurora and Canvas
Changed the dependency to pynanoleaf, nanoleaf does not seem to be
maintained anymore
* Don't hang forever if manually added cast is down
* Adapt to pychromecast
* Do not set available until connected
* Update __init__.py
* Update requirements
* Lint, tests
* Fix tests
* Deprecated http.api_password
* Deprecated ApiConfig.api_password
GitHub Drafted PR would trigger CI after changed it to normal PR.
I have to commit a comment change to trigger it
* Trigger CI
* Adjust if- elif chain in auth middleware
## Description:
* Bump version to latest version of pyvlx: 0.2.10. Library more failure tolerant, when detecting an unsupported device.
* When calling API (e.g. run scene, change position) don't wait until device has reached target position (This caused HASS to be flaky while the device was moving)
* Support for vertical and horizontal awnings.
* timediff is of type timedelta. Divide by timedelta does not work.
- convert a timedelta to int
- make sure the test inputs real timestamps
* Convert the total_seconds to decimal and round the result
readings are of type Decimal, so fix test to reflect that
* split line into multiple statements
Line too long
* use total_seconds instead of timediff
* Make both values float instead of Decimal
* First webhook commands for getting and deleting single registrations
* Keep a list of deleted webhook IDs so we can 410 if the webhook receives traffic in the future
* Return a empty JSON object instead of None
* Split up mobile_app bits into individual files
* Add typing
* Sort keys
* Remove unused async_setup_entry
* New decorator method of registering webhooks
* Add tests for cloud hook forwarding and improve error handling for cloud hooks
* Initial implementation of platform specific logic
* Add get registrations by user ID websocket call, minor style fixes
* Stop using resp dictionary during registration
* Move mobile_app/ios.py to ios/mobile_app.py
* Log any errors encountered during webhook
* Improve update registration call
* Split up mobile_app tests to match split up component
* Fix tests
* Remove integration_map in favor of component name in registration
* Add a few helper functions for custom logic components to use
* Load the app_component platform at device registration or component setup time
* Remove extraneous function
* Use guard function for checking if component is in device
* Inline websocket schemas
* Rename ATTR_s used in storage to DATA_ prefix
* squash flake8 and pylint issues
* Remove ios.mobile_app platform
* Dont mark websocket_api as a dependency
* Return standard empty_okay_response with 400 if no JSON sent
* Ensure deleted webhook IDs are registered at launch
* Remove the creation of cloudhooks during handle_webhook
* Rename device to registration everywhere applicable
* Dont check if cloud is logged in, just check if cloud is in components
* Dont ever use cloudhook_id
* Remove component loading logic for a later PR
* Cast exception to string
* Remove unused functions
* fix empty TOPIC_BASE issue
if the value of the TOPIC_BASE is empty then we need to remove "~" from the topic value if it exists.
by doing `if base:` on line 239 the condition will be false if the value is empty so the '~' will not be stripped from the topic value.
I simply removed the `if base:` line and added `if TOPIC_BASE in payload:`
* Update homeassistant/components/mqtt/discovery.py
Co-Authored-By: engrbm87 <engrbm87@gmail.com>
* Quick return if attr is null
There are some case where attr is null. Returning null doesn't change anything (in my case this is mapped to a volume that doesn't exist, not sure what others are seeing).
If you have confirmed you hass instance for C instead of F you do not see this error.
* update == to is
* whitespace
* Move cisco me to new layout
* Add docstring
* Move items out of init method and pass the controller instance to the scanner in get_scanner
* Update homeassistant/components/cisco_mobility_express/device_tracker.py
Co-Authored-By: fbradyirl <fbradyirl@users.noreply.github.com>
* Update homeassistant/components/cisco_mobility_express/device_tracker.py
Co-Authored-By: fbradyirl <fbradyirl@users.noreply.github.com>
* Update homeassistant/components/cisco_mobility_express/device_tracker.py
Co-Authored-By: fbradyirl <fbradyirl@users.noreply.github.com>
* Update homeassistant/components/cisco_mobility_express/device_tracker.py
Co-Authored-By: fbradyirl <fbradyirl@users.noreply.github.com>
* Fix build error
* Cleanup based on comments.