Commits on master branch showing up with an "x" because a PR is failing

If you look at the latest commit here: https://github.com/vmware/declarative-cluster-management/commits/master

It shows an “x” because a PR based on another branch is currently failing, even though the actual master branch is fine.

This is a bug right? How do I avoid this?

A PR build is built against a “merge preview” commit autogenerated by Github, see https://travis-ci.com/vmware/declarative-cluster-management/builds/127662021#L189.

If there are no more commit to master, I guess this is the commit that went to master when you merged the PR, so its build status was cached.

You can double check this with Github support (since this is their functionality).

This commit

is at the HEAD of the master branch now; and the history suggests to me that it was also on the or-tools branch when this PR

is open. The build that failed https://travis-ci.com/vmware/declarative-cluster-management/builds/127662942 uses this merge commit, which merges thisHEAD of the master to the or-tools branch.

In this sense, the HEAD commit was used for the PR build, which failed, presumably because of the issue(s) on the or-tools branch. It is not entirely clear to me how this is possible, since I’d expect that the normal workflow would either merge the master branch with a merge commit, or rebase (which creates new SHAs).