Skip to content

Commit 117188f

Browse files
committed
Fix doc typos.
1 parent 67bf35f commit 117188f

File tree

4 files changed

+16
-14
lines changed

4 files changed

+16
-14
lines changed

FASTPOLL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ changes should be minimal.
4040
#### Changes incompatible with prior versions
4141

4242
V0.24
43-
The `version` bound variable now retuens a 2-tuple.
43+
The `version` bound variable now returns a 2-tuple.
4444

4545
Prior versions.
4646
The high priority mechanism formerly provided in `asyncio_priority.py` was a

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,10 +120,10 @@ employ stream I/O. To operate at low latency they are simply run under the
120120
has details of how to write streaming drivers.
121121

122122
The current `fast_io` version 0.24 fixes an issue with task cancellation and
123-
timeouts. In version 2.0, where a coroutine is waiting on a `sleep()` or on
124-
I/O, a timeout or cancellation are deferred until the coroutine is next
125-
scheduled. This introduces uncertainty into when the coroutine is stopped. This
126-
issue is also addressed in Paul Sokolovsky's fork.
123+
timeouts. In `uasyncio` version 2.0, where a coroutine is waiting on a
124+
`sleep()` or on I/O, a timeout or cancellation is deferred until the coroutine
125+
is next scheduled. This introduces uncertainty into when the coroutine is
126+
stopped. This issue is also addressed in Paul Sokolovsky's fork.
127127

128128
## 4.1 A Pyboard-only low power module
129129

TUTORIAL.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ asyncio and includes a section for complete beginners.
3232
4.1.2 [Awaiting a coro](./TUTORIAL.md#412-awaiting-a-coro)
3333
4.2 [Asynchronous iterators](./TUTORIAL.md#42-asynchronous-iterators)
3434
4.3 [Asynchronous context managers](./TUTORIAL.md#43-asynchronous-context-managers)
35-
5 [Exceptions timeouts and cancellation](./TUTORIAL.md#45-exceptions-timeouts-and-cancellation)
35+
5. [Exceptions timeouts and cancellation](./TUTORIAL.md#5-exceptions-timeouts-and-cancellation)
3636
5.1 [Exceptions](./TUTORIAL.md#51-exceptions)
3737
5.2 [Cancellation and Timeouts](./TUTORIAL.md#52-cancellation-and-timeouts)
3838
5.2.1 [Task cancellation](./TUTORIAL.md#521-task-cancellation)
@@ -892,10 +892,11 @@ is complete.
892892
There is currently a wokround and two solutions.
893893
* Workround: the `asyn` library provides means of waiting on cancellation of
894894
tasks or groups of tasks. See [Task Cancellation](./PRIMITIVES.md#4-task-cancellation).
895-
* Paul Sokolovsky's library fork provides `uasyncio` V2.4, but this requires
896-
his [Pycopy](https://github.com/pfalcon/micropython) firmware.
897-
* The `fast_io` fork also solves this (in a less elegant manner) and runs
898-
under official firmware.
895+
* [Paul Sokolovsky's library fork](https://github.com/pfalcon/micropython-lib)
896+
provides `uasyncio` V2.4, but this requires his
897+
[Pycopy](https://github.com/pfalcon/micropython) firmware.
898+
* The [fast_io](./FASTPOLL.md) fork of `uasyncio` solves this in Python (in a
899+
less elegant manner) and runs under official firmware.
899900

900901
The exception hierarchy used here is `Exception-CancelledError-TimeoutError`.
901902

UNDER_THE_HOOD.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,8 @@ b = my_coro.pend_throw(None) # Coro can now safely be executed
102102
```
103103
In the above instance `a` will be `None` if it was the first call to
104104
`pend_throw` and `b` will be 42. This is used to determine if a paused task is
105-
on a `timeq` or waiting on I/O.
105+
on a `timeq` or waiting on I/O. A task on a `timeq` will have an integer value,
106+
being the `ID` of the task; one pending I/O will have `False`.
106107

107108
If a coro is actually run, the only acceptable stored values are `None` or an
108109
exception. The error "exception must be derived from base exception" indicates
@@ -241,9 +242,9 @@ time the coro is scheduled.
241242
In the `fast_io` version the `cancel` function puts the task onto `.runq` or
242243
`.ioq` for "immediate" excecution. In the case where the task is on `.waitq` or
243244
`.lpq` the task ID is added to a `set` `.canned`. When the task reaches the top
244-
of the timeq it is discarded. This pure Python approach is less efficient than
245-
that in the Paul Sokolovsky fork, but his approach uses a special version of
246-
the C `utimeq` object and so requires his firmware.
245+
of the timeq it is ignored and removed from `.canned`. This Python approach is
246+
less efficient than that in the Paul Sokolovsky fork, but his approach uses a
247+
special version of the C `utimeq` object and so requires his firmware.
247248

248249
Timeouts use a similar mechanism.
249250

0 commit comments

Comments
 (0)