spree_easypost 6.0.0.rc1 → 6.0.0.rc3

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: 8504147277652ef9c5e93e5d9f88f7ac05273a3ce4424379ed1d066577b36329
4
- data.tar.gz: 670cc90e304b7b593ae5adcea1499698e21afd5fadcc35c3688ba867c1711236
3
+ metadata.gz: 3f21c6cf6ca32e9f90007b58747d28c6c18c778bb6604e0f06c719295d7734f7
4
+ data.tar.gz: 8265e5837030888c0a5ca6e1e98d8f9dde00c070d356b2f75c7f94bed592ea12
5
5
  SHA512:
6
- metadata.gz: 4c0c5a31859685ad546ca47be9bb9a0d171c998070c988bdf6f4bc0fa6f17bb8f4bcdadaad0025d9a2f5454e2252770e20fe7328280119d8c1928f202e664447
7
- data.tar.gz: 972a2606071cbf718b24aa4137dee18b4425a0cf08b2821d7e7da718faa10645176cfd252c1cde2c3254d60337f74c8e37bdbd8d4377b476063614774c43e74f
6
+ metadata.gz: 5bf0f4dff8d6c7b0aad8fc37fd89372f49c5ae6a7da77f1b0712dd87da9f00d1e4ef147d0bea3c88d525fab7b53c4d678ea38b8c9f61e67c48a1e764b8bca081
7
+ data.tar.gz: 96f8ea9c39908951b8fadb1b62c842d792fe6feecb24a3e7d86dc7be9f470023479f1a412ca9d7eaeb996d200fe3e44b09232a4cd2e30c30eaa4232ba976c63a
@@ -22,12 +22,12 @@ module SpreeEasyPost
22
22
  # signer takes legal responsibility for the declared contents, so it names
23
23
  # a person at the merchant rather than the store.
24
24
  preference :customs_signer, :string
25
- preference :customs_contents_type, :string, default: 'merchandise', in: CUSTOMS_CONTENTS_TYPES
25
+ preference :customs_contents_type, :string, default: 'merchandise', choices: CUSTOMS_CONTENTS_TYPES
26
26
  # Who pays duties and taxes on arrival. Defaults to DAP — the recipient is
27
27
  # billed by the carrier. DDP bills the merchant instead, so only choose it
28
28
  # once duties are actually collected from the customer at checkout;
29
29
  # otherwise the merchant absorbs them silently.
30
- preference :incoterm, :string, default: 'DAP', in: INCOTERMS
30
+ preference :incoterm, :string, default: 'DAP', choices: INCOTERMS
31
31
 
32
32
  validates :preferred_incoterm, inclusion: { in: INCOTERMS }, allow_blank: true
33
33
  validates :preferred_customs_contents_type, inclusion: { in: CUSTOMS_CONTENTS_TYPES }, allow_blank: true
@@ -176,7 +176,7 @@ module SpreeEasyPost
176
176
  return unless origin&.country_code == 'US'
177
177
  return unless items.all? { |item| item[:currency].to_s.upcase == 'USD' }
178
178
 
179
- declared_value = items.sum { |item| item[:value].to_f }
179
+ declared_value = items.sum { |item| BigDecimal(item[:value].to_s) }
180
180
  'NOEEI 30.37(a)' if declared_value < EEI_EXEMPTION_LIMIT_USD
181
181
  end
182
182
 
@@ -195,7 +195,7 @@ module SpreeEasyPost
195
195
  {
196
196
  description: variant.customs_description_for_declaration,
197
197
  quantity: item.quantity,
198
- value: (item.price.to_f * item.quantity).round(2),
198
+ value: Spree::Money::Rounding.to_currency(item.price * item.quantity, package.currency).to_f, # EasyPost reads customs values as JSON numbers
199
199
  weight: ounces(item.weight, store),
200
200
  origin_country: variant.country_of_origin.presence,
201
201
  hs_tariff_number: variant.hs_code.presence,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spree_easypost
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.0.rc1
4
+ version: 6.0.0.rc3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vendo Connect Inc.
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2026-10-08 00:00:00.000000000 Z
12
+ date: 2026-10-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: easypost
@@ -31,14 +31,14 @@ dependencies:
31
31
  requirements:
32
32
  - - '='
33
33
  - !ruby/object:Gem::Version
34
- version: 6.0.0.rc1
34
+ version: 6.0.0.rc3
35
35
  type: :runtime
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
39
  - - '='
40
40
  - !ruby/object:Gem::Version
41
- version: 6.0.0.rc1
41
+ version: 6.0.0.rc3
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: vcr
44
44
  requirement: !ruby/object:Gem::Requirement
@@ -75,9 +75,9 @@ licenses:
75
75
  - MIT
76
76
  metadata:
77
77
  bug_tracker_uri: https://github.com/spree/spree/issues
78
- changelog_uri: https://github.com/spree/spree/releases/tag/v6.0.0.rc1
78
+ changelog_uri: https://github.com/spree/spree/releases/tag/v6.0.0.rc3
79
79
  documentation_uri: https://docs.spreecommerce.org/
80
- source_code_uri: https://github.com/spree/spree/tree/v6.0.0.rc1
80
+ source_code_uri: https://github.com/spree/spree/tree/v6.0.0.rc3
81
81
  post_install_message:
82
82
  rdoc_options: []
83
83
  require_paths: