Skip to main content

icrs.releaser

https://github.com/jamadden/icrs.releaser/workflows/tests/badge.svg https://coveralls.io/repos/github/jamadden/icrs.releaser/badge.svg?branch=master Documentation Status

This package provides support for releasing projects using zest.releaser, especially in combination with setuptools_scm.

This package does three things:

  • Insert the correct version number in source files.

    It’s helpful for readers of the source code and the documentation when object docstrings contain abbreviated change logs. Sphinx supports this with the special directives versionadded, versionchanged, and deprecated. For example, a docstring might contain:

    .. versionchanged:: 2.0.1
       Now frob the frizzle correctly when *frob_frizzle* is true.

    But the author of the docstring doesn’t always know what the version number that contains the change will ultimately be. In a scheme like CalVer, that will depend on when the release is made, and in a scheme like SemVer, that will depend on what other changes are part of the release. In either case, it can’t be determined until the release is actually made.

    To solve this, this package has a plugin that lets you write your docstrings like so:

    .. deprecated:: NEXT
       Turns out frobbing the frizzle was a bad idea.

    When a release is made, all .py files that are found in the src/<PROJECT>/ directory are examined for those three directives with an argument of NEXT, and the NEXT value is replaced with the version number the user selected.

    The user will be presented a diff of the changes made and asked whether to commit them before continuing.

  • Removes C compiler flags from the environment.

    You may have custom C compiler flags in your environment (CFLAGS, etc). These may contain non-portable options such as -ffast-math or -march=native that would prevent binary wheels built on your machine from working on other machines.

    This package removes those flags from the environment that builds binary wheels.

  • Makes setuptools_scm respect the version number the user entered.

    zest.releaser asks setuptools what version to use when it tags the repository. It expects to get back the version that the user entered, and which it wrote to disk (typically in setup.py).

    But because setuptools_scm overrides the value stored in setup.py based on the last tag in the repository, this doesn’t work: it would only work if the tag was already made! Instead of getting the correct tag like 0.0.2, zest.releaser wants to create a tag like 0.0.1.dev11+gbeb8b20.

    This package forces setuptools_scm to respect the version that the user entered so that the tag is correct.

Installation And Usage

This package registers certain entry points with zest.releaser when it is installed, so it is only necessary to pip install icrs.releaser and then invoke icrs_release to use the plugins mentioned above.

This package provides the recommended extra to install the same things that zest.releaser[recommended] does.

$ pip install 'icrs.releaser[recommended]'

Changes

1.3.0 (2024-12-10)

  • Use native pkgutil style namespace package.

  • Add support for Python 3.13.

1.2.0 (2024-01-30)

  • Add support for Python 3.11 and 3.12.

  • Drop support for Python 3.8. The minimum supported version is now 3.9.

  • Depend on newer zest.releaser >= 9.1.1.

  • Remove dependency on setuptools; now uses the so-called “native” namespace packages.

  • Add a new release check that forbids having development dependencies (e.g., “icrs.releaser >= 3.0.dev0” would be forbidden). This only works for setuptools projects that have dependencies listed in setup.py.

1.1.0 (2022-03-03)

  • Fix handling the case where the project name is a namespace (icrs.releaser), but the source directory on disk doesn’t include the namespace (src/releaser). This is a legacy case, supported for projects that are transitioning to a standard layout.

1.0.1 (2022-02-25)

  • Add the ‘recommended’ extra for installing the same things that zest.releaser[recommended] does.

1.0.0 (2022-02-25)

  • Initial PyPI release.

Release files for icrs.releaser 1.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for icrs.releaser 1.3.0
File Size Uploaded
icrs_releaser-1.3.0.tar.gz 25.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for icrs.releaser 1.3.0
File Interpreter ABI Platform
icrs.releaser-1.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 45.8 kB

Release files / icrs_releaser-1.3.0.tar.gz

Download URL icrs_releaser-1.3.0.tar.gz
Size 25.4 kB
Tags Source
SHA-256 checksum
How to use checksums
018d102f0681229e954b2b680086139a9c31fc4d40aafe6102d6ca0d340ccb95
BLAKE2b-256 checksum
How to use checksums
b6b389cbdf25d95372b9ccbe65da56d447ae23b2fc1a47701f94d44d405f5c04
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.8

Release files / icrs.releaser-1.3.0-py3-none-any.whl

Download URL icrs.releaser-1.3.0-py3-none-any.whl
Size 20.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b21f487e577128c2267d98a853e8ffc339dde51cd0a6ff2303cb9de875c03cf9
BLAKE2b-256 checksum
How to use checksums
da2815b7291823f9d66c022458d367184976b3939be9fe36218343a2155cee6a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.8

Release history Release notifications | RSS feed

This release

1.3.0 This release

2 release files

1.2.0

2 release files

1.1.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page