worldwide 1.25.5 → 1.25.6
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/.github/workflows/ci-typescript.yml +2 -2
- data/.github/workflows/npm-release.yml +2 -2
- data/CHANGELOG.md +3 -0
- data/Gemfile.lock +16 -16
- data/lib/worldwide/cldr.rb +58 -7
- data/lib/worldwide/version.rb +1 -1
- data/worldwide.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9995bb8a7911cba1d7e0602921122a2101d9fb4c1420259b8466f9f175f4a72e
|
|
4
|
+
data.tar.gz: 8c0702f3d76fd8eafd7683b31de542e655a33157b9c9c8ff1881cf816c4d75bf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1f07d3fd68d9438584c69c46330df60ae256a4ccd86b1fc8120c43165fa3a1ee4c69a9fed8a292791eeefe18ac9a68a0245e526bb58d99e6f2e6d129b3e2ac15
|
|
7
|
+
data.tar.gz: 77f7959d3aa5d385f6f6012cc9acdfd4e0d7502bb6f2b47bb6a37411a009f394389af071e9948f86d83d7250ab88cc0eadcb35cd99fe56be1fa946f18bbdde3a
|
|
@@ -17,11 +17,11 @@ jobs:
|
|
|
17
17
|
- name: Check out code
|
|
18
18
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
19
19
|
- name: Setup Node
|
|
20
|
-
uses: actions/setup-node@
|
|
20
|
+
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
|
|
21
21
|
with:
|
|
22
22
|
node-version: 20
|
|
23
23
|
- name: Setup PNPM
|
|
24
|
-
uses: pnpm/action-setup@
|
|
24
|
+
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
|
|
25
25
|
with:
|
|
26
26
|
version: 9.1.3
|
|
27
27
|
- name: Install dependencies
|
|
@@ -24,11 +24,11 @@ jobs:
|
|
|
24
24
|
with:
|
|
25
25
|
token: ${{ secrets.SHOPIFY_GH_ACCESS_TOKEN }}
|
|
26
26
|
- name: Setup Node
|
|
27
|
-
uses: actions/setup-node@
|
|
27
|
+
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
|
|
28
28
|
with:
|
|
29
29
|
node-version: 24
|
|
30
30
|
- name: Setup PNPM
|
|
31
|
-
uses: pnpm/action-setup@
|
|
31
|
+
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
|
|
32
32
|
with:
|
|
33
33
|
version: 9.1.3
|
|
34
34
|
- name: Install dependencies
|
data/CHANGELOG.md
CHANGED
|
@@ -29,6 +29,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
|
29
29
|
|
|
30
30
|
---
|
|
31
31
|
|
|
32
|
+
## [1.25.6] - 2026-07-21
|
|
33
|
+
- Bump i18n from 1.14.1 to 1.15.2 (now required as `>= 1.15`) and update `Cldr.with_cldr` to mirror i18n's fiber-aware config and fallbacks storage so the CLDR config still applies on Ruby 3.2+. [#540](https://github.com/Shopify/worldwide/pull/540)
|
|
34
|
+
|
|
32
35
|
## [1.25.5] - 2026-07-14
|
|
33
36
|
- Fix Nova Scotia HST rate from 15% to 14% [#529](https://github.com/Shopify/worldwide/pull/529)
|
|
34
37
|
|
data/Gemfile.lock
CHANGED
|
@@ -13,9 +13,9 @@ GIT
|
|
|
13
13
|
PATH
|
|
14
14
|
remote: .
|
|
15
15
|
specs:
|
|
16
|
-
worldwide (1.25.
|
|
16
|
+
worldwide (1.25.6)
|
|
17
17
|
activesupport (>= 7.0)
|
|
18
|
-
i18n
|
|
18
|
+
i18n (>= 1.15)
|
|
19
19
|
phonelib (~> 0.8)
|
|
20
20
|
|
|
21
21
|
GEM
|
|
@@ -38,14 +38,15 @@ GEM
|
|
|
38
38
|
builder (3.2.4)
|
|
39
39
|
byebug (11.1.3)
|
|
40
40
|
coderay (1.1.3)
|
|
41
|
-
concurrent-ruby (1.
|
|
41
|
+
concurrent-ruby (1.3.7)
|
|
42
42
|
connection_pool (2.4.1)
|
|
43
43
|
drb (2.1.1)
|
|
44
44
|
ruby2_keywords
|
|
45
|
-
i18n (1.
|
|
45
|
+
i18n (1.15.2)
|
|
46
46
|
concurrent-ruby (~> 1.0)
|
|
47
47
|
json (2.7.1)
|
|
48
|
-
language_server-protocol (3.17.0.
|
|
48
|
+
language_server-protocol (3.17.0.6)
|
|
49
|
+
logger (1.7.0)
|
|
49
50
|
method_source (1.1.0)
|
|
50
51
|
minitest (5.17.0)
|
|
51
52
|
minitest-focus (1.3.1)
|
|
@@ -67,7 +68,7 @@ GEM
|
|
|
67
68
|
ast (~> 2.4.1)
|
|
68
69
|
racc
|
|
69
70
|
phonelib (0.10.22)
|
|
70
|
-
|
|
71
|
+
prism (1.9.0)
|
|
71
72
|
pry (0.14.2)
|
|
72
73
|
coderay (~> 1.1)
|
|
73
74
|
method_source (~> 1.0)
|
|
@@ -79,11 +80,13 @@ GEM
|
|
|
79
80
|
racc (1.8.1)
|
|
80
81
|
rainbow (3.1.1)
|
|
81
82
|
rake (13.0.6)
|
|
82
|
-
rake-compiler (1.
|
|
83
|
+
rake-compiler (1.3.1)
|
|
83
84
|
rake
|
|
85
|
+
rbs (3.10.4)
|
|
86
|
+
logger
|
|
87
|
+
tsort
|
|
84
88
|
regexp_parser (2.9.0)
|
|
85
|
-
rexml (3.2
|
|
86
|
-
strscan (>= 3.0.9)
|
|
89
|
+
rexml (3.4.2)
|
|
87
90
|
rubocop (1.62.1)
|
|
88
91
|
json (~> 2.3)
|
|
89
92
|
language_server-protocol (>= 3.17.0)
|
|
@@ -106,19 +109,16 @@ GEM
|
|
|
106
109
|
rubocop (~> 1.0)
|
|
107
110
|
rubocop-shopify (2.12.0)
|
|
108
111
|
rubocop (~> 1.44)
|
|
109
|
-
ruby-lsp (0.
|
|
112
|
+
ruby-lsp (0.26.10)
|
|
110
113
|
language_server-protocol (~> 3.17.0)
|
|
111
|
-
|
|
112
|
-
|
|
114
|
+
prism (>= 1.2, < 2.0)
|
|
115
|
+
rbs (>= 3, < 5)
|
|
113
116
|
ruby-progressbar (1.13.0)
|
|
114
117
|
ruby2_keywords (0.0.5)
|
|
115
118
|
rubyzip (2.3.2)
|
|
116
|
-
sorbet-runtime (0.5.10648)
|
|
117
119
|
stringio (3.1.0)
|
|
118
|
-
strscan (3.1.0)
|
|
119
|
-
syntax_tree (5.3.0)
|
|
120
|
-
prettier_print (>= 1.2.0)
|
|
121
120
|
thor (1.2.1)
|
|
121
|
+
tsort (0.2.0)
|
|
122
122
|
tzinfo (2.0.6)
|
|
123
123
|
concurrent-ruby (~> 1.0)
|
|
124
124
|
unicode-display_width (2.5.0)
|
data/lib/worldwide/cldr.rb
CHANGED
|
@@ -11,6 +11,54 @@ module Worldwide
|
|
|
11
11
|
cldr_config.exception_handler = Worldwide::Config.exception_handler
|
|
12
12
|
end
|
|
13
13
|
|
|
14
|
+
# i18n 1.15 keeps the active config and fallbacks in Fiber storage on Ruby
|
|
15
|
+
# 3.2+ and in thread-local storage otherwise. We must write the same slots
|
|
16
|
+
# i18n reads back, so a Thread.current[:i18n_config] write is not silently
|
|
17
|
+
# ignored on Ruby 3.2+. These strategies mirror i18n's own storage; the one
|
|
18
|
+
# matching the runtime is selected once into STORAGE.
|
|
19
|
+
module FiberStorage
|
|
20
|
+
class << self
|
|
21
|
+
def config
|
|
22
|
+
Fiber[:i18n_config]
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
def config=(value)
|
|
26
|
+
Fiber[:i18n_config] = value
|
|
27
|
+
value.owner = Fiber.current if value.respond_to?(:owner=) && !value.frozen?
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def fallbacks
|
|
31
|
+
Fiber[:i18n_fallbacks]
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
def fallbacks=(value)
|
|
35
|
+
Fiber[:i18n_fallbacks] = value
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
module ThreadStorage
|
|
41
|
+
class << self
|
|
42
|
+
def config
|
|
43
|
+
Thread.current.thread_variable_get(:i18n_config)
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
def config=(value)
|
|
47
|
+
Thread.current.thread_variable_set(:i18n_config, value)
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
def fallbacks
|
|
51
|
+
Thread.current[:i18n_fallbacks]
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
def fallbacks=(value)
|
|
55
|
+
Thread.current[:i18n_fallbacks] = value
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
STORAGE = Fiber.respond_to?(:[]) ? FiberStorage : ThreadStorage
|
|
61
|
+
|
|
14
62
|
class << self
|
|
15
63
|
def fallbacks
|
|
16
64
|
FALLBACKS
|
|
@@ -33,17 +81,20 @@ module Worldwide
|
|
|
33
81
|
end
|
|
34
82
|
|
|
35
83
|
def with_cldr(&block)
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
84
|
+
# Swap the fallbacks slot directly rather than via I18n.fallbacks= so the
|
|
85
|
+
# change stays fiber/thread-local and never clobbers the host
|
|
86
|
+
# application's global fallbacks.
|
|
87
|
+
original_config = STORAGE.config
|
|
88
|
+
original_fallbacks = STORAGE.fallbacks
|
|
39
89
|
locale = I18n.locale
|
|
40
|
-
|
|
41
|
-
|
|
90
|
+
|
|
91
|
+
STORAGE.config = config
|
|
92
|
+
STORAGE.fallbacks = fallbacks
|
|
42
93
|
|
|
43
94
|
I18n.with_locale(locale, &block)
|
|
44
95
|
ensure
|
|
45
|
-
|
|
46
|
-
|
|
96
|
+
STORAGE.config = original_config
|
|
97
|
+
STORAGE.fallbacks = original_fallbacks
|
|
47
98
|
end
|
|
48
99
|
end
|
|
49
100
|
end
|
data/lib/worldwide/version.rb
CHANGED
data/worldwide.gemspec
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: worldwide
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.25.
|
|
4
|
+
version: 1.25.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Shopify
|
|
@@ -29,14 +29,14 @@ dependencies:
|
|
|
29
29
|
requirements:
|
|
30
30
|
- - ">="
|
|
31
31
|
- !ruby/object:Gem::Version
|
|
32
|
-
version: '
|
|
32
|
+
version: '1.15'
|
|
33
33
|
type: :runtime
|
|
34
34
|
prerelease: false
|
|
35
35
|
version_requirements: !ruby/object:Gem::Requirement
|
|
36
36
|
requirements:
|
|
37
37
|
- - ">="
|
|
38
38
|
- !ruby/object:Gem::Version
|
|
39
|
-
version: '
|
|
39
|
+
version: '1.15'
|
|
40
40
|
- !ruby/object:Gem::Dependency
|
|
41
41
|
name: phonelib
|
|
42
42
|
requirement: !ruby/object:Gem::Requirement
|