GithubHelp home page GithubHelp logo

Comments (9)

Aricg avatar Aricg commented on June 2, 2024

there is a 5.4.0-alpha.0 visible on the beta branch but it has been visible for months, so If something like this were to have an effect I would imagine it would have had an effect immediately.

git tag --merged beta --sort=creatordate
5.4.0-alpha.0
5.3.0-beta.2
5.2.10
5.2.11
5.3.0-beta.3
5.2.12
5.2.13
5.2.14
5.3.0-beta.4
5.3.0-beta.5
5.3.0-beta.6
5.3.0-beta.7
5.3.0-beta.8
5.3.0-beta.9
5.3.0-beta.10
5.3.0-beta.11
5.3.0-beta.12
5.3.0-beta.13
5.3.0-beta.14
5.3.0-beta.15
5.3.0-beta.16
5.3.0-beta.17
5.3.0-beta.18
5.4.0-beta.1

from semantic-release.

travi avatar travi commented on June 2, 2024

semantic-release version

20.1.0

i agree that this is unexpected behavior, but you are using a version of semantic-release that is several major versions behind current. if you can reproduce this behavior in the current major version, we can explore further, but we would not release a fix for an old major version anyway

from semantic-release.

Aricg avatar Aricg commented on June 2, 2024

Hi @travi after deleting the offending tags I can reproduce from 23.0.6 in dry run mode on my local

npm install -g [email protected]
(also tried 23.0.8)

deleted the offending 5.4.0-beta.1 tags from the origin repo and cloned fresh

git tag --merged beta --sort=creatordate | tail -n 5
5.3.0-beta.14
5.3.0-beta.15
5.3.0-beta.16
5.3.0-beta.17
5.3.0-beta.18

Still unexpectedly getting

