Skip to content

Commit 09c1a31

Browse files
authored
Merge pull request #236 from plugwise/async
Merge ASYNC-branch into MAIN
2 parents 858e20a + cba53b1 commit 09c1a31

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+15397
-4393
lines changed

.github/workflows/merge.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ on:
1313
types: closed
1414
branches:
1515
- main
16+
- async
1617

1718
jobs:
1819
publishing:

.github/workflows/verify.yml

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

66
env:
7-
CACHE_VERSION: 22
7+
CACHE_VERSION: 24
88
DEFAULT_PYTHON: "3.13"
99
PRE_COMMIT_HOME: ~/.cache/pre-commit
1010

@@ -48,9 +48,8 @@ jobs:
4848
pip install virtualenv --upgrade
4949
python -m venv venv
5050
. venv/bin/activate
51-
pip install uv
52-
uv pip install -U pip setuptools wheel
53-
uv pip install -r requirements_test.txt -r requirements_commit.txt
51+
pip install -U pip setuptools wheel
52+
pip install -r requirements_test.txt -r requirements_commit.txt
5453
- name: Restore pre-commit environment from cache
5554
id: cache-precommit
5655
uses: actions/cache@v4
@@ -98,7 +97,7 @@ jobs:
9897
- name: Ruff (check)
9998
run: |
10099
. venv/bin/activate
101-
#ruff check plugwise_usb/*py tests/*py
100+
#ruff plugwise_usb/*py tests/*py
102101
echo "***"
103102
echo "***"
104103
echo "Code is not up to par for ruff, skipping"
@@ -108,7 +107,7 @@ jobs:
108107
if: failure()
109108
run: |
110109
. venv/bin/activate
111-
ruff check --fix plugwise_usb/*py tests/*py
110+
ruff --fix plugwise_usb/*py tests/*py
112111
git config --global user.name 'autoruff'
113112
git config --global user.email 'plugwise_usb@users.noreply.github.com'
114113
git remote set-url origin https://x-access-token:${{ secrets.PAT_CT }}@github.com/$GITHUB_REPOSITORY
@@ -200,12 +199,11 @@ jobs:
200199
run: |
201200
python -m venv venv
202201
. venv/bin/activate
203-
pip install uv
204-
uv pip install -U pip setuptools wheel
205-
# uv pip install -r requirements_test.txt
202+
pip install -U pip setuptools wheel
203+
#pip install -r requirements_test.txt
206204
# 20220124 Mimic setup_test.sh
207-
uv pip install --upgrade -r requirements_test.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt
208-
uv pip install --upgrade pytest-asyncio
205+
pip install --upgrade -r requirements_test.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt
206+
pip install --upgrade pytest-asyncio
209207
210208
pytest:
211209
runs-on: ubuntu-latest

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ tests/__pycache__
1111
.coverage
1212
.vscode
1313
venv
14+
.venv
1415
fixtures/*
1516
!fixtures/.keep
1617
*.sedbck

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ci:
77

88
default_language_version:
99
# force all unspecified python hooks to run python3
10-
python: python3.12
10+
python: python3.13
1111

1212
repos:
1313
# Run manually in CI skipping the branch checks

CHANGELOG.md

Lines changed: 30 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,43 @@
11
# Changelog
22

3-
## Ongoing
3+
## v0.40.0
44

5-
- Ensure CI process remains operational
6-
- Bumped pip to now prepend uv for using quicker dependency resolving and installing
7-
- As for latest HA Core USB team should rework to python 3.12 (not still 3.10)
5+
- Make auto-joining work: (@bouwew)
6+
- Correct setting of accept_join_request which enables the auto-joining (only temporarily!)
7+
- Change NodeAddRequest to not expect a response, the NodeRejoinResponse is often delayed past the NODE_TIMEOUT
8+
- Use the already present response-subscription to capture the NodeRejoinResponse and initialize to joining of a Node
9+
- Improve async task-handling, this should stress the CPU less (@bouwew)
10+
- Limit cache-size to 24hrs instead of to 1 week (@bouwew, @ArnoutD)
11+
- Implement support for devices with production enabled (@bouwew)
12+
- Collect Stick NodeInfo for use in HA (@bouwew)
13+
- Several bugfixes (@ArnoutD)
14+
- Github improvements/fixes, python 3.13 (@CoMPaTech, @bouwew)
15+
- Async fixes - implement queue-based message processing (@ArnoutD - #141)
16+
17+
## v0.40.0 (a22)
18+
19+
- Correcting messageflow to HA (@ArnoutD)
20+
21+
## v0.40.0 (a4)
22+
23+
Full rewrite of library into async version (@brefra).
24+
Main list of changes:
25+
26+
- Full async and typed
27+
- Improved protocol handling
28+
- Support for local caching of collected data to improve startup and device detection
29+
- Improved handling of edge cases especially for energy data collection
30+
- Based on detected firmware version enable the supported features
31+
- API details about supported data is combined into api.py
32+
- Added tests
833

934
## v0.31.4(a0)
1035

1136
- Re-add python 3.12 checks and compatibility
1237

1338
## v0.31.3
1439

15-
- Bugfix midnight rollover for cicrles without power usage registered during first hour(s)
40+
- Bugfix midnight rollover for circles without power usage registered during first hour(s)
1641

1742
## v0.31.2
1843

CODEOWNERS

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
# Specific files
55
setup.cfg @plugwise/plugwise-usb
6-
setup.py @plugwise/plugwise-usb
76
pyproject.toml @plugwise/plugwise-usb
87
requirements*.txt @plugwise/plugwise-usb
98

109
# Main code
11-
/plugwise/ @plugwise/plugwise-usb
12-
/userdata/ @plugwise/plugwise-usb
10+
/plugwise_usb/ @plugwise/plugwise-usb
1311

1412
# Tests and development support
1513
/tests/ @plugwise/plugwise-usb

0 commit comments

Comments
 (0)