-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Step analyzeCommits suddenly exits 0 without analyzing commits #517
Comments
We have noted the same behaviour. No hint yet. Reproduced locally and it does indeed exit 0. |
I could reproduce this issue locally as well. I tried downgrading every npm package we need for semantic-release to run, which received a new release in the past few days. |
Huge thanks to @angylada for their debugging. If it's helpful for others using - name: Deploy git tag and Gradle plugin release via Semantic Release
uses: cycjimmy/semantic-release-action@v3
with:
# Hard-coding version as workaround https://github.com/semantic-release/commit-analyzer/issues/517#issuecomment-1697193361
extra_plugins: |
@semantic-release/git
@semantic-release/exec
conventional-changelog-conventionalcommits@6.1.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
since we are seeing feedback about this issue coming in though multiple issues, i've created a tracking issue at semantic-release/semantic-release#2929 to centralize the conversation |
summary here, exiting with zero is an issue that we do need to investigate but the root cause is the breaking updates to the conventional-changelog presets that happened over the weekend since you are using a different preset than the default (and therefore installing it separately from semantic-release itself). our focus will be on addressing the preset updates first, but i will leave this issue open so that we follow up by investigating the lack of failure. if someone would be interested in helping to track down that problem in parallel with our efforts focused on presets, we would welcome the help. |
appreciate the investigation here and i can certainly see how this would appear to be related. unfortunately, this was related to the preset updates exposing a gap to how our pipeline stages were protecting (or not as it turned out) against auto merging updates that failed the build. after fixing our pipeline, i reverted the presets that we test against as dev dependencies, but accidentally also reverted the prod dependency that was safe to be merged because of the related naming. in the end, the using a custom preset and installing the latest major version that comes with breaking changes that semantic-release is not ready for is the root issue. installing the previous major version for now should resolve issues for folks seeing this problem |
Just digging around, not 100% sure, maybe someone can have a good look as well. In version 7.0.0 of |
We fixed the issue in our installation reverting to conventional-changelog-conventionalcommits@6.1.0 together with @semantic-release/commit-analyzer@10.0.1 We're using semantic release 20.x actually. We've not tested latest commit-analyzer releases (we will do tomorrow). So it seems that the issue is related to conventional-changelog-conventionalcommits > 6.1.0 as far as we can understand |
See semantic-release/commit-analyzer#517 for more details
See semantic-release/commit-analyzer#517 for more details
See semantic-release/commit-analyzer#517 for more details
Same here... I am using github actions and specifying versions not helping. Today it was planned to do release and BAM.. it is failing... feeling frustruated... Maybe anyone has an idea how to override versions in github action?
but it does not work @spulci are you doing this in github actions file? Maybe you can share full step config? |
Sorry, my CI is actually on Gitlab...but I've just fixed the couple of plugin version stated in my previous message, nothing more. Please double check that you've invalidated your CI cache if any..it could be of help hopefully. |
@spulci but have you specified those versions under extra_plugins: or where? Maybe you can drop here some configs from gitlab? |
I've got the same problem as author of the issue while using official Github Action for Semantic Release – do we have any solution to fix it? |
When i do this for github actions:
it starts to analyze commits but not respecting cofiguration specified in .releaserc.json file for @semantic-release/commit-analyzer |
See semantic-release/commit-analyzer#517 for more details
Yes, I can also confirm this behaviour in our pipeline. We are trying to revert to older version of semantic release. |
In gitlab CI I've got this: before_script:
- npm install @semantic-release/git @semantic-release/commit-analyzer semantic-release-gitlab-registry @semantic-release/release-notes-generator @semantic-release/gitlab @semantic-release/changelog conventional-changelog-conventionalcommits@6 --force --no-save
script:
- npx semantic-release@21 --repositoryUrl ${CI_REPOSITORY_URL} In the npm install you can see some of the plugins I'm using inside my .releaserc.yml I've got in the root of my projects. Just force conventionalcommits to release train 6.x using semantic 21.x. |
it looks like you are confused about the necessary update needed to your config. adding the version to the the odd thing about the config you are showing here is that you are mentioning |
yes, the solution is to specify a version for the conventional-changelog preset that your project is installing rather than using the latest version, as is mentioned a few times in this thread and in semantic-release/semantic-release#2929. the version you specify needs to be for the previous major version since the latest major includes breaking changes that semantic-release is not prepared to work with yet |
i've created semantic-release/semantic-release#2932 to track the problem of exiting with the wrong exit code. with that, i'm going to close this issue. please direct further feedback to either semantic-release/semantic-release#2929 or semantic-release/semantic-release#2932 |
Thanks it worked with this config
|
As part of our CI/CD-pipelines we use semantic-release to create new tags within a self-hosted GitLab instance on dozens of repositories. This has been working steadily for ~2 years, but has been broken rather inexplicable since yesterday on all of them.
While the pipelines seem to succeed, as an exit code 0 is thrown, the
analyzeCommits
step completes without actually analysing found commits:Running with
--debug
I verified commits are still found with correct content, and as we're experiencing it on all pipelines I'm starting to think it has something to do with the plugin itself. I tried running previous versions of both node and semantic-release, but without success.I'm curious if anyone else experiences the same or notices a faulty configuration in YAML's above. What baffles me the most is that it has been working steadily for a long time.
Configuration
We configured the pipeline and semantic-release as follows:
.gitlab-ci.yml
.releaserc.yaml
The text was updated successfully, but these errors were encountered: