Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

examples uses direct import (helper...). #2442

Merged
merged 1 commit into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/client_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@


try:
from examples import helper
import helper # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/client_async_calls.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@


try:
from examples import client_async
import client_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/client_calls.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@


try:
from examples import client_sync
import client_sync # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/client_payload.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@


try:
from examples import client_async
import client_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/client_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@


try:
from examples import helper
import helper # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/modbus_forwarder.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@


try:
from examples import helper
import helper # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
Empty file added examples/py.typed
Empty file.
2 changes: 1 addition & 1 deletion examples/server_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@


try:
from examples import helper
import helper # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/server_callback.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


try:
from examples import server_async
import server_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/server_payload.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


try:
from examples import server_async
import server_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
3 changes: 2 additions & 1 deletion examples/server_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@


try:
from examples import helper, server_async
import helper # type: ignore[import-not-found]
import server_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down
2 changes: 1 addition & 1 deletion examples/server_updating.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@


try:
from examples import server_async
import server_async # type: ignore[import-not-found]
except ImportError:
print("*** ERROR --> THIS EXAMPLE needs the example directory, please see \n\
https://pymodbus.readthedocs.io/en/latest/source/examples.html\n\
Expand Down