Comments (2)
Weird behaviour for CI_COMMIT_BEFORE_SHA
, as reported here:
- https://gitlab.com/gitlab-org/gitlab/-/issues/7898
- https://gitlab.com/gitlab-org/gitlab/-/issues/12850
from dco-check.
Findings:
CI_COMMIT_BEFORE_SHA
is all zeros when pushing a new branch: https://gitlab.com/micro-ROS/ros_tracing/tracetools_analysis/-/jobs/613013361- works when pushing to an existing branch: https://gitlab.com/christophebedard/tracetools_analysis/-/jobs/613067025
- works if I retry that job: https://gitlab.com/christophebedard/tracetools_analysis/-/jobs/613071839
- all zeros if triggered by a schedule: https://gitlab.com/christophebedard/tracetools_analysis/-/jobs/613076623
So the problem seems to be schedules. It would make sense to not run dco-check
or have it do nothing if it's a scheduled pipeline. A simpler solution could be to set commit_hash_base
to commit_hash_head
if commit_hash_base
is all zeros. This way it won't check anything and is rather simple.
However, if the schedule is not on the default branch (which definitely happens), then it will try to check commits off of the default branch (given the current logic in GitlabRetriever.get_commit_range()
), which still doesn't really make sense. Therefore, we could simply detect the schedule (CI_PIPELINE_SOURCE == schedule
) and not do anything/set base to head and mention it in a verbose_print()
.
from dco-check.
Related Issues (20)
- Fails to check commits for a brand new branch on GitLab
- GitLab integration fails with detached pipelines for mere requests HOT 6
- dco-check run as GH action fails after extensive rebase HOT 3
- Add option to exclude some commit authors from DCO checking
- Fails when source branch has been merged in the target branch before HOT 1
- GitLabRetriever does not work with pipelines for merge requests HOT 4
- Please provide aarch64 container HOT 4
- Ignoring specific commits HOT 7
- Update GitHub workflow shield/badge
- maintenance bots that uses generic emails for commits causing dco check fail
- Improve code coverage HOT 1
- Use GitHub action to automatically tag commits
- Fix & improve handling of env vars wrt params and default values
- Codecov job fails because of coverage %
- Add more tests for supported CIs
- Add option to force dco-check to use GitRetriever
- Add license to source tarballs HOT 1
- Python internal error when manually running dco-check pipeline in GitLab
- Mypy detects several possible type errors
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dco-check.