Skip to content

Commit

Permalink
Merge pull request #246 from riptideio/async
Browse files Browse the repository at this point in the history
Redesign Async client implementation with support to tornado and asyncio
  • Loading branch information
dhoomakethu authored May 10, 2018
2 parents 7f788a4 + b8faf33 commit 73e9a57
Show file tree
Hide file tree
Showing 93 changed files with 4,575 additions and 603 deletions.
2 changes: 0 additions & 2 deletions .coveragerc

This file was deleted.

5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ pymodbus/server/__pycache__/
test/__pycache__/
**/pymodbus.db
/.eggs/
/test/bin/
/test/include/
/test/lib/
/test/pip-selfcheck.json
/test/.Python
/.cache/
/doc/sphinx/doctrees/
/doc_new/
Expand Down
1 change: 1 addition & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ python:
extra_requirements:
- twisted
- documents
version: 3.5
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@ matrix:
- os: linux
python: "3.6"
- os: osx
osx_image: xcode8.3
language: generic
before_install:
- if [ $TRAVIS_OS_NAME = osx ]; then brew update; fi
- if [ $TRAVIS_OS_NAME = osx ]; then brew install openssl; fi

install:
# - scripts/travis.sh pip install pip-accel
- scripts/travis.sh pip install -U setuptools
- scripts/travis.sh pip install coveralls
- scripts/travis.sh pip install --requirement=requirements-checks.txt
- scripts/travis.sh pip install --requirement=requirements-tests.txt
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
Version 2.0.0rc1
-----------------------------------------------------------
**Note This is a Major release and might affect your existing Async client implementation. Refer examples on how to use the latest async clients.**

* Async client implementation based on Tornado, Twisted and asyncio

Version 1.5.1
------------------------------------------------------------
* Fix device information selectors
Expand Down Expand Up @@ -36,6 +42,7 @@ Version 1.5.0
* Modbus read retries works only when empty/no message is received
* Change test runner from nosetest to pytest
* Fix Misc examples
>>>>>>> master

Version 1.4.0
------------------------------------------------------------
Expand Down
3 changes: 3 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
include requirements.txt
include README.rst
include CHANGELOG.rst
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ check: install

test: install
@pip install --quiet --requirement=requirements-tests.txt
@py.test
@py.test --cov=pymodbus/ --cov-report term-missing
@coverage report --fail-under=90

tox: install
Expand Down
7 changes: 5 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@
.. image:: https://badges.gitter.im/Join%20Chat.svg
:target: https://gitter.im/pymodbus_dev/Lobby

.. image:: https://readthedocs.org/projects/pymodbus-n/badge/?version=latest
:target: http://pymodbus-n.readthedocs.io/en/latest/?badge=latest
.. image:: https://readthedocs.org/projects/pymodbus/badge/?version=latest
:target: http://pymodbus.readthedocs.io/en/async/?badge=latest
:alt: Documentation Status

.. important::
**Note This is a Major release and might affect your existing Async client implementation. Refer examples on how to use the latest async clients.**

============================================================
Summary
============================================================
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
==================================================
Asynchronous Client Example
Async Asyncio Client Example
==================================================
.. literalinclude:: ../../../examples/common/asynchronous_client.py
.. literalinclude:: ../../../examples/common/async_asyncio_client.py
4 changes: 4 additions & 0 deletions doc/source/example/async_asyncio_serial_client.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Async Asyncio Serial Client Example
==================================================
.. literalinclude:: ../../../examples/common/async_asyncio_serial_client.py
4 changes: 4 additions & 0 deletions doc/source/example/async_tornado_client.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Async Tornado Client Example
==================================================
.. literalinclude:: ../../../examples/common/async_tornado_client.py
4 changes: 4 additions & 0 deletions doc/source/example/async_tornado_client_serial.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Async Tornado Client Serial Example
==================================================
.. literalinclude:: ../../../examples/common/async_tornado_client_serial.py
4 changes: 4 additions & 0 deletions doc/source/example/async_twisted_client.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Async Twisted Client Example
==================================================
.. literalinclude:: ../../../examples/common/async_twisted_client.py
4 changes: 4 additions & 0 deletions doc/source/example/async_twisted_client_serial.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Async Twisted Client Serial Example
==================================================
.. literalinclude:: ../../../examples/common/async_twisted_client_serial.py
4 changes: 4 additions & 0 deletions doc/source/example/asynchronous_asyncio_serial_client.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
==================================================
Asynchronous Asyncio Serial Client Example
==================================================
.. literalinclude:: ../../../examples/contrib/asynchronous_asyncio_serial_client.py
6 changes: 3 additions & 3 deletions doc/source/example/asynchronous_server.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
==================================================
===========================
Asynchronous Server Example
==================================================
.. literalinclude:: ../../../examples/common/asynchronous_server.py
===========================
.. literalinclude:: ../../../examples/common/asynchronous_server.py
4 changes: 2 additions & 2 deletions doc/source/example/callback_server.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
==================================================
===========================
Callback Server Example
==================================================
===========================
.. literalinclude:: ../../../examples/common/callback_server.py
8 changes: 7 additions & 1 deletion doc/source/example/modules.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@ Examples
.. toctree::
:maxdepth: 4

