lithic 0.1.0.pre.alpha.18 → 0.1.0.pre.alpha.19
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/CHANGELOG.md +8 -0
 - data/README.md +1 -1
 - data/lib/lithic/file_part.rb +5 -5
 - data/lib/lithic/internal/type/converter.rb +3 -0
 - data/lib/lithic/internal/type/file_input.rb +22 -11
 - data/lib/lithic/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: 05aee8aa5e025c482dcce7eda27b3c395985006317087846d579d0ad8d7991e7
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: cd3fc85b83558917f6c34dce35268e67593914dc57ef1de4148984cfe9921cd8
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: be54eb3eb00a6277372c104183d09f3d6bb7f4b8e771aaa5061084d9c06722b48eb2452e773176d1ea9ccc53584e9bce4585734d2fb80f5be7832a54909ef474
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 1f5aed27dd5929a0a3066f073d5c544c0844c7ecb17bfb4e9f46c76693fecd7b0deeb3abb8dab3175d574afadc5c14ebf958fc81bede86b2ef69d325dc549fa3
         
     | 
    
        data/CHANGELOG.md
    CHANGED
    
    | 
         @@ -1,5 +1,13 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            # Changelog
         
     | 
| 
       2 
2 
     | 
    
         | 
| 
      
 3 
     | 
    
         
            +
            ## 0.1.0-alpha.19 (2025-04-25)
         
     | 
| 
      
 4 
     | 
    
         
            +
             
     | 
