Skip to content

Bump Increments PATCH Version on ci Commit #695

Closed
@Kurt-von-Laven

Description

@Kurt-von-Laven

Description

commitizen-action cut a spurious patch release when we merged a ci commit, ScribeMD/slack-templates@e2d9df0, to main, because cz bump incorrectly committed a bump. We made many ci commits previously without encountering this issue, and I am not sure what was special about this case.

Steps to reproduce

  1. Run git clone git@github.com:ScribeMD/slack-templates.

  2. Run git checkout 0.6.17^ to checkout the commit that triggered the spurious release.

  3. Refer to our contributing guide if desired to maximize fidelity between our dev environments, but you can most likely get away with simply running commitizen 2.42.1.

  4. Run poetry run cz --no-raise 21 bump --yes --changelog --check-consistency --dry-run. (Omit the poetry run portion if you didn't follow our contributing guide and installed commitizen some other way.)

  5. Observe the following output:

    bump: version 0.6.16 → 0.6.17
    tag to create: 0.6.17
    increment detected: PATCH
    
    ## 0.6.17 (2023-04-05)
    

Current behavior

Here is the pertinent output from commitizen-action:

Commitizen version: 2.42.1
cz --no-raise 21 bump --yes --changelog --check-consistency
bump: version 0.6.16 → 0.6.17
tag to create: 0.6.17
increment detected: PATCH

Desired behavior

Commitizen shouldn't increment the version number when there are no feat, fix, or refactor commits since the previous tag, 0.6.16 in this case.

Screenshots

No response

Environment

  • Commitizen version: 2.42.1
  • Python version: 3.11.2
  • Operating system: Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions