Skip to content

Commit

Permalink
connections.pybricks: increase wait time in PybricksHub.run()
Browse files Browse the repository at this point in the history
Testing to see if this makes a difference in <#34>.

In any case, it doesn't hurt to wait a bit longer.
  • Loading branch information
dlech committed Jun 21, 2022
1 parent edadef7 commit decfa48
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## Changed
- Changed dependency from `mpy-cross` to `mpy-cross-v5`.
- Increased wait time when waiting for user program to start in `PybricksHub.run()`.

### Fixed
- Fix syntax error on Python < 3.10 in `firmware` module.
Expand Down
2 changes: 1 addition & 1 deletion pybricksdev/connections/pybricks.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ async def send_block(data: bytes) -> None:
# for it to start
try:
await asyncio.wait_for(
self.race_disconnect(user_program_running.get()), 0.2
self.race_disconnect(user_program_running.get()), 1
)
except asyncio.TimeoutError:
# if it doesn't start, assume it was a very short lived
Expand Down

0 comments on commit decfa48

Please sign in to comment.