Skip to content

Commit

Permalink
Update version to 4.0.0 (#398)
Browse files Browse the repository at this point in the history
* Add more metadata fields to project metadata

* Add upload instructions to README
  • Loading branch information
cx1111 authored Jun 27, 2022
1 parent a0d8d86 commit 225d2a2
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 13 deletions.
33 changes: 22 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@
[![PhysioNet Project](https://img.shields.io/badge/DOI-10.13026%2Fegpf--2788-blue)](https://doi.org/10.13026/egpf-2788)
[![Supported Python Versions](https://img.shields.io/pypi/pyversions/wfdb.svg)](https://pypi.org/project/wfdb)

## v4 Announcement

[Major breaking changes](/~https://github.com/MIT-LCP/wfdb-python/issues/369) are planned for WFDB v4, in the core APIs, and the installation method. The planned release date is in August 2022.

- Stable v3 documentation: <https://wfdb.readthedocs.io/en/stable/>
- WIP v4 documentation: <https://wfdb.readthedocs.io/en/latest/>

## Introduction

A Python-native package for reading, writing, processing, and plotting physiologic signal and annotation data. The core I/O functionality is based on the Waveform Database (WFDB) [specifications](/~https://github.com/wfdb/wfdb-spec/).
Expand All @@ -35,7 +28,7 @@ pip install wfdb
poetry add wfdb
```

On Linux systems, accessing *compressed* WFDB signal files requires installing `libsndfile`, by running `sudo apt-get install libsndfile1` or `sudo yum install libsndfile`. Support for Apple M1 systems is a work in progess (see </~https://github.com/bastibe/python-soundfile/issues/310> and </~https://github.com/bastibe/python-soundfile/issues/325>).
On Linux systems, accessing _compressed_ WFDB signal files requires installing `libsndfile`, by running `sudo apt-get install libsndfile1` or `sudo yum install libsndfile`. Support for Apple M1 systems is a work in progess (see </~https://github.com/bastibe/python-soundfile/issues/310> and </~https://github.com/bastibe/python-soundfile/issues/325>).

The development version is hosted at: </~https://github.com/MIT-LCP/wfdb-python>. This repository also contains demo scripts and example data. To install the development version, clone or download the repository, navigate to the base directory, and run:

Expand Down Expand Up @@ -68,7 +61,7 @@ Run the formatter with:
black .
```

### Package Management
### Package and Dependency Management

This project uses [poetry](https://python-poetry.org/docs/) for package management and distribution.

Expand All @@ -81,11 +74,29 @@ poetry add --optional <somepackage>

The `[tool.poetry.dev-dependencies]` attribute is NOT used because of a [limitation](/~https://github.com/python-poetry/poetry/issues/3514) that prevents these dependencies from being pip installable. Therefore, dev dependencies are not installed when purely running `poetry install`, and the `--no-dev` flag has no meaning in this project.

Make sure the versions in [version.py](./wfdb/version.py) and [pyproject.toml](./pyproject.toml) are kept in sync.
### Creating Distributions

To upload a new distribution to PyPI:
Make sure the versions in [version.py](./wfdb/version.py) and [pyproject.toml](./pyproject.toml) are updated and kept in sync.

It may be useful to publish to testpypi and preview the changes before publishing to PyPi. However, the project dependencies likely will not be available when trying to install from there.

Setup: configure access to repositories:

```sh
# Create an API token, then add it
poetry config pypi-token.pypi <my-token>

# For testpypi
poetry config repositories.test-pypi https://test.pypi.org/legacy/
poetry config pypi-token.test-pypi <my-testpypi-token>
```

To build and upload a new distribution:

```sh
poetry build

poetry publish -r test-pypi
poetry publish
```

Expand Down
6 changes: 5 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
[tool.poetry]
name = "wfdb"
version = "4.0.0a0"
version = "4.0.0"
description = "The WFDB Python package: tools for reading, writing, and processing physiologic signals and annotations."
authors = ["The Laboratory for Computational Physiology <contact@physionet.org>"]
readme = "README.md"
homepage = "/~https://github.com/MIT-LCP/wfdb-python/"
repository = "/~https://github.com/MIT-LCP/wfdb-python/"
documentation = "https://wfdb.readthedocs.io/"
license = "MIT"

[tool.poetry.dependencies]
Expand Down
2 changes: 1 addition & 1 deletion wfdb/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "4.0.0a0"
__version__ = "4.0.0"

0 comments on commit 225d2a2

Please sign in to comment.