Skip to content

Commit

Permalink
Update CONTRIBUTING.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ewjoachim committed Sep 26, 2024
1 parent fdd3246 commit 8623eca
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -393,6 +393,42 @@ needs to be asynchronous at core.
When possible, we're trying to avoid duplicating code, with designs such as
["hoisting the I/O"](https://www.youtube.com/watch?v=PBQN62oUnN8).

## Dependencies management

Dependencies for the package are handled by Poetry in
[`pyproject.toml`](https://github.com/procrastinate-org/procrastinate/blob/main/pyproject.toml#L25).
Whenever possible, we avoid pinning or putting any kind of limits on the
requirements. We'll typically only do that if we know that there's a
known conflict with specific versions. Typically, even if we support a subset of
Django versions, we won't restrict the Procrastinate package to those versions,
and if users use procrastinate with unsupported Django version and it works for
them, everyone is happy.

Dependencies for the development environment are kept in
[`poetry.lock`](https://github.com/procrastinate-org/procrastinate/blob/main/poetry.lock).
Those are updated regularily by [Renovate](https://docs.renovatebot.com/) which
merges their own PRs.
The versions in `pre-commit-config.yaml` are kept in sync with `poetry.lock`
by the `pre-commit` hook
[poetry-to-pre-commit](https://github.com/procrastinate-org/procrastinate/blob/main/.pre-commit-config.yaml#L61).

If you need to recompute the lockfile in your PR, you can use:

```console
$ # Update all the pinned dependencies in pyproject.toml & all versions in poetry.lock
$ # (there are actually no pinned dependencies in pyproject.toml, so this only updates the
$ # lockfile).
$ poetry update

$ # Similarly, update dependencies in the lockfile. In procrastinate, it's equivalent
$ # to the command above
$ poetry lock

$ # Recompute the lockfile (e.g. after the pyproject.toml was updated) without trying
$ # to update anything
$ poetry lock --no-update
```

## Core contributor additional documentation

### Issues
Expand Down

0 comments on commit 8623eca

Please sign in to comment.