sponomarev/circleci-cancel-builds

CircleCI 2.1 error

ilyapuchka opened this issue · 7 comments

Currently migrating to CircleCI 2.1 and while it allows cancelation of redundant builds out of the box it is not conditional, so we keep using this tool. But we started to see issues with jobs query:

jq: error (at <stdin>:2): Cannot index string with string "status"

Any idea what can be causing it?

Hey @ilyapuchka, I'm glad to hear that you're still using it.

Unfortunately, it's no compatible with CircleCI 2.1 since they deprecated Job API.

The thing is that the endpoint to get list of jobs still works though (they may indeed remove it in the future though) and it's possible to get all the jobs.

I've just tried it and received

{
  "message" : "Project not found"
}

😞

hm, strange. I used to get this when was using a wrong token.

It seems like the issue was that some env variables were missing, as soon as we imported them properly it works 👍

@ilyapuchka Can you share your investigation results? What the variables was missing?