jenkinsci / jenkinsci/git-plugin

[JENKINS-43220] Setting "Commit in Ancestry" causes errors when there are branches without that commit

Open
#3,070 1 comment 0 reactions 0 assignees View on GitHub
component:git-plugin imported-jira-issue priority:minor resolution:unresolved
Dominant language
Java
Stars
694
Forks
1.1k
Avg merge
1h 29m
Merged PRs (30d)
3

Description

I set up a  project where I added the "Strategy for choosing what to build" behavior and set "Commit in ancestry" to a given commit.

Now when Jenkins polls the repo, it mostly finds branches without that commit, and ends up spitting out "ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job." over and over.

I set this up because the commit in question is in a branch that adds bits needed for Jenkins to do its thing, so other older branches simply cannot be run in Jenkins. Once my branch is merged to master and all the older branches are gone, that won't be needed, but for now this is quite annoying.

 

 

---
Originally reported by autarch, imported from: Setting "Commit in Ancestry" causes errors when there are branches without that commit


  • status: Open
  • priority: Minor
  • component(s): git-plugin
  • resolution: Unresolved
  • votes: 2
  • watchers: 4
  • imported: 2025-12-02

Raw content of original issue

I set up a  project where I added the "Strategy for choosing what to build" behavior and set "Commit in ancestry" to a given commit.

Now when Jenkins polls the repo, it mostly finds branches without that commit, and ends up spitting out "ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job." over and over.

I set this up because the commit in question is in a branch that adds bits needed for Jenkins to do its thing, so other older branches simply cannot be run in Jenkins. Once my branch is merged to master and all the older branches are gone, that won't be needed, but for now this is quite annoying.

 

 

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.