You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm using bump2version in my CI process on CircleCI.
I've mentioned that when the tag already exists, bump2version throws an error like
Adding changes in file 'helm/Chart.yaml' to Git
Adding changes in file '.bumpversion.cfg' to Git
Committing to Git with message '"[skip ci] circleci-bot: bump version 0.54.0 → 0.55.0"'
Tagging 'v0.55.0' with message 'Bump version: 0.54.0 → 0.55.0' in Git and not signing
fatal: tag 'v0.55.0' already exists
Traceback (most recent call last):
File "/usr/bin/bump2version", line 11, in <module>
sys.exit(main())
File "/usr/lib/python3.6/site-packages/bumpversion/cli.py", line 137, in main
_tag_in_vcs(vcs, context, args)
File "/usr/lib/python3.6/site-packages/bumpversion/cli.py", line 728, in _tag_in_vcs
vcs.tag(sign_tags, tag_name, tag_message)
File "/usr/lib/python3.6/site-packages/bumpversion/vcs.py", line 138, in tag
subprocess.check_output(command)
File "/usr/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/usr/lib/python3.6/subprocess.py", line 438, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'tag', 'v0.55.0', '--message', 'Bump version: 0.54.0 → 0.55.0']' returned non-zero exit status 128.
CircleCI received exit code 0
So the git tag command exits with exit code 128, but the bump2version process still exits with an exit code 0, so the build is finished 'successfully'.
Bump2version version is bumpversion: v1.0.1 (using Python v3.6.8)
Bump2version config is:
current_version = 0.54.0
commit = True
tag = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)
message = "[skip ci] circleci-bot: bump version {current_version} → {new_version}"
[bumpversion:file:helm/Chart.yaml]```
Can we add some sort of check or exception to catch this error and exit with a non-zero code please?
The text was updated successfully, but these errors were encountered:
Hi,
I'm using bump2version in my CI process on CircleCI.
I've mentioned that when the tag already exists, bump2version throws an error like
So the
git tag
command exits withexit code 128
, but the bump2version process still exits with anexit code 0
, so the build is finished 'successfully'.Bump2version version is
bumpversion: v1.0.1 (using Python v3.6.8)
Bump2version config is:
The text was updated successfully, but these errors were encountered: