sushi_fabric 1.1.9 → 1.2.1

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: a1018e406de9a52abc0c904f94990e5370ae7791cb7460081b6d5f9d38b1292c
4
- data.tar.gz: e70a1fa7f02f6947ec6752bcd65c55aae2151badc6797d16fa1024a5f13b248d
3
+ metadata.gz: 4b09cd3b4d6a3357e0dcb22f20446c1bba615316d6aba33f13eb84608d4ffa25
4
+ data.tar.gz: 2f0ebf4ad1ac5df177df7371565da896eaebc9adea188ecbca6648c2339412c1
5
5
  SHA512:
6
- metadata.gz: 2425522c912c4d289053d97027d8c53553f1fa0503c610db77b67db7ad4786865c642ea6d5f3d380c41f38df0b0371dd6bb6603927af98f54369e7b9062ac5cb
7
- data.tar.gz: c165c1dd223dbbb9eb508576935d92e6254611cfabb19654085224a418d2980b9012fa2d8241ac0d6828e6c189718764f9db92e81b76c9c7c95aef5bf086e10d
6
+ metadata.gz: '0548d2078159ddd9c926663ec250bc1869ec02ea92b8e2689ffb048c731c982556f745e77f021b33b214ea568444f6096537b5b3aef0dcfc956276a13e20060f'
7
+ data.tar.gz: de17c3cad3cc3bf8f81e7d37f3bb65ca2135624d3efa5c235a48ba70c32a33d2bcc3ef1e9e6a52301da224c33adb05d82f6e5fb9a3379886602badf2f7aa60e1
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ruby
2
2
  # encoding: utf-8
3
- # Version = '20230404-132741'
3
+ # Version = '20230622-143640'
4
4
 
5
5
  require 'csv'
6
6
  require 'fileutils'
@@ -349,7 +349,7 @@ class SushiApp
349
349
  end
350
350
  def check_application_parameters
351
351
  if @required_params and (@required_params - @params.keys).empty?
352
- @output_params = @params.clone
352
+ @output_params = {"sushi_app" => self.class}.merge(@params.clone)
353
353
  end
354
354
  end
355
355
  def set_user_parameters
@@ -588,9 +588,8 @@ rm -rf #{@scratch_dir} || exit 1
588
588
  def save_parameters_as_tsv
589
589
  file_path = File.join(@scratch_result_dir, @parameter_file)
590
590
  CSV.open(file_path, 'w', :col_sep=>"\t") do |out|
591
- out << ["sushi_app", self.class.name]
592
591
  @output_params.each do |key, value|
593
- if @output_params[key, 'file_upload']
592
+ if @output_params[key, 'file_upload'] and !value.to_s.empty?
594
593
  uploaded_file_path = File.join(@result_dir, "uploaded", File.basename(value))
595
594
  out << [key, uploaded_file_path]
596
595
  @params[key] = uploaded_file_path
@@ -651,7 +650,7 @@ rm -rf #{@scratch_dir} || exit 1
651
650
  end
652
651
  def copy_uploaded_files
653
652
  if not @uploaded_files.empty?
654
- @uploaded_files.each do |file|
653
+ @uploaded_files.compact.select{|file| !file.empty?}.each do |file|
655
654
  FileUtils.cp(file, @uploaded_files_dir)
656
655
  command = "cp #{file} #{@uploaded_files_dir}"
657
656
  puts command
@@ -813,7 +812,6 @@ rm -rf #{@scratch_dir} || exit 1
813
812
  end
814
813
  def save_parameters_in_sushi_db
815
814
  if @next_dataset_id and next_dataset = DataSet.find_by_id(@next_dataset_id)
816
- @output_params['sushi_app'] = self.class
817
815
  next_dataset.job_parameters = @output_params
818
816
  next_dataset.save
819
817
  end
@@ -1,3 +1,3 @@
1
1
  module SushiFabric
2
- VERSION = "1.1.9"
2
+ VERSION = "1.2.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sushi_fabric
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.9
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Functional Genomics Center Zurich
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-04-04 00:00:00.000000000 Z
11
+ date: 2023-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler