We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a623e6 commit 21fac6cCopy full SHA for 21fac6c
pymodbus/server/simulator/main.py
@@ -47,10 +47,6 @@
47
from pymodbus.server.simulator.http_server import ModbusSimulatorServer
48
49
50
-async def run():
51
- """Run simulator."""
52
-
53
54
def get_commandline():
55
"""Get command line arguments."""
56
parser = argparse.ArgumentParser(
@@ -110,13 +106,12 @@ def get_commandline():
110
106
return cmd_args
111
107
112
108
113
-async def main():
109
+def main():
114
"""Run server."""
115
cmd_args = get_commandline()
116
task = ModbusSimulatorServer(**cmd_args)
117
118
- await task.run_forever()
+ asyncio.run(task.run_forever(), debug=True)
119
120
121
if __name__ == "__main__":
122
- asyncio.run(main(), debug=True)
+ main()
0 commit comments