Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-67615

Interrupting the cli "build -s" command will leave the job queued if it wasn't started yet

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • cli
    • None
    • Jenkins: 2.263.4
      OS: Linux - 3.10.0-1127.el7.x86_64

      When using the "build -s " command in the cli to wait for the job to finish, and pass any interrupts to the job it works fine it the job was started, it will then be properly aborted. However, if the job is waiting in the queue, it will not be dequeued, instead it will be left there, orphaned. This makes the " -s " switch more or less useless, and I don't think there is a work-around.

          [JENKINS-67615] Interrupting the cli "build -s" command will leave the job queued if it wasn't started yet

          Basil Crow added a comment -

          Hey mats_johnson, thanks for reporting this. It sounds like this should be easy to reproduce. Would you be interested in opening a PR that simply adds a test case demonstrating the problem? The test would be expected to fail, obviously. Getting a reproducible test case in code form would be the first step toward resolving this issue.

          Basil Crow added a comment - Hey mats_johnson , thanks for reporting this. It sounds like this should be easy to reproduce. Would you be interested in opening a PR that simply adds a test case demonstrating the problem? The test would be expected to fail, obviously. Getting a reproducible test case in code form would be the first step toward resolving this issue.

          Mats Johnson added a comment -

          Sorry, we needed a quick solution, so this prompted us to rewrite using declarative pipelines instead.
          Can't spend any more time on the issue, but thought I'd at least notify you guys of the problem.

          Mats Johnson added a comment - Sorry, we needed a quick solution, so this prompted us to rewrite using declarative pipelines instead. Can't spend any more time on the issue, but thought I'd at least notify you guys of the problem.

            Unassigned Unassigned
            mats_johnson Mats Johnson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: