Skip to content

Commit

Permalink
Add a custom Python README.
Browse files Browse the repository at this point in the history
By default Hatch automatically includes the README.md file at the root
of the project as the Python package's description, which shows up when
looking at the package on PyPI. Since the README mostly contains
information about the server this could lead to confusion, with users
trying to start a server when what they really wanted was to be
redirected to the main outpack-py package.

This adds a minimal README with the Python specific information, and a
link to the main package. The new file is referenced from
`pyproject.toml`, ensuring this is what gets used as the description
rather than the default one.
  • Loading branch information
plietar committed Apr 3, 2024
1 parent dbf23fb commit 775c087
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 9 deletions.
11 changes: 2 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -294,15 +294,8 @@ The metadata should be written directly to the request body.

## Python bindings

This crate provides Python bindings for its query parser. The bindings can be installed directly from PyPI using `pip install outpack_query_parser`.

### Local development

```
hatch run python # Start a Python interpreter with the bindings installed
hatch run test # Run the bindings test-suite
hatch run develop # Rebuild the bindings. Necessary whenever changes to Rust code is made.
```
This crate provides Python bindings for its query parser. See
[README.python.md] for details.

## Releasing

Expand Down
17 changes: 17 additions & 0 deletions README.python.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# outpack_query_parser

Python bindings for the outpack query parser. The bindings can be installed
directly from PyPI using `pip install outpack_query_parser`.

This package provides a low-level building block for the Python version of
outpack/orderly. Most users shouldn't need to use this package and should
instead install [outpack-py](https://github.com/mrc-ide/outpack-py), which
provides the high-level functionality.

## Development

```
hatch run python # Start a Python interpreter with the bindings installed
hatch run test # Run the bindings test-suite
hatch run develop # Rebuild the bindings. Necessary whenever changes to Rust code is made.
```
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[project]
name = "outpack_query_parser"
readme = "README.python.md"

[build-system]
requires = ["maturin>=1.0,<2.0"]
Expand Down

0 comments on commit 775c087

Please sign in to comment.