This has come up in a couple of discussions recently, but if one were to look at the spec for versions and read pre-releases and dev-releases:
Pre-releases
Some projects use an “alpha, beta, release candidate” pre-release cycle to support testing by their users prior to a final release.
If used as part of a project’s development cycle, these pre-releases are indicated by including a pre-release segment in the version identifier:
X.YaN # Alpha release
X.YbN # Beta release
X.YrcN # Release Candidate
X.Y # Final releaseA version identifier that consists solely of a release segment and a pre-release segment is termed a “pre-release”.
The pre-release segment consists of an alphabetical identifier for the pre-release phase, along with a non-negative integer value. Pre-releases for a given release are ordered first by phase (alpha, beta, release candidate) and then by the numerical component within that phase.
Installation tools MAY accept both
c
andrc
releases for a common release segment in order to handle some existing legacy distributions.Installation tools SHOULD interpret
c
versions as being equivalent torc
versions (that is,c1
indicates the same version asrc1
).Build tools, publication tools and index servers SHOULD disallow the creation of both
rc
andc
releases for a common release segment.
Developmental releases
Some projects make regular developmental releases, and system packagers (especially for Linux distributions) may wish to create early releases directly from source control which do not conflict with later project releases.
If used as part of a project’s development cycle, these developmental releases are indicated by including a developmental release segment in the version identifier:
X.Y.devN # Developmental release
A version identifier that includes a developmental release segment is termed a “developmental release”.
The developmental release segment consists of the string .dev, followed by a non-negative integer value. Developmental releases are ordered by their numerical component, immediately before the corresponding release (and before any pre-releases with the same release segment), and following any previous release (including any post-releases).
Developmental releases are also permitted for pre-releases and post-releases:
X.YaN.devM # Developmental release of an alpha release
X.YbN.devM # Developmental release of a beta release
X.YrcN.devM # Developmental release of a release candidate
X.Y.postN.devM # Developmental release of a post-release
Going just by that text I think it’s fairly clear that developmental releases are, by themselves, not a form of pre-release.
However, other parts of the spec, such as “Handling of pre-releases” state otherwise:
Pre-releases of any kind, including developmental releases
And that’s how it’s implemented in packaging:
>>> from packaging.version import Version
>>> Version("1.0dev0").is_prerelease
True
I propose the spec should be clarified to say Developmental releases are a type of pre-release.
Otherwise other parts of the spec, and packaging, should be updated as they are incorrect in their use of the term “pre-release”.