rbbt-util 5.23.24 → 5.23.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/rbbt/util/cmd.rb +1 -0
- data/lib/rbbt/util/misc.rb +1 -1
- data/lib/rbbt/util/misc/concurrent_stream.rb +3 -1
- data/lib/rbbt/util/misc/inspect.rb +1 -1
- data/test/rbbt/util/test_misc.rb +5 -6
- metadata +2 -2
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA1:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 625721aa410028657ae453a55d77e57782e3d7c5
         | 
| 4 | 
            +
              data.tar.gz: 30a323d757baade804120a648538a5f7669aa053
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 3e6ca02574ebf885b77e0d380dfdc84be134fa651f11fe13e011b36b06e944e7d6bcb1ee15338a287096835cb84f2ee9b9f41f594c4b975013888552638f20b2
         | 
| 7 | 
            +
              data.tar.gz: f605dff38ff692d99d438a1082071abbb890a209ffb27cf51f9e9c40e1a431aa2a17f3759dc4cebe723af8d047d4cc4d79304927c06cecf2845404467e8590f5
         | 
    
        data/lib/rbbt/util/cmd.rb
    CHANGED
    
    
    
        data/lib/rbbt/util/misc.rb
    CHANGED
    
    
| @@ -7,7 +7,7 @@ module AbortedStream | |
| 7 7 | 
             
            end
         | 
| 8 8 |  | 
| 9 9 | 
             
            module ConcurrentStream
         | 
| 10 | 
            -
              attr_accessor :threads, :pids, :callback, :abort_callback, :filename, :joined, :aborted, :autojoin, :lockfile, :no_fail, :pair, :thread
         | 
| 10 | 
            +
              attr_accessor :threads, :pids, :callback, :abort_callback, :filename, :joined, :aborted, :autojoin, :lockfile, :no_fail, :pair, :thread, :stream_exception
         | 
| 11 11 |  | 
| 12 12 | 
             
              def self.setup(stream, options = {}, &block)
         | 
| 13 13 |  | 
| @@ -125,6 +125,7 @@ module ConcurrentStream | |
| 125 125 | 
             
                ensure
         | 
| 126 126 | 
             
                  @joined = true
         | 
| 127 127 | 
             
                  lockfile.unlock if lockfile and lockfile.locked?
         | 
| 128 | 
            +
                  raise stream_exception if stream_exception
         | 
| 128 129 | 
             
                end
         | 
| 129 130 | 
             
              end
         | 
| 130 131 |  | 
| @@ -224,6 +225,7 @@ module ConcurrentStream | |
| 224 225 | 
             
                threads.each do |thread|
         | 
| 225 226 | 
             
                  thread.raise exception
         | 
| 226 227 | 
             
                end
         | 
| 228 | 
            +
                self.stream_exception = exception
         | 
| 227 229 |  | 
| 228 230 | 
             
                self.abort
         | 
| 229 231 | 
             
              end
         | 
    
        data/test/rbbt/util/test_misc.rb
    CHANGED
    
    | @@ -428,9 +428,6 @@ eum fugiat quo voluptas nulla pariatur?" | |
| 428 428 | 
             
                assert_equal [737407, ["-----", "-----G", "-----GTTAAT"]], Misc.correct_vcf_mutation(737406, "GTTAAT", "G,GG,GGTTAAT")
         | 
| 429 429 | 
             
              end
         | 
| 430 430 |  | 
| 431 | 
            -
              def test_mutation_to_ensembl_format
         | 
| 432 | 
            -
                assert_equal Misc.mutation_to_ensembl_format("1:100:T", "A"), %w(1 100 100 A/T)
         | 
| 433 | 
            -
              end
         | 
| 434 431 |  | 
| 435 432 | 
             
              def test_fingerprint
         | 
| 436 433 | 
             
                assert_equal '{:a=>1}', Misc.fingerprint({:a => 1})
         | 
| @@ -487,9 +484,11 @@ eum fugiat quo voluptas nulla pariatur?" | |
| 487 484 |  | 
| 488 485 | 
             
              def test_obj2md5
         | 
| 489 486 | 
             
                str = "string" *  1000000
         | 
| 490 | 
            -
                obj1 = [1,2," | 
| 491 | 
            -
             | 
| 492 | 
            -
                 | 
| 487 | 
            +
                obj1 = [1,2,"test_str", 0.3, [1,2,3], {:a => [1,2], :b => str}]
         | 
| 488 | 
            +
             | 
| 489 | 
            +
                obj2 = [1,2,"test_str", 0.3, [1,2,3], {:a => [1,2,3], :b => str}]
         | 
| 490 | 
            +
                obj3 = [1,2,:test_str, 0.3, [1,2,3], {:a => [1,2,"3"], :b => str}]
         | 
| 491 | 
            +
             | 
| 493 492 | 
             
                assert_not_equal Misc.obj2md5(obj1), Misc.obj2md5(obj2)
         | 
| 494 493 | 
             
                assert_equal Misc.obj2md5(obj2), Misc.obj2md5(obj3)
         | 
| 495 494 | 
             
                hash = Hash[*(0..obj1.length).zip(obj1).flatten]
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: rbbt-util
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 5.23. | 
| 4 | 
            +
              version: 5.23.25
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Miguel Vazquez
         | 
| 8 8 | 
             
            autorequire: 
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date: 2018-10- | 
| 11 | 
            +
            date: 2018-10-15 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: rake
         |