8000 Change touchline dependency to pytouchline_extended by brondum · Pull Request #136362 · home-assistant/core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Change touchline dependency to pytouchline_extended #136362

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

Merged
merged 4 commits into from
Feb 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions homeassistant/components/touchline/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

from typing import Any, NamedTuple

from pytouchline import PyTouchline
from pytouchline_extended import PyTouchline

Check warning on line 7 in homeassistant/components/touchline/climate.py

View check run for this annotation

Codecov / codecov/patch

homeassistant/components/touchline/climate.py#L7

Added line #L7 was not covered by tests
import voluptuous as vol

from homeassistant.components.climate import (
Expand Down Expand Up @@ -53,12 +53,13 @@
"""Set up the Touchline devices."""

host = config[CONF_HOST]
py_touchline = PyTouchline()
number_of_devices = int(py_touchline.get_number_of_devices(host))
add_entities(
(Touchline(PyTouchline(device_id)) for device_id in range(number_of_devices)),
True,
)
py_touchline = PyTouchline(url=host)
number_of_devices = int(py_touchline.get_number_of_devices())
devices = [

Check warning on line 58 in homeassistant/components/touchline/climate.py

View check run for this annotation

Codecov / codecov/patch

homeassistant/components/touchline/climate.py#L56-L58

Added lines #L56 - L58 were not covered by tests
Touchline(PyTouchline(id=device_id, url=host))
for device_id in range(number_of_devices)
]
add_entities(devices, True)

Check warning on line 62 in homeassistant/components/touchline/climate.py

View check run for this annotation

Codecov / codecov/patch

homeassistant/components/touchline/climate.py#L62

Added line #L62 was not covered by tests


class Touchline(ClimateEntity):
Expand Down
2 changes: 1 addition & 1 deletion homeassistant/components/touchline/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
"iot_class": "local_polling",
"loggers": ["pytouchline"],
"quality_scale": "legacy",
"requirements": ["pytouchline==0.7"]
"requirements": ["pytouchline_extended==0.4.5"]
}
2 changes: 1 addition & 1 deletion requirements_all.txt

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
0