Found git tag 5.3.0-beta.18 associated with version 5.3.0-beta.18 on branch beta
Analysis of 5 commits complete: patch 
The next release version is 5.4.0-beta.1
npx semantic-release --dry-run
[11:02:04 a.m.] [semantic-release] › ℹ  Running semantic-release version 23.0.6
(node:28214) ExperimentalWarning: Importing JSON modules is an experimental feature and might change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "verifyConditions" from "@semantic-release/git"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "verifyConditions" from "@semantic-release/gitlab"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "analyzeCommits" from "@semantic-release/commit-analyzer"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "generateNotes" from "@semantic-release/release-notes-generator"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "prepare" from "@google/semantic-release-replace-plugin"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "prepare" from "@semantic-release/git"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "publish" from "@semantic-release/gitlab"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "success" from "@semantic-release/gitlab"
[11:02:04 a.m.] [semantic-release] › ✔  Loaded plugin "fail" from "@semantic-release/gitlab"
[11:04:38 a.m.] [semantic-release] › ⚠  Run automated release from branch beta on repository [email protected]:generic-ml/production/deployments/cloud-platform.git in dry-run mode
[11:04:39 a.m.] [semantic-release] › ✔  Allowed to push to the Git repository
[11:04:39 a.m.] [semantic-release] › ℹ  Start step "verifyConditions" of plugin "@semantic-release/git"
[11:04:39 a.m.] [semantic-release] › ✔  Completed step "verifyConditions" of plugin "@semantic-release/git"
[11:04:39 a.m.] [semantic-release] › ℹ  Start step "verifyConditions" of plugin "@semantic-release/gitlab"
[11:04:39 a.m.] [semantic-release] [@semantic-release/gitlab] › ℹ  Verify GitLab authentication (https://gitlab.com/api/v4)
[11:04:39 a.m.] [semantic-release] › ✔  Completed step "verifyConditions" of plugin "@semantic-release/gitlab"
[11:04:39 a.m.] [semantic-release] › ℹ  Found git tag 5.3.0-beta.18 associated with version 5.3.0-beta.18 on branch beta
[11:04:39 a.m.] [semantic-release] › ℹ  Found 5 commits since last release
[11:04:39 a.m.] [semantic-release] › ℹ  Start step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analyzing commit: chore(release): update tags to version 5.4.0-beta.2
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The commit should not trigger a release
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analyzing commit: fix(storage-service): drop extra 'storage-service' prefix from new resources
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The release type for the commit is patch
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analyzing commit: fix(storage-service): add job to disable archive mode
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The release type for the commit is patch
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analyzing commit: chore(release): update tags to version 5.4.0-beta.1
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The commit should not trigger a release
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analyzing commit: fix(logging-service): fix metrics annotation
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The release type for the commit is patch
[11:04:39 a.m.] [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analysis of 5 commits complete: patch release
[11:04:39 a.m.] [semantic-release] › ✔  Completed step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
[11:04:39 a.m.] [semantic-release] › ℹ  The next release version is 5.4.0-beta.1
[11:04:39 a.m.] [semantic-release] › ℹ  Start step "generateNotes" of plugin "@semantic-release/release-notes-generator"
[11:04:39 a.m.] [semantic-release] › ✔  Completed step "generateNotes" of plugin "@semantic-release/release-notes-generator"
[11:04:39 a.m.] [semantic-release] › ⚠  Skip step "prepare" of plugin "@google/semantic-release-replace-plugin" in dry-run mode
[11:04:39 a.m.] [semantic-release] › ⚠  Skip step "prepare" of plugin "@semantic-release/git" in dry-run mode
[11:04:39 a.m.] [semantic-release] › ⚠  Skip 5.4.0-beta.1 tag creation in dry-run mode
[11:04:39 a.m.] [semantic-release] › ⚠  Skip step "publish" of plugin "@semantic-release/gitlab" in dry-run mode
[11:04:39 a.m.] [semantic-release] › ⚠  Skip step "success" of plugin "@semantic-release/gitlab" in dry-run mode
[11:04:39 a.m.] [semantic-release] › ✔  Published release 5.4.0-beta.1 on beta channel
[11:04:39 a.m.] [semantic-release] › ℹ  Release note for version 5.4.0-beta.1:
# 5.4.0-beta.1 (https://gitlab.com/generic-ml/production/deployments/cloud-platform/compare/5.3.0-beta.18...5.4.0-beta.1) (2024-04-12)

### Bug Fixes

    * logging-service: fix metrics annotation (21b8dd2 (https://gitlab.com/generic-ml/production/deployments/cloud-platform/commit/21b8dd2e154dd0654ec8b5bbd4f51e236acca610))
    * storage-service: add job to disable archive mode (18b1507 (https://gitlab.com/generic-ml/production/deployments/cloud-platform/commit/18b1507dd20aeb5622ea290b44674cb9602c90c8))
    * storage-service: drop extra 'storage-service' prefix from new resources (2735968 (https://gitlab.com/generic-ml/production/deployments/cloud-platform/commit/2735968827c946c4fc552c142d760ff6544be67b))

from semantic-release.

Aricg avatar Aricg commented on June 2, 2024

set "plugins": []
and just the default @semantic-release/[email protected]
is latest as well

[semantic-release] [@semantic-release/commit-analyzer] › ℹ  The release type for the commit is patch
[semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analysis of 5 commits complete: patch release
[semantic-release] › ✔  Completed step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
[semantic-release] › ℹ  The next release version is 5.4.0-beta.1
[semantic-release] › ⚠  Skip 5.4.0-beta.1 tag creation in dry-run mode
npx semantic-release --dry-run --debug
[11:55:39 a.m.] [semantic-release] › ℹ  Running semantic-release version 23.0.6
  semantic-release:config load config from: /Users/agardner/TEMPS/foo-beta-test-fix/.releaserc.json +0ms
  semantic-release:config options values: {
  semantic-release:config   branches: [
  semantic-release:config     'master',
  semantic-release:config     { name: 'beta', prerelease: true },
  semantic-release:config     { name: 'alpha', prerelease: true },
  semantic-release:config     { name: 'test-tagging', prerelease: true },
  semantic-release:config     '+([0-9])?(.{+([0-9]),x}).x'
  semantic-release:config   ],
  semantic-release:config   repositoryUrl: '[email protected]:foo/production/deployments/foo.git',
  semantic-release:config   tagFormat: '${version}',
  semantic-release:config   plugins: [],
  semantic-release:config   _: [],
  semantic-release:config   'dry-run': true,
  semantic-release:config   d: true,
  semantic-release:config   dryRun: true,
  semantic-release:config   debug: true,
  semantic-release:config   '$0': 'semantic-release'
  semantic-release:config } +6ms

from semantic-release.

travi avatar travi commented on June 2, 2024

Thank you for reproducing on current versions.

The output still doesn't make it clear what is resulting in that level bump. It might help to give the full output with the debug flag enabled.

It might be necessary to create a public reproduction so that I can reproduce. Would that be possible?

from semantic-release.

Aricg avatar Aricg commented on June 2, 2024

I added some console.log and it does appear that the 5.4.0-alpha.0 tag visible from the beta branch is what is tripping it up.

LatestVersionFromTags take precedence over newPrereleaseVersion

however this tag has been visible from beta for two months and I cannot explain why this is only happening now..

 [semantic-release] [@semantic-release/commit-analyzer] › ℹ  The release type for the commit is patch
 [semantic-release] [@semantic-release/commit-analyzer] › ℹ  Analysis of 5 commits complete: patch release
 [semantic-release] › ✔  Completed step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
 [semantic-release] › ℹ  Starting next version calculation...
 [semantic-release] › ℹ  Branch type: prerelease, Release type: patch, Channel: beta
 [semantic-release] › ℹ  Parsed last release version: major=5, minor=3, patch=0
 [semantic-release] › ℹ  Handling a prerelease...
 [semantic-release] › ℹ  Last release was a prerelease and in the same channel...
 [semantic-release] › ℹ  Incremented prerelease version from last version: 5.3.0-beta.19
 [semantic-release] › ℹ  Latest version from tags: 5.4.0-alpha.0
 [semantic-release] › ℹ  New version based on type 'patch': 5.4.0
 [semantic-release] › ℹ  Highest version calculated: 5.4.0-beta.1
 [semantic-release] › ℹ  Choosing to advance to a higher base version from tags over continuing the current prerelease sequence.
 [semantic-release] › ℹ  The next release version is 5.4.0-beta.1
 [semantic-release] › ⚠  Skip 5.4.0-beta.1 tag creation in dry-run mode
 [semantic-release] › ✔  Published release 5.4.0-beta.1 on beta channel
 [semantic-release] › ℹ  Release note for version 5.4.0-beta.1:

very confused..

git log --tags="*beta*" --simplify-by-decoration --pretty="format:%ai %d" | grep 5.4.0
2024-02-07 04:02:30 +0000  (tag: 5.4.0-alpha.0, tag: 5.3.0-beta.1)
git tag --contains 5.4.0-alpha.0
5.3.0-beta.1
5.3.0-beta.10
5.3.0-beta.11
5.3.0-beta.12
5.3.0-beta.13
5.3.0-beta.14
5.3.0-beta.15
5.3.0-beta.16
5.3.0-beta.17
5.3.0-beta.18
5.3.0-beta.2
5.3.0-beta.3
5.3.0-beta.4
5.3.0-beta.5
5.3.0-beta.6
5.3.0-beta.7
5.3.0-beta.8
5.3.0-beta.9
5.4.0-alpha.0

from semantic-release.

travi avatar travi commented on June 2, 2024

it does appear that the 5.4.0-alpha.0 tag visible from the beta branch

this likely does explain the reason for the bump. if a branch that contained that alpha version was merged into the beta branch, that would fully be expected behavior

this tag has been visible from beta for two months and I cannot explain why this is only happening now

i dont have a good explanation for this without a public reproduction either. it seems like there is likely more detail about this scenario that we dont understand yet. can you help be understand why the 5.4.0-alpha.0 version exists in the history of this branch and how it was introduced to that branch?

from semantic-release.

Aricg avatar Aricg commented on June 2, 2024

Hi @travi

Deleting the 5.4.0-alpha.0 tag which was visible from the beta branch resolved the issue.

the history of the repo is rewritten and time constraints mean no further investigation is possible, thank you for your time.

closing as 'can't reproduce'

from semantic-release.

Aricg avatar Aricg commented on June 2, 2024

So I figured out what happened.

beta was merged back into alpha at the end of the release

we then incorrectly added the +1 5.4.0-alpha.0 tag by hand to that ref which exists on both branches rather than adding it as a chore commit in the next commit on alpha.

this was noticed a few days later and deleted.

by this time, people had cloned this incorrect tag and later when they pushed that tag got added back but in the past at the the offending ref.

from semantic-release.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.