| 
      
 5 
     | 
    
         
            +
            Full Changelog: [v0.1.0-alpha.18...v0.1.0-alpha.19](https://github.com/lithic-com/lithic-ruby/compare/v0.1.0-alpha.18...v0.1.0-alpha.19)
         
     | 
| 
      
 6 
     | 
    
         
            +
             
     | 
| 
      
 7 
     | 
    
         
            +
            ### Bug Fixes
         
     | 
| 
      
 8 
     | 
    
         
            +
             
     | 
| 
      
 9 
     | 
    
         
            +
            * make a typo for `FilePart.content` ([4eb5bee](https://github.com/lithic-com/lithic-ruby/commit/4eb5bee30c1bfbc394092b72b338908643010f5a))
         
     | 
| 
      
 10 
     | 
    
         
            +
             
     | 
| 
       3 
11 
     | 
    
         
             
            ## 0.1.0-alpha.18 (2025-04-25)
         
     | 
| 
       4 
12 
     | 
    
         | 
| 
       5 
13 
     | 
    
         
             
            Full Changelog: [v0.1.0-alpha.17...v0.1.0-alpha.18](https://github.com/lithic-com/lithic-ruby/compare/v0.1.0-alpha.17...v0.1.0-alpha.18)
         
     | 
    
        data/README.md
    CHANGED
    
    | 
         @@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application 
     | 
|
| 
       15 
15 
     | 
    
         
             
            <!-- x-release-please-start-version -->
         
     | 
| 
       16 
16 
     | 
    
         | 
| 
       17 
17 
     | 
    
         
             
            ```ruby
         
     | 
| 
       18 
     | 
    
         
            -
            gem "lithic", "~> 0.1.0.pre.alpha. 
     | 
| 
      
 18 
     | 
    
         
            +
            gem "lithic", "~> 0.1.0.pre.alpha.19"
         
     | 
| 
       19 
19 
     | 
    
         
             
            ```
         
     | 
| 
       20 
20 
     | 
    
         | 
| 
       21 
21 
     | 
    
         
             
            <!-- x-release-please-end -->
         
     | 
    
        data/lib/lithic/file_part.rb
    CHANGED
    
    | 
         @@ -15,15 +15,15 @@ module Lithic 
     | 
|
| 
       15 
15 
     | 
    
         
             
                #
         
     | 
| 
       16 
16 
     | 
    
         
             
                # @return [String]
         
     | 
| 
       17 
17 
     | 
    
         
             
                private def read
         
     | 
| 
       18 
     | 
    
         
            -
                  case  
     | 
| 
      
 18 
     | 
    
         
            +
                  case content
         
     | 
| 
       19 
19 
     | 
    
         
             
                  in Pathname
         
     | 
| 
       20 
     | 
    
         
            -
                     
     | 
| 
      
 20 
     | 
    
         
            +
                    content.read(binmode: true)
         
     | 
| 
       21 
21 
     | 
    
         
             
                  in StringIO
         
     | 
| 
       22 
     | 
    
         
            -
                     
     | 
| 
      
 22 
     | 
    
         
            +
                    content.string
         
     | 
| 
       23 
23 
     | 
    
         
             
                  in IO
         
     | 
| 
       24 
     | 
    
         
            -
                     
     | 
| 
      
 24 
     | 
    
         
            +
                    content.read
         
     | 
| 
       25 
25 
     | 
    
         
             
                  in String
         
     | 
| 
       26 
     | 
    
         
            -
                     
     | 
| 
      
 26 
     | 
    
         
            +
                    content
         
     | 
| 
       27 
27 
     | 
    
         
             
                  end
         
     | 
| 
       28 
28 
     | 
    
         
             
                end
         
     | 
| 
       29 
29 
     | 
    
         | 
| 
         @@ -67,17 +67,28 @@ module Lithic 
     | 
|
| 
       67 
67 
     | 
    
         
             
                        end
         
     | 
| 
       68 
68 
     | 
    
         
             
                      end
         
     | 
| 
       69 
69 
     | 
    
         | 
| 
       70 
     | 
    
         
            -
                      #  
     | 
| 
       71 
     | 
    
         
            -
                      # 
     | 
| 
       72 
     | 
    
         
            -
                      # 
     | 
| 
       73 
     | 
    
         
            -
                      # 
     | 
| 
       74 
     | 
    
         
            -
                      # 
     | 
| 
       75 
     | 
    
         
            -
                      # 
     | 
| 
       76 
     | 
    
         
            -
                      #    
     | 
| 
       77 
     | 
    
         
            -
                      # 
     | 
| 
       78 
     | 
    
         
            -
                      # 
     | 
| 
       79 
     | 
    
         
            -
                       
     | 
| 
       80 
     | 
    
         
            -
             
     | 
| 
      
 70 
     | 
    
         
            +
                      # @api private
         
     | 
| 
      
 71 
     | 
    
         
            +
                      #
         
     | 
| 
      
 72 
     | 
    
         
            +
                      # @param value [Pathname, StringIO, IO, String, Object]
         
     | 
| 
      
 73 
     | 
    
         
            +
                      #
         
     | 
| 
      
 74 
     | 
    
         
            +
                      # @param state [Hash{Symbol=>Object}] .
         
     | 
| 
      
 75 
     | 
    
         
            +
                      #
         
     | 
| 
      
 76 
     | 
    
         
            +
                      #   @option state [Boolean] :can_retry
         
     | 
| 
      
 77 
     | 
    
         
            +
                      #
         
     | 
| 
      
 78 
     | 
    
         
            +
                      # @return [Pathname, StringIO, IO, String, Object]
         
     | 
| 
      
 79 
     | 
    
         
            +
                      def dump(value, state:)
         
     | 
| 
      
 80 
     | 
    
         
            +
                        # rubocop:disable Lint/DuplicateBranch
         
     | 
| 
      
 81 
     | 
    
         
            +
                        case value
         
     | 
| 
      
 82 
     | 
    
         
            +
                        in IO
         
     | 
| 
      
 83 
     | 
    
         
            +
                          state[:can_retry] = false
         
     | 
| 
      
 84 
     | 
    
         
            +
                        in Lithic::FilePart if value.content.is_a?(IO)
         
     | 
| 
      
 85 
     | 
    
         
            +
                          state[:can_retry] = false
         
     | 
| 
      
 86 
     | 
    
         
            +
                        else
         
     | 
| 
      
 87 
     | 
    
         
            +
                        end
         
     | 
| 
      
 88 
     | 
    
         
            +
                        # rubocop:enable Lint/DuplicateBranch
         
     | 
| 
      
 89 
     | 
    
         
            +
             
     | 
| 
      
 90 
     | 
    
         
            +
                        value
         
     | 
| 
      
 91 
     | 
    
         
            +
                      end
         
     | 
| 
       81 
92 
     | 
    
         
             
                    end
         
     | 
| 
       82 
93 
     | 
    
         
             
                  end
         
     | 
| 
       83 
94 
     | 
    
         
             
                end
         
     | 
    
        data/lib/lithic/version.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: lithic
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.1.0.pre.alpha. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.1.0.pre.alpha.19
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Lithic
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire:
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2025-04- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2025-04-26 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: connection_pool
         
     |