Interesting API behavior

Jenkins setup: Version 2.414.2

Hi, I am currently writing a bot for jenkins and I am experiencing abnormal API behavior. On the 7th, everything was fine and I could parse the queue. But now I can’t do that, I’ve lost the “name” position

“_class” : “hudson.model.Queue$BuildableItem”,
“actions” : [

  "blocked" : False,
  "buildable" : True,
  "id" : 8,
  "inQueueSince" : 1713376095721,
  "params" : "",
  "stuck" : False,
  "task" : {
    "_class" : "$PlaceholderTask"
  "url" : "queue/item/8/",
  "why" : "Waiting for next available executor",
  "buildableStartMilliseconds" : 1713376095722,
  "pending" : False

Who can tell you how to fix this and remove job names from the queue?

I think this is expected. What you see here is a node step waiting for an executor so it is not a complete job, like freestyle.
You can use queue/api/json?depth=1 to see a bit more information, e.g. the url of the run, from that you could reconstruct the job name

1 Like

thanks, I used the python library. there was initially a depth of 0. I slightly changed the library and everything worked :slight_smile: