'GitLab Checking pipeline status - running forever

I've enabled the option - Settings/General/Merge Requests/Merge Checks - Pipelines must succeed. Since then every merge requests automatically starts execution of the pipeline which is actually what i want. The problem is that this is running forever , i'm receiving message : Checking pipeline status If i run the pipeline manually from CI/CD Pipelines - Run pipeline finish immediately. I don't understand what is wrong and why it stuck , can i check logs somewhere or something ? For testing , the pipeline is really simple , just exit 1 .. but still not working .. At this stage , "running pipeline" is not listed in pipeline list even if the status in merge request is : Checking pipeline status



Solution 1:[1]

We ran into a case where a merge request does not contain the .gitlab-ci.yml file. The fix is simply to do a rebase

For troubleshooting purposes, pipelines can be run manually on particular branches at CI/CD -> Pipelines -> Run Pipeline

Solution 2:[2]

For me what happened that .gitlab-ci.yml file was having issue as I have mentioned "master" as value for "only" label .. , then everything worked after updating it with my correct branch name which IMO should be "main"

Solution 3:[3]

Encountered this myself just now, using Gitlab shared runners. Tried re-running one individual job from the pipeline in the hope that it would resolve the issue. It did not. The best way is to change the commit id of the latest change in the MR. You can either create an empty commit as suggested by @Bhargav11 or, to keep a cleaner commit history, do

$ git commit --amend --no-edit
$ git push --force

on your branch.

Solution 4:[4]

check if current branch you are checking the pipeline status and branch specified in "only: field" are same only: - master

enter image description here

Solution 5:[5]

Just add an empty commit to trigger it again.

git commit -n -m "commit comment"

Solution 6:[6]

I found what was wrong in my case. The problem was with the runners. There was "Shared runners" enabled by default which caused the confusion. I've just disabled them and enable my own runner and everything started to work as expected. You can check this in CI / CD Settings, I think they are enabled by default. Basically , pipelines are nothing more than a trigger for the runner.. than the runner is responsible for the execution.

Solution 7:[7]

In our case, simply creating a copy of the branch (git checkout -b new-branch-name) and making a new MR with the identical code allowed us to work around the issue. The new MR pipeline executed successfully.

Solution 8:[8]

From GitLab documentation: "Checking pipeline status" message

This message is shown when the merge request has no pipeline associated with the latest commit yet. This might be because:

  • GitLab hasn't finished creating the pipeline yet

  • You are using an external CI service and GitLab hasn't heard back from the service yet.

  • You are not using CI/CD pipelines in your project.

  • You are using CI/CD pipelines in your project, but your configuration prevented a pipeline from running on the source branch for your merge request.

  • The latest pipeline was deleted (this is a known issue).

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Poh Zi How
Solution 2 vikanksh nath
Solution 3 milgner
Solution 4 ANANTH AYYASWAMY
Solution 5 Bhargav Tavethiya
Solution 6 Harry Birimirski
Solution 7 dokkaebi
Solution 8