Skip to content

Commit 6cb300a

Browse files
committed
Merge branch 'dev'
2 parents e5a82d5 + 4b95cbe commit 6cb300a

Some content is hidden

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

58 files changed

+1315
-1373
lines changed

.github/workflows/ci.yml

Lines changed: 27 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -18,45 +18,33 @@ on:
1818

1919
jobs:
2020
linters:
21-
name: Linters
22-
runs-on: ubuntu-latest
21+
name: Linters - ${{ matrix.os.on }} - ${{ matrix.python.version }}
22+
runs-on: ${{ matrix.os.on }}
2323
timeout-minutes: 10
2424
strategy:
2525
fail-fast: false
26+
matrix:
27+
os:
28+
- on: ubuntu-latest
29+
# - on: macos-latest
30+
# - on: windows-latest
31+
python:
32+
- version: '3.8'
33+
- version: '3.9'
34+
- version: '3.10'
35+
- version: '3.11'
2636
steps:
27-
- name: Checkout repository
28-
uses: actions/checkout@v3
29-
30-
- name: Set up python
31-
uses: actions/setup-python@v4
32-
with:
33-
python-version: 3.8
34-
35-
- name: venv restore
36-
id: cache-venv
37-
uses: syphar/restore-virtualenv@v1
37+
- uses: actions/checkout@v3
38+
- uses: actions/setup-python@v4
3839
with:
39-
requirement_files: requirements.txt
40-
41-
- name: venv create
42-
if: steps.cache-venv.outputs.cache-hit != 'true'
43-
run: pip install -e . -r requirements.txt
44-
45-
- name: codespell
46-
run: codespell
47-
48-
- name: pylint
49-
run: pylint --recursive=y examples pymodbus test
50-
51-
- name: precommit (black, bandit, and ruff)
52-
run: pre-commit run --all-files
53-
54-
- name: docs
55-
run: make -C doc/ html
56-
57-
- name: mypy
58-
run: mypy pymodbus
59-
40+
python-version: ${{ matrix.python.version }}
41+
cache: 'pip'
42+
- run: pip install -e ".[all]"
43+
- run: codespell
44+
- run: pylint --recursive=y examples pymodbus test
45+
- run: pre-commit run --all-files
46+
- run: cd doc; ./build_html
47+
- run: mypy pymodbus
6048

6149
integreation_test:
6250
name: pytest - ${{ matrix.os.on }} - ${{ matrix.python.version }}
@@ -75,40 +63,25 @@ jobs:
7563
- version: '3.10'
7664
- version: '3.11'
7765
steps:
78-
- name: Checkout repository
79-
uses: actions/checkout@v3
80-
81-
- name: Set up ${{ matrix.python.version }}
82-
uses: actions/setup-python@v4
66+
- uses: actions/checkout@v3
67+
- uses: actions/setup-python@v4
8368
with:
8469
python-version: ${{ matrix.python.version }}
70+
cache: 'pip'
71+
- run: pip install -e ".[all]"
8572

86-
- name: venv restore
87-
id: cache-venv
88-
uses: syphar/restore-virtualenv@v1
89-
with:
90-
requirement_files: requirements.txt
91-
92-
- name: venv create
93-
if: steps.cache-venv.outputs.cache-hit != 'true'
94-
run: pip install -e . -r requirements.txt
95-
96-
- name: pytest
97-
run: pytest -n0 -v --full-trace --timeout=1200
73+
- run: pytest -n0 -v --full-trace --timeout=1200
9874

9975
analyze:
10076
name: Analyze Python
10177
runs-on: ubuntu-22.04
10278

10379
steps:
10480
- uses: actions/checkout@v3
105-
10681
- uses: github/codeql-action/init@v2
10782
with:
10883
languages: python
109-
11084
- uses: github/codeql-action/autobuild@v2
111-
11285
- uses: github/codeql-action/analyze@v2
11386

11487
ci_complete:

.github/workflows/clean_workflow_runs.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ jobs:
1414
with:
1515
token: ${{ github.token }}
1616
repository: ${{ github.repository }}
17+
retain_days: 7
18+
keep_minimum_runs: 0
19+
1720

1821
clear-cache:
1922
runs-on: ubuntu-latest

.gitignore

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,6 @@ __pycache__/
1313
.vscode
1414
.vscode/
1515
build/
16-
/doc/api/epydoc/html/
17-
/doc/sphinx/doctrees/
18-
/doc/sphinx/
19-
/doc/html/
20-
/doc/_build/
2116
/dist/
2217
/pymodbus.egg-info/
2318
venv

