Skip to content

Commit

Permalink
Update README for 0.6 release
Browse files Browse the repository at this point in the history
  • Loading branch information
bmerry committed Mar 23, 2024
1 parent bec1263 commit 6398818
Showing 1 changed file with 28 additions and 6 deletions.
34 changes: 28 additions & 6 deletions README.md
Expand Up @@ -91,8 +91,17 @@ port number of 0, and async-solipsism will bind the first port number above
### Integration with pytest-asyncio

async-solipsism and pytest-asyncio complement each other well: just write a
custom `event_loop` fixture in your test file or `conftest.py` and it will
override the default provided by pytest-asyncio:
custom `event_loop_policy` fixture in your test file or `conftest.py` and it
will override the default provided by pytest-asyncio:

```python
@pytest.fixture
def event_loop_policy():
return async_solipsism.EventLoopPolicy()
```

The above is for pytest-asyncio 0.23+. If you're using an older version, then
instead you should do this:

```python
@pytest.fixture
Expand All @@ -114,10 +123,8 @@ from aiohttp import web, test_utils


@pytest.fixture
def event_loop():
loop = async_solipsism.EventLoop()
yield loop
loop.close()
def event_loop_policy():
return async_solipsism.EventLoopPolicy()


def socket_factory(host, port, family):
Expand Down Expand Up @@ -167,6 +174,21 @@ Calling functions that are not supported will generally raise

## Changelog

### 0.6

- Drop support for Python 3.6 and 3.7, which have reached end of life.
- Add `EventLoopPolicy` to simplify integration with pytest-asyncio 0.23+,
and use it for the internal tests.
- Make `Socket.write` and `Socket.recv_into` accept arbitrary buffer-protocol
objects.
- Various packaging and developer experience improvements:
- Put the packaging metadata in pyproject.toml, removing setup.cfg.
- Pin versions for CI in requirements.txt using pip-compile.
- Use pre-commit to enforce flake8 and pip-compile.
- Remove wheel from `build-system.requires` (on setuptools advice).
- Test against Python 3.11 and 3.12.
- Run CI workflow against pull requests.

### 0.5

- Map port 0 to an unused port.
Expand Down

0 comments on commit 6398818

Please sign in to comment.