fmrest-core 0.26.1 → 0.26.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 47bbc3a1dd60de769f11e2e95034ff7e2a88374553251ea5f210b5328551999a
4
- data.tar.gz: a96c1503865da0c440e4ee4516ebb156d4bef6e39d800fced6ad2110cb8b4264
3
+ metadata.gz: d27671c00aed0903a6cbfa70dd2dd3d98fff8bb78819dbfa59b9189f8125cd96
4
+ data.tar.gz: e971d61b21897e0c60d8b281b00e60c496b77b87c8cf62471b8e8845e83221ec
5
5
  SHA512:
6
- metadata.gz: dc5bc00c7e9122511fac018624f5ac8a5faf2102f78cb0ad350e3366fc56cbbb91a32af7975aeee74400c7ade2c456190c5ce2abdf7ba1ef24d7f2830944a037
7
- data.tar.gz: 1eabd5a9c384b7ee398cbae514d350d96eb3c4d7e62e358f005ebcc174da27ed561e08399a2efb6c138a1a7b697921c496f90091ba7ecc7469fca15014fb745f
6
+ metadata.gz: 1f7a31c9f5e56bb29a5816279990518ee8349358dd76a39441e0d0d2af0527cfe770ed5f23ca079c2f94524a472b319025df46917ffeac96e5d3d3422a9328e3
7
+ data.tar.gz: 9c2a60f9ce6e39a0089cc7ff430394dfff7c185d905c63bb187eea6dcb5cce73cbd344b6ca854d1cfd3fd389b2ff6a04183e4845b7a2ff9c2077943a5bf1ff95
data/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  ## Changelog
2
2
 
3
+ ### 0.26.3
4
+
5
+ * Compatibility with faraday-multipart 1.1.0
6
+
7
+ ### 0.26.2
8
+
9
+ * Fix handling of empty container file URLs, now raises
10
+ `FmRest::ContainerFieldError`
11
+
3
12
  ### 0.26.1
4
13
 
5
14
  * Fix downloading of container files in FileMaker 20
data/README.md CHANGED
@@ -588,7 +588,7 @@ FM Data API reference: https://help.claris.com/en/data-api-guide/
588
588
 
589
589
  The latest fmrest-ruby is
590
590
  [tested against](https://github.com/beezwax/fmrest-ruby/actions?query=workflow%3ACI)
591
- Ruby 3.0 through 3.3, and Rails (ActiveSupport) 6.1 through 7.1.
591
+ Ruby 3.0 through 3.3, and Rails (ActiveSupport) 6.1 through 8.0.
592
592
 
593
593
  ## Gem development
594
594
 
@@ -25,15 +25,19 @@ module FmRest
25
25
  def fetch_container_data(container_field_url, base_connection = nil)
26
26
  require "open-uri"
27
27
 
28
+ if container_field_url == ""
29
+ raise FmRest::ContainerFieldError, "Container field URL is empty string"
30
+ end
31
+
28
32
  begin
29
33
  url = URI(container_field_url)
30
- rescue ::URI::InvalidURIError
34
+ rescue ::URI::InvalidURIError, ArgumentError
31
35
  raise FmRest::ContainerFieldError, "Invalid container field URL `#{container_field_url}'"
32
36
  end
33
37
 
34
38
  # Make sure we don't try to open anything on the file:/ URI scheme
35
39
  unless url.scheme.match(/\Ahttps?\Z/)
36
- raise FmRest::ContainerFieldError, "Container URL is not HTTP (#{container_field_url})"
40
+ raise FmRest::ContainerFieldError, "Container field URL is not HTTP (#{container_field_url})"
37
41
  end
38
42
 
39
43
  ssl_options = base_connection && base_connection.ssl && base_connection.ssl.to_hash
@@ -84,7 +88,7 @@ module FmRest
84
88
 
85
89
  connection.post do |request|
86
90
  request.url container_path
87
- request.headers['Content-Type'] = ::Faraday::Multipart::Middleware.mime_type
91
+ request.headers['Content-Type'] = "multipart/form-data"
88
92
 
89
93
  filename = options[:filename] || filename_or_io.try(:original_filename)
90
94
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module FmRest
4
- VERSION = "0.26.1"
4
+ VERSION = "0.26.3"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fmrest-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.26.1
4
+ version: 0.26.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pedro Carbajal
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-01-05 00:00:00.000000000 Z
11
+ date: 2024-12-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -101,7 +101,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
101
101
  - !ruby/object:Gem::Version
102
102
  version: '0'
103
103
  requirements: []
104
- rubygems_version: 3.4.6
104
+ rubygems_version: 3.5.3
105
105
  signing_key:
106
106
  specification_version: 4
107
107
  summary: FileMaker Data API client using Faraday, core library