asynchronous_client
async_asyncio_client
async_asyncio_serial_client
async_tornado_client
async_tornado_client_serial
async_twisted_client
async_twisted_client_serial
asynchronous_processor
asynchronous_server
callback_server
Expand All @@ -22,6 +27,7 @@ Examples
synchronous_client_ext
synchronous_server
updating_server
asynchronous_asyncio_serial_client
bcd_payload
concurrent_client
libmodbus_client
Expand Down
1 change: 1 addition & 0 deletions doc/source/example/performance.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
performance module
==================
.. literalinclude:: ../../../examples/common/performance.py

8 changes: 8 additions & 0 deletions doc/source/library/pymodbus.client.async.asyncio.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
pymodbus\.client\.async\.asyncio package
========================================

.. automodule:: pymodbus.client.async.asyncio
:members:
:undoc-members:
:show-inheritance:

36 changes: 36 additions & 0 deletions doc/source/library/pymodbus.client.async.factory.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
pymodbus\.client\.async\.factory package
========================================

.. automodule:: pymodbus.client.async.factory
:members:
:undoc-members:
:show-inheritance:

Submodules
----------

pymodbus\.client\.async\.factory\.serial module
-----------------------------------------------

.. automodule:: pymodbus.client.async.factory.serial
:members:
:undoc-members:
:show-inheritance:

pymodbus\.client\.async\.factory\.tcp module
--------------------------------------------

.. automodule:: pymodbus.client.async.factory.tcp
:members:
:undoc-members:
:show-inheritance:

pymodbus\.client\.async\.factory\.udp module
--------------------------------------------

.. automodule:: pymodbus.client.async.factory.udp
:members:
:undoc-members:
:show-inheritance:


55 changes: 55 additions & 0 deletions doc/source/library/pymodbus.client.async.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
pymodbus\.client\.async package
===============================

.. automodule:: pymodbus.client.async
:members:
:undoc-members:
:show-inheritance:

Subpackages
-----------

.. toctree::

pymodbus.client.async.asyncio
pymodbus.client.async.factory
pymodbus.client.async.schedulers
pymodbus.client.async.tornado
pymodbus.client.async.twisted

Submodules
----------

pymodbus\.client\.async\.serial module
--------------------------------------

.. automodule:: pymodbus.client.async.serial
:members:
:undoc-members:
:show-inheritance:

pymodbus\.client\.async\.tcp module
-----------------------------------

.. automodule:: pymodbus.client.async.tcp
:members:
:undoc-members:
:show-inheritance:

pymodbus\.client\.async\.thread module
--------------------------------------

.. automodule:: pymodbus.client.async.thread
:members:
:undoc-members:
:show-inheritance:

pymodbus\.client\.async\.udp module
-----------------------------------

.. automodule:: pymodbus.client.async.udp
:members:
:undoc-members:
:show-inheritance:


8 changes: 8 additions & 0 deletions doc/source/library/pymodbus.client.async.schedulers.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
pymodbus\.client\.async\.schedulers package
===========================================

.. automodule:: pymodbus.client.async.schedulers
:members:
:undoc-members:
:show-inheritance:

8 changes: 8 additions & 0 deletions doc/source/library/pymodbus.client.async.tornado.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
pymodbus\.client\.async\.tornado package
========================================

.. automodule:: pymodbus.client.async.tornado
:members:
:undoc-members:
:show-inheritance:

8 changes: 8 additions & 0 deletions doc/source/library/pymodbus.client.async.twisted.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
pymodbus\.client\.async\.twisted package
========================================

.. automodule:: pymodbus.client.async.twisted
:members:
:undoc-members:
:show-inheritance:

25 changes: 11 additions & 14 deletions doc/source/library/pymodbus.client.rst
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
pymodbus\.client package
========================

Submodules
----------

pymodbus\.client\.async module
------------------------------

.. automodule:: pymodbus.client.async
.. automodule:: pymodbus.client
:members:
:undoc-members:
:show-inheritance:

Subpackages
-----------

.. toctree::

pymodbus.client.async

Submodules
----------

pymodbus\.client\.common module
-------------------------------

Expand All @@ -29,10 +33,3 @@ pymodbus\.client\.sync module
:show-inheritance:


Module contents
---------------

.. automodule:: pymodbus.client
:members:
:undoc-members:
:show-inheritance:
12 changes: 5 additions & 7 deletions doc/source/library/pymodbus.datastore.database.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
pymodbus\.datastore\.database package
=====================================

.. automodule:: pymodbus.datastore.database
:members:
:undoc-members:
:show-inheritance:

Submodules
----------

Expand All @@ -21,10 +26,3 @@ pymodbus\.datastore\.database\.sql\_datastore module
:show-inheritance:


Module contents
---------------

.. automodule:: pymodbus.datastore.database
:members:
:undoc-members:
:show-inheritance:
12 changes: 5 additions & 7 deletions doc/source/library/pymodbus.datastore.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
pymodbus\.datastore package
===========================

.. automodule:: pymodbus.datastore
:members:
:undoc-members:
:show-inheritance:

Subpackages
-----------

Expand Down Expand Up @@ -36,10 +41,3 @@ pymodbus\.datastore\.store module
:show-inheritance:


Module contents
---------------

.. automodule:: pymodbus.datastore
:members:
:undoc-members:
:show-inheritance:
Loading

0 comments on commit 73e9a57

Please sign in to comment.