arvados-cli 0.1.20151111160124 → 0.1.20151113142812

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/bin/crunch-job +12 -5
  3. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9871ad8965822ce0d375df3c91229e9b458c84f0
4
- data.tar.gz: 21c273ce4146f3bb5fbccd9f784336401deb763f
3
+ metadata.gz: 9bcb8ae09c736d9865677d82cb6323910af2a295
4
+ data.tar.gz: c5fc1244bbc70e3e8f877e0e47df628988737a79
5
5
  SHA512:
6
- metadata.gz: 3f86c42d920b2f550567b09a549b893de9200915d1ac5f84cebed30ae0070ab9a39164e42009a9306720252a690ceb3a605678735efc871649f7da374ef8aaae
7
- data.tar.gz: 61541871026484340ad3ebfa1d714dbb45e9f5bcc98a105113a84379fe41e7ffc83af5e40d6b653e173a78de9370f6cd7a514c50e0012cc3567620f9d33f901e
6
+ metadata.gz: b26edba3728a8c8dd6476806fb0557ba38de645da4d78919826c5ac53e2d020a2c9b9f506dc1f23c20cfd75e35904890f7fcc7cd180adaa2b1d3d4d33999c92e
7
+ data.tar.gz: 3bcd6ab6627deaac21c3fd14d98f219e44c1266c85fa053ff7ff9d84d732f1e08831dc717a84b35732fc736f9451d0d70f7570d6242e4824d008230533001262
data/bin/crunch-job CHANGED
@@ -820,6 +820,9 @@ update_progress_stats();
820
820
  THISROUND:
821
821
  for (my $todo_ptr = 0; $todo_ptr <= $#jobstep_todo; $todo_ptr ++)
822
822
  {
823
+ # Don't create new tasks if we already know the job's final result.
824
+ last if defined($main::success);
825
+
823
826
  my $id = $jobstep_todo[$todo_ptr];
824
827
  my $Jobstep = $jobstep[$id];
825
828
  if ($Jobstep->{level} != $level)
@@ -1018,7 +1021,7 @@ for (my $todo_ptr = 0; $todo_ptr <= $#jobstep_todo; $todo_ptr ++)
1018
1021
  ||
1019
1022
  ($round_num_freeslots > @freeslot && $todo_ptr+1 > $#jobstep_todo))
1020
1023
  {
1021
- last THISROUND if $main::please_freeze || defined($main::success);
1024
+ last THISROUND if $main::please_freeze;
1022
1025
  if ($main::please_info)
1023
1026
  {
1024
1027
  $main::please_info = 0;
@@ -1695,20 +1698,24 @@ sub log_writer_finish()
1695
1698
 
1696
1699
  close($log_pipe_in);
1697
1700
 
1701
+ my $logger_failed = 0;
1698
1702
  my $read_result = log_writer_read_output(120);
1699
1703
  if ($read_result == -1) {
1704
+ $logger_failed = -1;
1700
1705
  Log (undef, "timed out reading from 'arv-put'");
1701
1706
  } elsif ($read_result != 0) {
1707
+ $logger_failed = -2;
1702
1708
  Log(undef, "failed to read arv-put log manifest to EOF");
1703
1709
  }
1704
1710
 
1705
1711
  waitpid($log_pipe_pid, 0);
1706
1712
  if ($?) {
1713
+ $logger_failed ||= $?;
1707
1714
  Log(undef, "log_writer_finish: arv-put exited " . exit_status_s($?))
1708
1715
  }
1709
1716
 
1710
1717
  close($log_pipe_out);
1711
- my $arv_put_output = $log_pipe_out_buf;
1718
+ my $arv_put_output = $logger_failed ? undef : $log_pipe_out_buf;
1712
1719
  $log_pipe_pid = $log_pipe_in = $log_pipe_out = $log_pipe_out_buf =
1713
1720
  $log_pipe_out_select = undef;
1714
1721
 
@@ -1774,13 +1781,13 @@ sub save_meta
1774
1781
  my $justcheckpoint = shift; # false if this will be the last meta saved
1775
1782
  return if $justcheckpoint; # checkpointing is not relevant post-Warehouse.pm
1776
1783
  return unless log_writer_is_active();
1784
+ my $log_manifest = log_writer_finish();
1785
+ return unless defined($log_manifest);
1777
1786
 
1778
- my $log_manifest = "";
1779
1787
  if ($Job->{log}) {
1780
1788
  my $prev_log_coll = api_call("collections/get", uuid => $Job->{log});
1781
- $log_manifest .= $prev_log_coll->{manifest_text};
1789
+ $log_manifest = $prev_log_coll->{manifest_text} . $log_manifest;
1782
1790
  }
1783
- $log_manifest .= log_writer_finish();
1784
1791
 
1785
1792
  my $log_coll = api_call(
1786
1793
  "collections/create", ensure_unique_name => 1, collection => {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: arvados-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.20151111160124
4
+ version: 0.1.20151113142812
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arvados Authors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-11-11 00:00:00.000000000 Z
11
+ date: 2015-11-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: arvados
@@ -178,7 +178,7 @@ dependencies:
178
178
  - - "<"
179
179
  - !ruby/object:Gem::Version
180
180
  version: 1.0.0
181
- description: Arvados command line tools, git commit 3cdc4e8e3668b783f42f887f6a8662b66ecb7f9a
181
+ description: Arvados command line tools, git commit 6de60c7db7a98405ef7ae4ac5eb20498f095416c
182
182
  email: gem-dev@curoverse.com
183
183
  executables:
184
184
  - arv