-
-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Maintenance: Improve demo documentation and fix minor linting issues (#…
…319) Also fix #313 Co-authored-by: Pavel Kirienko <[email protected]>
- Loading branch information
1 parent
eddd2b3
commit 8f0c212
Showing
14 changed files
with
50 additions
and
62 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = "1.17.1" | ||
__version__ = "1.17.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
# Copyright (c) 2019 OpenCyphal | ||
# This software is distributed under the terms of the MIT License. | ||
# Author: Pavel Kirienko <[email protected]> | ||
# pylint: disable=duplicate-code | ||
|
||
import enum | ||
import time | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ | |
# This software is distributed under the terms of the MIT License. | ||
# Author: Pavel Kirienko <[email protected]> | ||
|
||
import time | ||
import asyncio | ||
import pytest | ||
import pycyphal | ||
|
@@ -96,7 +95,7 @@ async def add_inferior(inferior: pycyphal.transport.InputSession) -> None: | |
assert inf_b.transfer_id_timeout == pytest.approx(1.1) | ||
|
||
# Redundant reception - new transfers accepted because the iface switch timeout is exceeded. | ||
time.sleep(ses.transfer_id_timeout) # Just to make sure that it is REALLY exceeded. | ||
await asyncio.sleep(ses.transfer_id_timeout) # Just to make sure that it is REALLY exceeded. | ||
assert await tx_b.send( | ||
Transfer( | ||
timestamp=Timestamp.now(), | ||
|
@@ -132,7 +131,7 @@ async def add_inferior(inferior: pycyphal.transport.InputSession) -> None: | |
assert tr.fragmented_payload == [memoryview(b"ghi")] | ||
assert tr.inferior_session == inf_b | ||
|
||
assert None is await ses.receive(asyncio.get_running_loop().time() + 1.0) # Nothing left to read now. | ||
assert None is await ses.receive(asyncio.get_running_loop().time() + 0.1) # Nothing left to read now. | ||
|
||
# This one will be rejected because wrong iface and the switch timeout is not yet exceeded. | ||
assert await tx_a.send( | ||
|
@@ -144,7 +143,7 @@ async def add_inferior(inferior: pycyphal.transport.InputSession) -> None: | |
), | ||
asyncio.get_running_loop().time() + 1.0, | ||
) | ||
assert None is await ses.receive(asyncio.get_running_loop().time() + 1.0) | ||
assert None is await ses.receive(asyncio.get_running_loop().time() + 0.1) | ||
|
||
# Transfer-ID timeout reconfiguration. | ||
ses.transfer_id_timeout = 3.0 | ||
|