Skip to content

Commit 42349e5

Browse files
authored
Merge pull request #232 from plugwise/py_typed
Py typed as suggested in #231
2 parents c02f63e + 6a428d0 commit 42349e5

File tree

7 files changed

+10
-7
lines changed

7 files changed

+10
-7
lines changed

.github/workflows/merge.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ env:
88
DEFAULT_PYTHON: 3.9
99

1010
# Only run on merges
11-
on:
11+
on:
1212
pull_request:
1313
types: closed
1414
branches:
@@ -32,7 +32,7 @@ jobs:
3232
run: >-
3333
python setup.py sdist
3434
- name: Publish distribution 📦 to PyPI
35-
uses: pypa/gh-action-pypi-publish@master
35+
uses: pypa/gh-action-pypi-publish@release/v1
3636
with:
3737
password: ${{ secrets.pypi_token }}
3838
skip_existing: true

.github/workflows/verify.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
name: Latest commit
55

66
env:
7-
CACHE_VERSION: 5
7+
CACHE_VERSION: 6
88
DEFAULT_PYTHON: "3.9"
99
PRE_COMMIT_HOME: ~/.cache/pre-commit
1010

@@ -352,7 +352,7 @@ jobs:
352352
run: >-
353353
python setup.py sdist
354354
- name: Publish distribution 📦 to Test PyPI
355-
uses: pypa/gh-action-pypi-publish@master
355+
uses: pypa/gh-action-pypi-publish@release/v1
356356
continue-on-error: true
357357
with:
358358
password: ${{ secrets.testpypi_token }}

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# Changelog
22

3+
# v0.25.4: Add py.typed, fix typing as suggested in #231
4+
35
# v0.25.3: Bugfix for https://github.com/plugwise/plugwise-beta/issues/309
46

57
# v0.25.2: Bugfix, code improvements

plugwise/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"""Plugwise module."""
22

3-
__version__ = "0.25.3"
3+
__version__ = "0.25.4"
44

55
from plugwise.smile import Smile
66
from plugwise.stick import Stick

plugwise/smile.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,7 @@ async def _update_domain_objects(self) -> None:
533533
f"{self._endpoint}{DOMAIN_OBJECTS}",
534534
)
535535

536-
async def async_update(self) -> list[GatewayData | dict[str, DeviceData]]:
536+
async def async_update(self) -> tuple[GatewayData, dict[str, DeviceData]]:
537537
"""Perform an incremental update for updating the various device states."""
538538
if self.smile_type != "power":
539539
await self._update_domain_objects()
@@ -573,7 +573,7 @@ async def async_update(self) -> list[GatewayData | dict[str, DeviceData]]:
573573
# Update for cooling
574574
self.update_for_cooling(dev_dict)
575575

576-
return [self.gw_data, self.gw_devices]
576+
return (self.gw_data, self.gw_devices)
577577

578578
async def _set_schedule_state_legacy(
579579
self, loc_id: str, name: str, status: str

py.typed

Whitespace-only changes.

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def readme():
3535
author_email="[email protected]",
3636
license="MIT",
3737
packages=find_packages(),
38+
package_data={"plugwise": ["py.typed"]},
3839
install_requires=[
3940
"aiohttp",
4041
"async_timeout",

0 commit comments

Comments
 (0)