.readthedocs.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,17 @@
1-
# Build PDF & ePub
1+
version: 2
2+
3+
build:
4+
os: ubuntu-22.04
5+
tools:
6+
python: "3.11"
7+
8+
sphinx:
9+
configuration: doc/conf.py
10+
11+
python:
12+
install:
13+
- requirements: requirements.txt
14+
215
formats:
316
- epub
417
- pdf
5-
requirements_file: requirements.txt
6-
python:
7-
extra_requirements:
8-
- documents
9-
version: 3.8

API_changes.rst

Lines changed: 20 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,13 @@
1-
=======================
2-
PyModbus - API changes.
3-
=======================
1+
API changes
2+
===========
3+
Versions (X.Y.Z) where Z > 0 e.g. 3.0.1 do NOT have API changes!
44

5-
-------------
6-
Version 3.6.0 (future)
7-
-------------
5+
API changes 3.6.0 (future)
6+
--------------------------
87

9-
-------------
10-
Version 3.5.2
11-
-------------
12-
No changes.
138

14-
-------------
15-
Version 3.5.1
16-
-------------
17-
No changes.
18-
19-
-------------
20-
Version 3.5.0
21-
-------------
9+
API changes 3.5.0
10+
-----------------
2211
- Remove handler parameter from ModbusUdpServer
2312
- Remove loop parameter from ModbusSerialServer
2413
- Remove handler and allow_reuse_port from repl default config
@@ -31,14 +20,9 @@ Version 3.5.0
3120
- Async clients now accepts `no_resend_on_retry=True`, to not resend the request when retrying.
3221
- ModbusSerialServer now accepts request_tracer=.
3322

34-
-------------
35-
Version 3.4.1
36-
-------------
37-
No changes.
3823

39-
-------------
40-
Version 3.4.0
41-
-------------
24+
API changes 3.4.0
25+
-----------------
4226
- Modbus<x>Client .connect() returns True/False (connected or not)
4327
- Modbue<x>Server handler=, allow_reuse_addr=, backlog= are no longer accepted
4428
- ModbusTcpClient / AsyncModbusTcpClient no longer support unix path
@@ -48,15 +32,8 @@ Version 3.4.0
4832
- ModbusSimulatorServer.serve_forever(only_start=False) added to allow return
4933

5034

51-
-------------
52-
Version 3.3.1
53-
-------------
54-
55-
No changes.
56-
57-
-------------
58-
Version 3.3.0
59-
-------------
35+
API changes 3.3.0
36+
-----------------
6037
- ModbusTcpDiagClient is removed due to lack of support
6138
- Clients have an optional parameter: on_reconnect_callback, Function that will be called just before a reconnection attempt.
6239
- general parameter unit= -> slave=
@@ -65,9 +42,9 @@ Version 3.3.0
6542
- on_reconnect_callback for async clients works slightly different
6643
- utilities/unpack_bitstring now expects an argument named `data` not `string`
6744

68-
-------------
69-
Version 3.2.0
70-
-------------
45+
46+
API changes 3.2.0
47+
-----------------
7148
- helper to convert values in mixin: convert_from_registers, convert_to_registers
7249
- import pymodbus.version -> from pymodbus import __version__, __version_full__
7350
- pymodbus.pymodbus_apply_logging_config(log_file_name="pymodbus.log") to enable file pymodbus_apply_logging_config
@@ -83,23 +60,16 @@ Version 3.2.0
8360
- client.protocol.<something> --> client.<something>
8461
- client.factory.<something> --> client.<something>
8562

86-
-------------
87-
Version 3.1.0
88-
-------------
63+
64+
API changes 3.1.0
65+
-----------------
8966
- Added --host to client_* examples, to allow easier use.
9067
- unit= in client calls are no longer converted to slave=, but raises a runtime exception.
9168
- Added missing client calls (all standard request are not available as methods).
9269
- client.mask_write_register() changed parameters.
9370
- server classes no longer accept reuse_port= (the socket do not accept it)
9471

95-
---------------------
96-
Version 3.0.1 / 3.0.2
97-
---------------------
98-
99-
No changes.
100-
101-
-------------
102-
Version 3.0.0
103-
-------------
10472

105-
Base
73+
API changes 3.0.0
74+
-----------------
75+
Base for recording changes.

0 commit comments

Comments
 (0)