Skip to content

Commit 7469704

Browse files
Fix typos in release notes
Signed-off-by: Daniel Zullo <[email protected]>
1 parent 38a69fd commit 7469704

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

RELEASE_NOTES.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This release adds support to pass `None` values via channels and revamps the `Ti
88

99
* `util.Timer` was replaced by a more generic implementation that allows for customizable policies to handle missed ticks.
1010

11-
If you were using `Timer` to implement timeouts, these two pices of code should be almost equivalent:
11+
If you were using `Timer` to implement timeouts, these two pieces of code should be almost equivalent:
1212

1313
- Old:
1414

@@ -27,7 +27,7 @@ This release adds support to pass `None` values via channels and revamps the `Ti
2727

2828
They are not **exactly** the same because the `triggered_datetime` in the second case will not be exactly when the timer had triggered, but that shouldn't be relevant, the important part is when your code can actually react to the timer trigger and to know how much drift there was to be able to take corrective actions.
2929

30-
Also the new `Timer` uses the `asyncio` loop monotonic clock and the old one used the wall clock (`datetime.now()`) to track time. This means that when using `async-solipsism` to test, the new `Timer` will always trigger immediately regarless of the state of the wall clock. This also means that we don't need to mock the wall clock with `time-machine` either now.
30+
Also the new `Timer` uses the `asyncio` loop monotonic clock and the old one used the wall clock (`datetime.now()`) to track time. This means that when using `async-solipsism` to test, the new `Timer` will always trigger immediately regardless of the state of the wall clock. This also means that we don't need to mock the wall clock with `time-machine` either now.
3131

3232
With the previous timer one needed to create a separate task to run the timer, because otherwise it would block as it loops until the wall clock was at a specific time. Now the code will run like this:
3333

@@ -39,7 +39,7 @@ This release adds support to pass `None` values via channels and revamps the `Ti
3939

4040
# Simulates a delay in the timer trigger time
4141
asyncio.sleep(1.5) # Advances the loop monotonic clock by 1.5 seconds immediately
42-
await drift = timer.receive() # The timer should have triggerd 0.5 seconds ago, so it doesn't even sleep
42+
await drift = timer.receive() # The timer should have triggered 0.5 seconds ago, so it doesn't even sleep
4343
assert drift == approx(timedelta(seconds=0.5)) # Now we should observe a drift of 0.5 seconds
4444
```
4545

0 commit comments

Comments
 (0)