查询头部分支仍然存在的合并拉取请求

Querying merged pull requests whose head branches still exist

我有一个 GraphQL 查询,它列出了合并和关闭的拉取请求(通过询问拉取请求的 headRef 我可以判断它的分支是否存在):

{
  organization(login: "company") {
    repository(name: "repo") {
      pullRequests(last: 100, states: [CLOSED, MERGED]) {
        nodes {
          headRef {
            name
          }
        }
      }
    }
  }
}

我想要获取所有 headRef 不为空的拉取请求(例如,我希望我可以做类似 pullRequests(last: 100, states: [CLOSED, MERGED], headRef not null) 的事情)。有可能吗,还是我应该继续丢弃 null headRefs?

好吧,毕竟看起来像 I can't query only non-null headRefs