File tree Expand file tree Collapse file tree 20 files changed +75
-240
lines changed Expand file tree Collapse file tree 20 files changed +75
-240
lines changed Original file line number Diff line number Diff line change @@ -15,12 +15,12 @@ jobs:
1515 python-version : ' 3.x'
1616 - name : Install dependencies
1717 run : |
18- python -m pip install --upgrade pip
18+ python3 -m pip install --upgrade pip
1919 pip install setuptools wheel twine
2020 - name : Build and publish
2121 env :
2222 TWINE_USERNAME : ${{ secrets.PYPI_USERNAME }}
2323 TWINE_PASSWORD : ${{ secrets.PYPI_PASSWORD }}
2424 run : |
25- python setup.py sdist bdist_wheel
25+ python3 setup.py sdist bdist_wheel
2626 twine upload dist/*
Original file line number Diff line number Diff line change 3434 runs-on : ubuntu-latest
3535 matrix : linux
3636 container :
37- 2.7 : docker://python:2.7-buster
38- 3.6 : docker://python:3.6-buster
3937 3.7 : docker://python:3.7-buster
4038 3.8 : docker://python:3.8-buster
4139 3.9 : docker://python:3.9-buster
5149 x86 : win32
5250 x64 : win64
5351 python :
54- - name : CPython 2.7
55- tox : py27
56- action : 2.7
57- docker : 2.7
58- matrix : 2.7
59- implementation : cpython
60- - name : PyPy 2.7
61- tox : pypy27
62- action : pypy-2.7
63- docker : pypy2.7
64- matrix : 2.7
65- implementation : pypy
66- openssl_msvc_version : 2019
67- - name : CPython 3.6
68- tox : py36
69- action : 3.6
70- docker : 3.6
71- matrix : 3.6
72- implementation : cpython
7352 - name : CPython 3.7
7453 tox : py37
7554 action : 3.7
8867 docker : 3.9
8968 matrix : 3.9
9069 implementation : cpython
91- - name : PyPy 3.6
92- tox : pypy36
93- action : pypy-3.6
94- docker : pypy3.6
95- matrix : 3.6
96- implementation : pypy
97- openssl_msvc_version : 2019
9870 - name : PyPy 3.7
9971 tox : pypy37
10072 action : pypy-3.7
Original file line number Diff line number Diff line change @@ -41,22 +41,12 @@ check: install
4141
4242test : install
4343 @pip install --upgrade --quiet --requirement=requirements-tests.txt
44- ifeq ($(PYVER ) ,3.6)
45- $(info Running tests on $(PYVER))
46- @pip install --upgrade pip --quiet
47- @pytest --cov=pymodbus/ --cov-report term-missing test/test_server_asyncio.py test
48- @coverage report --fail-under=85 -i
49- else ifeq ($(PYVER),2.7)
50- $(info Running tests on $(PYVER))
51- @pip install pip==20.3.4 --quiet
52- @pytest --cov-config=.coveragerc --cov=pymodbus/ --cov-report term-missing --ignore test/test_server_asyncio.py --ignore test/test_client_async_asyncio.py test
53- @coverage report --fail-under=90 -i
54- else
55- $(info Running tests on $(PYVER))
56- @pip install --upgrade pip --quiet
57- @pytest --cov=pymodbus/ --cov-report term-missing test
58- @coverage report --fail-under=85 -i
59- endif
44+
45+ $(info Running tests on $(PYVER))
46+ @pip install --upgrade pip --quiet
47+ @pytest --cov=pymodbus/ --cov-report term-missing test
48+ @coverage report --fail-under=85 -i
49+
6050
6151tox : install
6252 @pip install --upgrade --quiet tox && tox
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ Summary
2323Pymodbus is a full Modbus protocol implementation using twisted/torndo/asyncio for its
2424asynchronous communications core. It can also be used without any third
2525party dependencies (aside from pyserial) if a more lightweight project is
26- needed. Furthermore, it should work fine under any python version > 2 .7
26+ needed. Furthermore, it should work fine under any python version >= 3 .7
2727(including python 3+)
2828
2929
Original file line number Diff line number Diff line change 11Requirements
22-------------
33
4- * Python 2 .7 or later.
4+ * Python 3 .7 or later.
55* Python Twisted, Tornado or asyncio (For async client and server)
66* Pyserial
77
Original file line number Diff line number Diff line change 66The following is an example of how to use the synchronous modbus client
77implementation from pymodbus.
88
9- It should be noted that the client can also be used with
10- the guard construct that is available in python 2.5 and up::
11-
129 with ModbusClient('127.0.0.1') as client:
1310 result = client.read_coils(1,10)
1411 print result
Original file line number Diff line number Diff line change 66The following is an example of how to use the synchronous modbus client
77implementation from pymodbus.
88
9- It should be noted that the client can also be used with
10- the guard construct that is available in python 2.5 and up::
11-
129 with ModbusClient('127.0.0.1') as client:
1310 result = client.read_coils(1,10)
1411 print result
Original file line number Diff line number Diff line change 66The following is an example of how to use the synchronous modbus client
77implementation from pymodbus.
88
9- It should be noted that the client can also be used with
10- the guard construct that is available in python 2.5 and up::
11-
129 with ModbusClient('127.0.0.1') as client:
1310 result = client.read_coils(1,10)
1411 print result
Original file line number Diff line number Diff line change @@ -10,7 +10,6 @@ from twisted.python.logfile import DailyLogFile
1010from pymodbus .constants import Defaults
1111from pymodbus .server .async import ModbusServerFactory
1212from pymodbus .transaction import ModbusSocketFramer
13- from pymodbus .internal .ptwisted import InstallManagementConsole
1413
1514def BuildService ():
1615 """
@@ -19,7 +18,6 @@ def BuildService():
1918 context = None
2019 framer = ModbusSocketFramer
2120 factory = ModbusServerFactory (context , framer )
22- InstallManagementConsole ({ 'server' : factory })
2321 application = internet .TCPServer (Defaults .Port , factory )
2422 return application
2523
Original file line number Diff line number Diff line change @@ -10,7 +10,6 @@ from twisted.python.logfile import DailyLogFile
1010from pymodbus .constants import Defaults
1111from pymodbus .server .async import ModbusUdpProtocol
1212from pymodbus .transaction import ModbusSocketFramer
13- from pymodbus .internal .ptwisted import InstallManagementConsole
1413
1514def BuildService ():
1615 """
@@ -19,7 +18,6 @@ def BuildService():
1918 context = None
2019 framer = ModbusSocketFramer
2120 server = ModbusUdpProtocol (context , framer )
22- InstallManagementConsole ({ 'server' : server })
2321 application = internet .UDPServer (Defaults .Port , server )
2422 return application
2523
You can’t perform that action at this time.
0 commit comments