[ARVADOS] updated: 2741b54c38ed1e32cc9f0129614a00d84f51bca8

Git user git at public.curoverse.com
Wed Mar 22 10:19:42 EDT 2017


Summary of changes:
 services/api/lib/crunch_dispatch.rb | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

       via  2741b54c38ed1e32cc9f0129614a00d84f51bca8 (commit)
      from  077878d94771c25c25edfe01a98a523898916d9e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 2741b54c38ed1e32cc9f0129614a00d84f51bca8
Author: Lucas Di Pentima <lucas at curoverse.com>
Date:   Wed Mar 22 11:18:55 2017 -0300

    11170: Calling close method from an ensure block.

diff --git a/services/api/lib/crunch_dispatch.rb b/services/api/lib/crunch_dispatch.rb
index c95db31..bea1657 100644
--- a/services/api/lib/crunch_dispatch.rb
+++ b/services/api/lib/crunch_dispatch.rb
@@ -964,9 +964,11 @@ class CrunchDispatch
   def squeue_jobs
     if Rails.configuration.crunch_job_wrapper == :slurm_immediate
       p = IO.popen(['squeue', '-a', '-h', '-o', '%j'])
-      l = p.readlines.map {|line| line.strip}
-      p.close
-      l
+      begin
+        p.readlines.map {|line| line.strip}
+      ensure
+        p.close
+      end
     else
       []
     end

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list