cnvrg 2.1.3 → 2.1.5
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/Readme.md +8 -1
- data/lib/cnvrg/cli.rb +10 -2
- data/lib/cnvrg/data.rb +1 -1
- data/lib/cnvrg/helpers/agent.rb +6 -0
- data/lib/cnvrg/version.rb +1 -1
- metadata +2 -2
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: ffe47307abd2feac46497f34ceec95fab9a866324a235db3ab6f0c61129a7a9d
         | 
| 4 | 
            +
              data.tar.gz: cd8316866861c8b16ec4a4d1d001d8da20f79e34ab95ea38a850a8bce79d6d66
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 9b73987d1023e4aa2600ca11555078194398e7e10cb1d0314569aac8ab24a7385a41c4e86e70a169a4502f122e56baa1bde68ea5cb13706c666996c7a92b5244
         | 
| 7 | 
            +
              data.tar.gz: 8dbd96c0b77e8c88d52254d04af38efa20fcab1c003027c8ee4b8e5918dc01ff35ae35505ec5d36687183925847438d5cb49eb8063a2db2ed2784a13e09900d3
         | 
    
        data/Readme.md
    CHANGED
    
    | @@ -88,4 +88,11 @@ | |
| 88 88 | 
             
            * DEV-13815 - Bug: CLI - remove "cnvrg data sync" command
         | 
| 89 89 | 
             
            ## Version v2.1.3
         | 
| 90 90 | 
             
            2022-05-16
         | 
| 91 | 
            -
            * DEV-13981 - Bug: CLI - dataset query clone stuck at 50% then "Killed"
         | 
| 91 | 
            +
            * DEV-13981 - Bug: CLI - dataset query clone stuck at 50% then "Killed"
         | 
| 92 | 
            +
            ## Version v2.1.4
         | 
| 93 | 
            +
            2022-05-22
         | 
| 94 | 
            +
            * DEV-14182 - Bug: Cli - hide 'data upload' command
         | 
| 95 | 
            +
            ## Version v2.1.5
         | 
| 96 | 
            +
            2022-07-31
         | 
| 97 | 
            +
            * DEV-14244 - Bug: CLI - "failed to upload ongoing stats" due to NaN in float
         | 
| 98 | 
            +
            * DEV-14633 - Bug: End sync did not complete, causing the experiment to get stuck in "terminating"
         | 
    
        data/lib/cnvrg/cli.rb
    CHANGED
    
    | @@ -2088,6 +2088,8 @@ module Cnvrg | |
| 2088 2088 | 
             
                method_option :message, :type => :string, :aliases => ["--message"], :desc => "create commit with message", :default => nil
         | 
| 2089 2089 |  | 
| 2090 2090 | 
             
                def upload_data_new(new_branch, verbose, sync, force, tags, chunk_size, message:nil, total_deleted: 0, total_downloaded: 0)
         | 
| 2091 | 
            +
                  log_message("This method is deprecated, please use 'data put' instead. for more info visit our docs: https://app.cnvrg.io/docs/cli/install.html#upload-files-to-a-dataset", Thor::Shell::Color::BLUE, !options["verbose"])
         | 
| 2092 | 
            +
                  return
         | 
| 2091 2093 | 
             
                  begin
         | 
| 2092 2094 | 
             
                    commit, files_list = invoke :start_commit_data,[], :new_branch=> new_branch, :direct=>false, :force =>force, :chunk_size => chunk_size, :message => message
         | 
| 2093 2095 | 
             
                    files_to_upload, upload_errors = invoke :upload_data_files,[commit, files_list: files_list],:new_branch=>new_branch, :verbose =>verbose, :force =>force, :sync =>sync, :chunk_size => chunk_size
         | 
| @@ -4731,8 +4733,14 @@ module Cnvrg | |
| 4731 4733 | 
             
                            end
         | 
| 4732 4734 | 
             
                          end
         | 
| 4733 4735 | 
             
                        else
         | 
| 4734 | 
            -
                           | 
| 4735 | 
            -
             | 
