【问题标题】:GitHub Actions: Filter returns "jq: error Cannot iterate over null (null)"GitHub Actions:过滤器返回“jq:错误无法迭代 null (null)”
【发布时间】:2019-06-08 03:51:39
【问题描述】:

我正在尝试 GitHub Actions 中的过滤器,但它返回此错误:

Digest: sha256:f747d8611fb26448f06a4245e252204859df6c7f81f04c248497c3e68c7740dd
Status: Downloaded newer image for gcr.io/github-actions-images/action-runner:latest
jq: error (at /github/workflow/event.json:1): Cannot iterate over null (null)

这是我的 main.workflow:

workflow "New workflow" {
  on = "push"
  resolves = ["label-filter"]
}

 action "label-filter" {
  uses = "actions/bin/filter@master"
  args = "label ready"
}

 action "./github/testdeploy" {
  uses = "./github/testdeploy"
  needs = "label-filter"
}

尝试引用以前的提交而不是 master (actions/bin/filter@18d4c9c),但是我仍然得到同样的错误。

我的存储库也是私有,不确定这是否与它有关。

谢谢!

【问题讨论】:

    标签: github github-actions


    【解决方案1】:

    在朋友的帮助下,

    标签过滤器不适用于 push 事件:

    [GitHub 的推送事件][1] 的负载中没有 .issue.labels[].name,这是过滤器所需要的 (https://github.com/actions/bin/blob/master/filter/bin/label#L5)

    【讨论】:

      猜你喜欢
      • 2019-09-14
      • 2019-07-14
      • 2015-03-28
      • 2019-08-04
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-10
      相关资源
      最近更新 更多