kubernetes_template_rendering 0.2.1.pre.dc.4 → 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: 5661c5542fae565c240f74d80c13ad46f4d2ced02a3b84b8e146b62c72f455d2
4
- data.tar.gz: b59521b0d0dc2be25718961698dc9d43020dd4cc8ff75c5fa6a909ce2f3ed575
3
+ metadata.gz: d4f2b0c2babad49e2d7575342add52164dd884fe4ff5a4d3ddcfa2c03c1b3bce
4
+ data.tar.gz: 9e083a18142eec4c42d509cc2e86b3d459e58fb10a4155b385598aa2a96b4813
5
5
  SHA512:
6
- metadata.gz: 224db8733389c73a84d7b9e280658d3e140df13af4fecf73a9ebb035363007f279ed1677133c03319eb6f7e74a1fae938a3dd5ae3e073ae5194afb6d699a6274
7
- data.tar.gz: 036dc5ee957ae5ff07aafbbc0f4f694d65f8b55e0c1ab37b7cb07d98df6edc1f851bd048589233caec3edecbcbd23dd5e98a971e59de6503fa5b5458eb265050
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
- [_, exit_status] = Process.waitpid2(pid, Process::WNOHANG)
77
- exit_status.success? or raise "Child process #{pid} failed"
77
+ _, exit_status = Process.waitpid2(pid, Process::WNOHANG)
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.4"
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.4
4
+ version: 0.2.1.pre.dc.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Octothorpe