Skip to content

Wrong developer version up on v0.14.2 #3826

Closed

Description

@yvonnefroehlich

There is an error with the versioning up on the release of v0.14.2. This is also wrong on the TestPyPi page at https://test.pypi.org/project/pygmt/#history.

website TestPyPi
Image Image

Currently I can not install the developer version via

pip install --upgrade --pre --extra-index-url https://test.pypi.org/simple/ pygmt

and it always installs v0.14.2. To get the developer version I have to use

pip install -i https://test.pypi.org/simple/ pygmt==0.14.1.dev69

Activity

  1. added
    bug
    on Feb 27, 2025
  2. added this to the 0.15.0 milestone on Feb 27, 2025
  3. seisman commented on Feb 28, 2025

    @seisman
    Member

    I also noticed the issue. It's very likely due to limitations in the setuptools_scm packages

  4. seisman commented on Feb 28, 2025

    @seisman
    Member

    The issue is that, v0.14.2 was created from the v0.14.x branch, rather than the main branch.

    The setuptools_scm package uses the following git command (https://setuptools-scm.readthedocs.io/en/latest/config/#setuptools_scm.git.DEFAULT_DESCRIBE) to extract the version information:

    $ git describe --dirty --tags --long --match '*[0-9]*'
    v0.14.0-69-g81fb2e2c6
    

    It means the latest commit on the main branch is 81fb2e2, and it's 69 commits since the latest tag on the main branch (v0.14.0 because v0.14.2 was not created on the main branch).

    PR #3828 is the potential solution to address the issue. The key difference is that, after we release v0.14.0, what's the expected string for the next version? v0.14.1.dev0 or v0.15.0.dev0. Currently, it's v0.14.1.dev0 and as shown in this issue, it causes troubles when we have patch releases not on the main branch. PR #3828 fixes the issue by setting version_scheme=release-branch-semver, then the next dev version is v0.15.0.dev0.

  5. seisman commented on Feb 28, 2025

    @seisman
    Member

    The key difference is that, after we release v0.14.0, what's the expected string for the next version? v0.14.1.dev0 or v0.15.0.dev0.

    Trying to read long PEP440, but it's still unclear to me which one is recommended for dev versions. Since we have a separate branch (e.g., v0.14.x) for patch releases and the main branch is always targeted for the next minor release, I feel v0.15.0.dev0 is more suitable.

  6. seisman commented on Mar 3, 2025

    @seisman
    Member

    The issue should be fixed by PR #3828.

    The version history on TestPyPI looks correct. The dev documentation still shows v0.14.1.dev70. We need to wait for the next docs builds to verify that it works.

  7. added
    maintenance
    on Mar 5, 2025
  8. seisman commented on Mar 5, 2025

    @seisman
    Member

    The dev documentation still shows v0.14.1.dev70. We need to wait for the next docs builds to verify that it works.

    Now the dev version at https://www.pygmt.org/dev/ is correct.

  9. yvonnefroehlich commented on Mar 11, 2025

    @yvonnefroehlich
    MemberAuthor

    The dev documentation still shows v0.14.1.dev70. We need to wait for the next docs builds to verify that it works.

    Now the dev version at https://www.pygmt.org/dev/ is correct.

    Looks good! Thanks @seisman!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugmaintenance

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions