Asked by Chris in https://mail.python.org/pipermail/async-sig/2017-June/000279.html Test output below shows that lock is being taken for both read and write. Test invariants ensure the rest.
----
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for write
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for write
locked for write
----
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for write
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for write
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for read
locked for write
locked for read
locked for read
locked for read
locked for read
locked for write