Merge "Fix node leak when skipping child jobs"

This commit is contained in:
Zuul 2019-01-22 21:44:48 +00:00 committed by Gerrit Code Review
commit 8b79ce972c
2 changed files with 10 additions and 0 deletions

View File

@ -37,9 +37,17 @@
success-url: docs/index.html
run: playbooks/data-return-relative.yaml
# This child job will be skipped in the test case test_data_return_child_jobs.
# In order to verify that this doesn't lead to node leaks attach a nodeset to
# it. Each test case automatically verifies that there are no open node
# requests and no locked nodes left behind.
- job:
name: child
run: playbooks/child.yaml
nodeset:
nodes:
- name: node
label: test
- job:
name: several-zuul-return-parent

View File

@ -2243,6 +2243,8 @@ class QueueItem(object):
build = build_set.getBuild(job.name)
if build and (build.result == 'SUCCESS' or build.paused):
successful_job_names.add(job.name)
elif build and build.result == 'SKIPPED':
pass
else:
nodeset = build_set.getJobNodeSet(job.name)
if nodeset is None: