quonfig-openfeature 2.2.0 → 2.3.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 +11 -0
- data/VERSION +1 -1
- data/lib/quonfig/openfeature/provider.rb +9 -2
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 43b628f81214e3ced11ab61bcce6a2a84d9dfe8abd1aaec2f90590466c8b5b5c
|
|
4
|
+
data.tar.gz: 53464b81651916ed49c83ed88a95a94829e278ccbff56bfaa5236c4e89ab56a0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2db151d762fa6ae6be9c4197790153deba4b3a083b66101d24524de19c19952fbe6ba247dbf70a3504137c7c9c66243d3f6a144e6a6f8e97ef015352dea484b8
|
|
7
|
+
data.tar.gz: f8434a2390cfd3d55848383562b874d2fd81e1353247df49c35262a76bed642e09d2adcca9c0fe5daf859fed4b3bd5c3c55321e661f9c997a2f19784feddc7f7
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.3.0 - 2026-10-29
|
|
4
|
+
|
|
5
|
+
When sdk-ruby reports error code `PARSE_ERROR` for a value that did not parse (qfg-wg1n), the
|
|
6
|
+
provider now returns it as OpenFeature `PARSE_ERROR` in one read: your default, reason `ERROR`, and
|
|
7
|
+
the SDK's message, variant and flag metadata. Before, an SDK `PARSE_ERROR` came back as `GENERAL`.
|
|
8
|
+
|
|
9
|
+
Nothing changes with the sdk-ruby you run today. sdk-ruby 2.1.0 reports a malformed value as
|
|
10
|
+
`TYPE_MISMATCH`, and the provider still tells the two apart as in 2.1.0: it checks the stored
|
|
11
|
+
`valueType` and reads the config again with the getter for that type. The `quonfig` floor stays
|
|
12
|
+
`>= 2.1.0`.
|
|
13
|
+
|
|
3
14
|
## 2.2.0 - 2026-10-29
|
|
4
15
|
|
|
5
16
|
`fetch_string_value` on a `duration` config returns its stored ISO 8601 text again (reason
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
2.
|
|
1
|
+
2.3.0
|
|
@@ -80,7 +80,12 @@ module Quonfig
|
|
|
80
80
|
'string_list' => :get_string_list_details,
|
|
81
81
|
'json' => :get_json_details
|
|
82
82
|
}.freeze
|
|
83
|
-
|
|
83
|
+
# sdk-ruby's error code for a value that did not parse (a malformed
|
|
84
|
+
# stored value or ENV_VAR value, qfg-wg1n). Matched as a string: the
|
|
85
|
+
# quonfig floor (2.1.0) defines no constant for it and never emits it,
|
|
86
|
+
# so with that SDK the TYPE_MISMATCH re-read in #malformed? still applies.
|
|
87
|
+
SDK_PARSE_ERROR = 'PARSE_ERROR'
|
|
88
|
+
private_constant :READABLE_VALUE_TYPES, :NATIVE_DETAILS_GETTER, :SDK_PARSE_ERROR
|
|
84
89
|
|
|
85
90
|
attr_reader :metadata, :targeting_key_mapping
|
|
86
91
|
|
|
@@ -293,7 +298,8 @@ module Quonfig
|
|
|
293
298
|
# Map a Quonfig::EvaluationDetails to the OpenFeature ResolutionDetails
|
|
294
299
|
# the SDK consumes. The Quonfig SDK's *_details methods don't raise, so
|
|
295
300
|
# this is a pure mapping layer. +parse_error+ reports an ERROR as
|
|
296
|
-
# PARSE_ERROR (see #malformed?)
|
|
301
|
+
# PARSE_ERROR (see #malformed?); an SDK PARSE_ERROR passes straight
|
|
302
|
+
# through in #map_error_code.
|
|
297
303
|
def to_resolution(details, default_value, parse_error: false)
|
|
298
304
|
variant = details.variant
|
|
299
305
|
flag_metadata = details.flag_metadata || {}
|
|
@@ -338,6 +344,7 @@ module Quonfig
|
|
|
338
344
|
when ::Quonfig::EvaluationDetails::ERROR_FLAG_NOT_FOUND then ErrorCode::FLAG_NOT_FOUND
|
|
339
345
|
when ::Quonfig::EvaluationDetails::ERROR_TYPE_MISMATCH then ErrorCode::TYPE_MISMATCH
|
|
340
346
|
when ::Quonfig::EvaluationDetails::ERROR_PROVIDER_NOT_READY then ErrorCode::PROVIDER_NOT_READY
|
|
347
|
+
when SDK_PARSE_ERROR then ErrorCode::PARSE_ERROR
|
|
341
348
|
else ErrorCode::GENERAL
|
|
342
349
|
end
|
|
343
350
|
end
|