This is an automated email from the ASF dual-hosted git repository.
git-site-role pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/plc4x-website.git
The following commit(s) were added to refs/heads/asf-site by this push:
new ce8cac879 Site checkin for project PLC4X: Jenkins Tools
ce8cac879 is described below
commit ce8cac879ca48704610ff91f9b5f5c74c1933f07
Author: jenkins <[email protected]>
AuthorDate: Tue Apr 9 19:45:04 2024 +0000
Site checkin for project PLC4X: Jenkins Tools
---
users/getting-started/plc4py.html | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
diff --git a/users/getting-started/plc4py.html
b/users/getting-started/plc4py.html
index 7eec358e9..cde35a1f5 100644
--- a/users/getting-started/plc4py.html
+++ b/users/getting-started/plc4py.html
@@ -356,9 +356,7 @@ async def communicate_with_plc():
builder.add_item("Random Tag", "4x00001[10]")
request = builder.build()
- future = connection.execute(request)
- await future
- response = future.result()
+ response = await connection.execute(request)
asyncio.run(communicate_with_plc())</pre>
</div>
@@ -440,9 +438,7 @@ with connection.read_request_builder() as builder:
<div class="listingblock">
<div class="content">
<pre>try:
- future = connection.execute(request)
- await future
- response = future.result()
+ response = await connection.execute(request)
except TimeOutException:
# Handle timeout error
except ...
@@ -551,9 +547,7 @@ with connection.write_request_builder() as builder:
<div class="listingblock">
<div class="content">
<pre>try:
- future = connection.execute(request)
- await future
- response = future.result()
+ response = await connection.execute(request)
except TimeOutException:
# Handle timeout error
except ...