kubernetes_template_rendering 0.2.1.pre.dc.5 → 0.2.1.pre.dc.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 53dae774584941385d8da6cd1d6adc2e1fe5b689d1150008772f3e2cf88a830c
4
- data.tar.gz: de02816725401bc5d55fd9aa83babe79c0ad8165913166d55674da16fda30d96
3
+ metadata.gz: d4f2b0c2babad49e2d7575342add52164dd884fe4ff5a4d3ddcfa2c03c1b3bce
4
+ data.tar.gz: 9e083a18142eec4c42d509cc2e86b3d459e58fb10a4155b385598aa2a96b4813
5
5
  SHA512:
6
- metadata.gz: 75a17c850e564cab7f9baf8666e2104acb6411b41b10b638525f279c2ecda52a38997d428ba2b2700a3daf66d08c6d7362c9e8e9c736845bef386c9ed8514eee
7
- data.tar.gz: 3399af3e06da59d4553c7fe68b5064dbc8a3ddba278f40216bbd23d0f3140fd56bc129b1755c9c61595803230796cb96d55631cd55fb41051dc0db66a650eac2
6
+ metadata.gz: 249a72b3493290a7fe5dd115e4d7d6277b04be0b23a030843c96372e4e2b685dc682d610f4058527169f63e507f23f980697b7dfdad3b7d15e07a4ba0b54d3a5
7
+ data.tar.gz: 3575c715541ac1d8e447ce4e52d1bed1c87f8080eb8f1945fe71ee4f9bc77505f1a39319603a8b02b1481755b92564f2f03bdfee11b0b500715a0f3e8723130a
@@ -68,13 +68,16 @@ module KubernetesTemplateRendering
68
68
  def wait_if_max_forked(child_pids)
69
69
  while child_pids.size >= MAX_FORKED_PROCESSES
70
70
  begin
71
- Process.waitpid # this is a race condition because 1 or more processes could exit before we get here
71
+ pid, exit_status = Process.waitpid2 # this is a race condition because 1 or more processes could exit before we get here
72
+ exit_status.success? or raise "Child process #{pid} failed"
72
73
  rescue SystemCallError # this will happen if they all exited before we called waitpid
73
74
  end
74
75
  child_pids.delete_if do |pid|
75
76
  begin
76
77
  _, exit_status = Process.waitpid2(pid, Process::WNOHANG)
77
- exit_status.success? or raise "Child process #{pid} failed"
78
+ if exit_status
79
+ exit_status.success? or raise "Child process #{pid} failed"
80
+ end
78
81
  rescue Errno::ECHILD # No child processes
79
82
  true
80
83
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module KubernetesTemplateRendering
4
- VERSION = "0.2.1.pre.dc.5"
4
+ VERSION = "0.2.1.pre.dc.6"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kubernetes_template_rendering
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1.pre.dc.5
4
+ version: 0.2.1.pre.dc.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Octothorpe