| 4736 | 
            +
                          begin
         | 
| 4737 | 
            +
                            timestamp, value = data_result&.first&.dig('value')
         | 
| 4738 | 
            +
                            stat_value = value.present? ? ("%.2f" % value) : 0 # converting 34.685929244444445 to 34.69
         | 
| 4739 | 
            +
                          rescue => e
         | 
| 4740 | 
            +
                            Cnvrg::Logger.log_info("Failed converting string into float with error: #{e.message}")
         | 
| 4741 | 
            +
                            Cnvrg::Logger.log_error(e)
         | 
| 4742 | 
            +
                            stat_value = 0
         | 
| 4743 | 
            +
                          end
         | 
| 4736 4744 | 
             
                          stat_value = stat_value.to_i == stat_value.to_f ? stat_value.to_i : stat_value.to_f # converting 34.00 to 34
         | 
| 4737 4745 | 
             
                          if query_name.include? 'block'
         | 
| 4738 4746 | 
             
                            stats['block_io'] = {} if stats['block_io'].blank?
         | 
    
        data/lib/cnvrg/data.rb
    CHANGED
    
    | @@ -81,7 +81,7 @@ module Cnvrg | |
| 81 81 | 
             
                  end
         | 
| 82 82 | 
             
                end
         | 
| 83 83 |  | 
| 84 | 
            -
                desc "data upload", "Upload files from local dataset directory to remote server"
         | 
| 84 | 
            +
                desc "data upload", "Upload files from local dataset directory to remote server", :hide => true
         | 
| 85 85 | 
             
                method_option :verbose, :type => :boolean, :aliases => ["-v"], :default => false
         | 
| 86 86 | 
             
                method_option :new_branch, :type => :boolean, :aliases => ["-nb"], :desc => "create new branch of commits"
         | 
| 87 87 | 
             
                method_option :force, :type => :boolean, :aliases => ["-f","--force"], :default => false
         | 
    
        data/lib/cnvrg/helpers/agent.rb
    CHANGED
    
    | @@ -179,11 +179,17 @@ class Cnvrg::Helpers::Agent | |
| 179 179 | 
             
                  end
         | 
| 180 180 | 
             
                end
         | 
| 181 181 | 
             
                @exit_status = $?.exitstatus
         | 
| 182 | 
            +
              rescue NoMethodError => e
         | 
| 183 | 
            +
                log_internal("No Method Error: #{e}", level: LogLevel::ERROR)
         | 
| 184 | 
            +
                @exit_status = 129
         | 
| 182 185 | 
             
              rescue Timeout::Error
         | 
| 183 186 | 
             
                Process.kill(0, @pid)
         | 
| 184 187 | 
             
                @errors << {log: "Command timed out!", timestamp: Time.now}
         | 
| 185 188 | 
             
                log_internal("Command timed out!", level: LogLevel::ERROR)
         | 
| 186 189 | 
             
                @exit_status = 124
         | 
| 190 | 
            +
              rescue => e
         | 
| 191 | 
            +
                log_internal("Error: #{e}", level: LogLevel::ERROR)
         | 
| 192 | 
            +
                @exit_status = 129
         | 
| 187 193 | 
             
              ensure
         | 
| 188 194 | 
             
                retry_command if @retries != 0 and @exit_status !=0
         | 
| 189 195 | 
             
                @exit_status
         | 
    
        data/lib/cnvrg/version.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: cnvrg
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 2.1. | 
| 4 | 
            +
              version: 2.1.5
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Yochay Ettun
         | 
| @@ -10,7 +10,7 @@ authors: | |
| 10 10 | 
             
            autorequire: 
         | 
| 11 11 | 
             
            bindir: bin
         | 
| 12 12 | 
             
            cert_chain: []
         | 
| 13 | 
            -
            date: 2022- | 
| 13 | 
            +
            date: 2022-08-07 00:00:00.000000000 Z
         | 
| 14 14 | 
             
            dependencies:
         | 
| 15 15 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 16 16 | 
             
              name: bundler
         |