quonfig-openfeature 1.1.0 → 2.0.0
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 +44 -0
- data/README.md +18 -1
- data/VERSION +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 20da9ec1d24f20fa576a6430d8cd765b6d821a2cc052e0bfb8f59a5511b8447a
|
|
4
|
+
data.tar.gz: 333ea7e9395c479af7e7768bdb256c79860e7c495e009e9c51e8d14af51807e4
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b3319e1dbd57f6bcfa125befb424e8c2f811dc3c01f921b94c3426a0e62eed5f3ab100a49c372236e68adaa1fde3ca5d259d55af09800c40e0a4043393915c2d
|
|
7
|
+
data.tar.gz: 5cc0aecc4fcd057d426ae31381572bb27e97160dea9e154cc84e85bf668849618d5a2def62c950f3713353aef3c6f1d0c8e386055bcc35cd58b0affd1e3e0321
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,49 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.0.0 - 2026-10-27
|
|
4
|
+
|
|
5
|
+
**BREAKING / UPGRADE (major, qfg-zvyy.6).** This release tracks sdk-ruby 2.0.0, the cross-SDK
|
|
6
|
+
typed-getter contract. Require `quonfig` (sdk-ruby) `>= 2.0.0` (floor raised from `>= 1.11.0`). No
|
|
7
|
+
change to this provider's code: it passes through the SDK's `*_details` results, so provider users
|
|
8
|
+
inherit the contract below.
|
|
9
|
+
|
|
10
|
+
### UPGRADE to 2.0
|
|
11
|
+
|
|
12
|
+
A value a `fetch_*` method cannot read as its type returns your default with reason `ERROR` and
|
|
13
|
+
error code `TYPE_MISMATCH`. Strings are never coerced, and the only number conversions are exact
|
|
14
|
+
ones. What changes for provider users:
|
|
15
|
+
|
|
16
|
+
- `fetch_float_value` on an int config now returns the value (`30` -> `30.0`). 1.x returned your
|
|
17
|
+
default with `TYPE_MISMATCH`.
|
|
18
|
+
- `fetch_integer_value` on a double config returns the value when it is whole and within
|
|
19
|
+
+/-(2^53-1) (`3.0` -> `3`). 1.x returned your default for every double. `3.9`, `2^53` and `1e300`
|
|
20
|
+
still return your default with `TYPE_MISMATCH`, never truncated.
|
|
21
|
+
- `fetch_number_value` on a `duration` config returns your default with `TYPE_MISMATCH`. 1.x
|
|
22
|
+
returned the duration in milliseconds (`30000`, reason `STATIC`). Durations are native-only: use
|
|
23
|
+
`provider.client.get_duration` (integer milliseconds). `fetch_float_value` on a duration already
|
|
24
|
+
returned your default.
|
|
25
|
+
- A malformed stored int or double (for example `"twelve"`) or a malformed ENV_VAR value returns
|
|
26
|
+
your default with error code `TYPE_MISMATCH`, as in sdk-go. 1.x reported `GENERAL`. An unset
|
|
27
|
+
ENV_VAR still returns your default with `GENERAL`.
|
|
28
|
+
- sdk-ruby logs one WARN per key per client when a read returns your default because of a type
|
|
29
|
+
mismatch, a malformed value, an unset ENV_VAR or a decryption failure. The line names the key and
|
|
30
|
+
types, never the value. A wrong decryption key now degrades to your defaults with these WARNs.
|
|
31
|
+
- If you call the native client via `provider.client`: typed getters with a `default:` return the
|
|
32
|
+
default instead of raising, `enabled?` is true only for the bool `true` and never raises, and
|
|
33
|
+
`get_bool` on a stored string `"true"` is a type mismatch. See the sdk-ruby CHANGELOG
|
|
34
|
+
"UPGRADE to 2.0".
|
|
35
|
+
|
|
36
|
+
These already held under 1.11.0 through the provider, and the new tests now pin them: a stored
|
|
37
|
+
string `"true"` / `"false"` read as a boolean, a stored `"3"` read as a number, an int or bool read as
|
|
38
|
+
a string, an int read as a boolean, and a string or bool read as an object all return your default
|
|
39
|
+
with `TYPE_MISMATCH`.
|
|
40
|
+
|
|
41
|
+
### Tests
|
|
42
|
+
|
|
43
|
+
- New `test/integration/test_typed_getter_contract.rb` (31 tests) drives the real provider through
|
|
44
|
+
the OpenFeature client against the integration-test-data `getter.contract.*` fixtures. 7 of the 31
|
|
45
|
+
fail on sdk-ruby 1.11.0; all pass on 2.0.0.
|
|
46
|
+
|
|
3
47
|
## 1.1.0 - 2026-10-23
|
|
4
48
|
|
|
5
49
|
- **UPGRADE: raise the `quonfig` floor from `>= 1.10.0` to `>= 1.11.0`. Requires sdk-ruby 1.11.0:
|
data/README.md
CHANGED
|
@@ -134,13 +134,30 @@ Quonfig features require the native `quonfig` SDK:
|
|
|
134
134
|
|
|
135
135
|
1. **Log levels** -- `should_log?` and the `semantic_logger_filter` are native-only.
|
|
136
136
|
2. **`string_list` configs** -- accessed via `fetch_object_value` and used as `Array<String>`.
|
|
137
|
-
3. **`duration` configs** --
|
|
137
|
+
3. **`duration` configs** -- native-only: read them with `provider.client.get_duration` (integer
|
|
138
|
+
milliseconds). `fetch_float_value` and `fetch_number_value` on a duration config return your
|
|
139
|
+
default with `TYPE_MISMATCH`.
|
|
138
140
|
4. **`bytes` configs** -- not accessible via OpenFeature (no binary type in OF).
|
|
139
141
|
5. **`keys` / raw config inspection** -- native-only via `provider.client`.
|
|
140
142
|
6. **Context keys use dot-notation** -- `"user.email"`, not nested hashes.
|
|
141
143
|
7. **`targeting_key` maps to `user.id` by default** -- configure
|
|
142
144
|
`targeting_key_mapping` if you target a different namespace.
|
|
143
145
|
|
|
146
|
+
## Typed reads
|
|
147
|
+
|
|
148
|
+
Each `fetch_*` method reads only values of its type (the cross-SDK typed-getter contract,
|
|
149
|
+
`quonfig` >= 2.0.0). A value of another type returns your default with reason `ERROR` and error
|
|
150
|
+
code `TYPE_MISMATCH`:
|
|
151
|
+
|
|
152
|
+
- A stored string is never coerced: `"false"` is not a boolean and `"3"` is not a number.
|
|
153
|
+
- Numbers convert only when exact: `fetch_float_value` on an int config returns `30.0`, and
|
|
154
|
+
`fetch_integer_value` on a double config returns the value only when it is whole and within
|
|
155
|
+
+/-(2^53-1) (`3.0` -> `3`; `3.9` is a mismatch, never truncated).
|
|
156
|
+
- A malformed stored or ENV_VAR value (an int `"twelve"`) also returns your default with
|
|
157
|
+
`TYPE_MISMATCH`. An unset ENV_VAR returns your default with `GENERAL`.
|
|
158
|
+
|
|
159
|
+
sdk-ruby logs one WARN per key when a read returns your default for one of these reasons.
|
|
160
|
+
|
|
144
161
|
## Offline / test mode
|
|
145
162
|
|
|
146
163
|
Pass `datadir:` to evaluate against a Quonfig workspace on disk -- the same
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
2.0.0
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: quonfig-openfeature
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 2.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jeff Dwyer
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-10-
|
|
11
|
+
date: 2026-10-27 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: openfeature-sdk
|
|
@@ -30,14 +30,14 @@ dependencies:
|
|
|
30
30
|
requirements:
|
|
31
31
|
- - ">="
|
|
32
32
|
- !ruby/object:Gem::Version
|
|
33
|
-
version:
|
|
33
|
+
version: 2.0.0
|
|
34
34
|
type: :runtime
|
|
35
35
|
prerelease: false
|
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
37
|
requirements:
|
|
38
38
|
- - ">="
|
|
39
39
|
- !ruby/object:Gem::Version
|
|
40
|
-
version:
|
|
40
|
+
version: 2.0.0
|
|
41
41
|
- !ruby/object:Gem::Dependency
|
|
42
42
|
name: minitest
|
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|