miga-base 1.0.4.0 → 1.0.5.0

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: 2519f1f7a439615e68915b46534a98cdf03c88fa9c64a60dfaa7b6ace394a5ac
4
- data.tar.gz: 642ebe775db70dabbad9a20aec03ef269bc62ea3c32c32c48161caeef2a6efda
3
+ metadata.gz: bc2d6a45a59d47e3490d1e6bbe728961abfc28002c945c0fc371b24277f7abcd
4
+ data.tar.gz: c20265a37c53e403858c592a72b2de801ab6ce12e48f0fe88d886cea41a94413
5
5
  SHA512:
6
- metadata.gz: e99839162d562d5636d246179a82a01cc354bd11b12878348031aab30f3afe27777aa3447757af1d34ed0e0b090f5dbc81a35c05416386fd6d64f2f2b116b4c3
7
- data.tar.gz: 39bc66a47a078fab4f39216a86faa8d50afb19dbadb23175a0d4fa79c40bf84fc42be4b3ba0394130a725a52307728663bc583cd59e717df17582f2b8cae14ba
6
+ metadata.gz: 91804137814911287b5f1395e79b28e2805a0584dfb5ff234ca51a2366d17d497acf8a88ee80e18a1b8dd27a1b159ab3433471f82b389fd741825a1f5da57da5
7
+ data.tar.gz: 97d932379e302a22b2c0f489b5dd6cdd5efe4408c77e9cd32bb3b89efff3bc5f3787d167bc8f46720777dcc4d2efa06fb9b82f77e1903735a4b6e631e20be6f9
@@ -34,7 +34,7 @@ class MiGA::Cli::Action::Run < MiGA::Cli::Action
34
34
  if cli[:env]
35
35
  cli[:project] ||= ENV['PROJECT']
36
36
  cli[:dataset] ||= ENV['DATASET']
37
- cli[:thr] ||= ENV['CORES'].to_i unless ENV['CORES'].nil?
37
+ cli[:thr] = ENV['CORES'].to_i unless ENV['CORES'].nil?
38
38
  cli[:result] = File.basename(cli[:result].to_s, '.bash').to_sym
39
39
  end
40
40
  %i[project dataset result].each do |i|
@@ -183,6 +183,7 @@ module MiGA::Cli::Action::Wf
183
183
  cmd += ['--json', cli[:daemon_json]] unless cli[:daemon_json].nil?
184
184
  cmd += ['--max-jobs', cli[:jobs]] unless cli[:jobs].nil?
185
185
  cmd += ['--ppn', cli[:threads]] unless cli[:threads].nil?
186
+ cmd += ['--debug', MiGA::MiGA.debug_trace? ? '2' : '1'] if MiGA::MiGA.debug?
186
187
  cwd = Dir.pwd
187
188
  call_cli(cmd)
188
189
  Dir.chdir(cwd)
@@ -29,10 +29,18 @@ class MiGA::MiGA
29
29
  ##
30
30
  # Send debug message
31
31
  def DEBUG(*args)
32
- $stderr.puts(*args) if @@DEBUG
32
+ $stderr.puts(*args) if debug?
33
33
  $stderr.puts(
34
34
  caller.map { |v| v.gsub(/^/, ' ') }.join("\n")
35
- ) if @@DEBUG_TRACE
35
+ ) if debug_trace?
36
+ end
37
+
38
+ def debug?
39
+ @@DEBUG ||= false
40
+ end
41
+
42
+ def debug_trace?
43
+ @@DEBUG_TRACE ||= false
36
44
  end
37
45
  end
38
46
  end
data/lib/miga/daemon.rb CHANGED
@@ -329,6 +329,7 @@ class MiGA::Daemon < MiGA::MiGA
329
329
  def launch_job(job, hostk = nil)
330
330
  # Execute job
331
331
  job[:cmd] = job_cmd(job)
332
+ MiGA::MiGA.DEBUG "CMD: #{job[:cmd]}"
332
333
  case runopts(:type)
333
334
  when 'ssh'
334
335
  # Remote job
data/lib/miga/version.rb CHANGED
@@ -12,7 +12,7 @@ module MiGA
12
12
  # - String indicating release status:
13
13
  # - rc* release candidate, not released as gem
14
14
  # - [0-9]+ stable release, released as gem
15
- VERSION = [1.0, 4, 0].freeze
15
+ VERSION = [1.0, 5, 0].freeze
16
16
 
17
17
  ##
18
18
  # Nickname for the current major.minor version.
@@ -20,7 +20,7 @@ module MiGA
20
20
 
21
21
  ##
22
22
  # Date of the current gem release.
23
- VERSION_DATE = Date.new(2021, 6, 16)
23
+ VERSION_DATE = Date.new(2021, 8, 26)
24
24
 
25
25
  ##
26
26
  # References of MiGA
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: miga-base
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4.0
4
+ version: 1.0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Luis M. Rodriguez-R
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-16 00:00:00.000000000 Z
11
+ date: 2021-08-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: daemons