Skip to content

Commit

Permalink
Merge pull request #221 from requests-cache/release-notes
Browse files Browse the repository at this point in the history
Add notes about releases to contributing guide
  • Loading branch information
alessio-locatelli authored Feb 8, 2024
2 parents 856b484 + e07833b commit 7445714
Show file tree
Hide file tree
Showing 5 changed files with 380 additions and 359 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ on:
required: false
default: ''
env:
LATEST_PY_VERSION: '3.11'
LATEST_PY_VERSION: '3.12'

jobs:
# Deploy stable builds on tags only, and pre-release builds from manual trigger ("workflow_dispatch")
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ repos:
- id: mixed-line-ending
- id: trailing-whitespace
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.13
rev: v0.2.1
hooks:
- id: ruff
args: [ --fix ]
Expand Down
25 changes: 20 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ To set up for local development (requires [poetry](https://python-poetry.org/doc
```bash
$ git clone https://github.com/requests-cache/aiohttp-client-cache
$ cd aiohttp-client-cache
$ poetry install -E backends -E docs
$ poetry install -E all -E docs
```

## Pre-commit hooks
Expand Down Expand Up @@ -115,12 +115,27 @@ Here are some general guidelines for submitting a pull request:
- If your changes add or modify user-facing behavior, add documentation describing those changes
- Submit the PR to be merged into the `main` branch.

## Releases
Releases are built and published to pypi based on **git tags.**
[Milestones](https://github.com/requests-cache/aiohttp-client-cache/milestones) will be used to track
## Notes for Maintainers

### Releases
* Releases are built and published to PyPI based on **git tags.**
* [Milestones](https://github.com/requests-cache/aiohttp-client-cache/milestones) will be used to track
progress on major and minor releases.
* GitHub Actions will build and deploy packages to PyPI on tagged commits
on the `main` branch.

Release steps:
* Update the version in both `pyproject.toml` and `aiohttp_client_cache/__init__.py`
* Make sure the release notes in `HISTORY.md` are up to date
* Push a new tag, e.g.: `git tag v0.1 && git push origin --tags`
* This will trigger a deployment. Verify that this completes successfully and that the new version can be installed from pypi with `pip install`
* A [readthedocs build](https://readthedocs.org/projects/aiohttp-client-cache/builds/) will be triggered by the new tag. Verify that this completes successfully.

Downstream builds:
* We also maintain a [Conda package](https://anaconda.org/conda-forge/aiohttp-client-cache), which is automatically built and published by conda-forge whenever a new release is published to PyPI. The [feedstock repo](https://github.com/conda-forge/aiohttp-client-cache-feedstock) only needs to be updated manually if there are changes to dependencies.
* For reference: [repology](https://repology.org/project/python:aiohttp-client-cache) lists additional downstream packages maintained by other developers.

## Code Layout
### Code Layout
Here is a brief overview of the main classes and modules. See [API Reference](https://aiohttp-client-cache.readthedocs.io/en/latest/reference.html) for more complete documentation.
* `session.CacheMixin`, `session.CachedSession`: A mixin and wrapper class, respectively, for `aiohttp.ClientSession`. There is little logic here except wrapping `ClientSession._request()` with caching behavior.
* `response.CachedResponse`: A wrapper class built from an `aiohttp.ClientResponse`, with additional cache-related info. This is what is serialized and persisted to the cache.
Expand Down
2 changes: 1 addition & 1 deletion HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# History

## (Unreleased)
## 0.11.0

Features
--------
Expand Down
Loading

0 comments on commit 7445714

Please sign in to comment.