Skip to content

Commit d72dfc9

Browse files
committed
lint
1 parent af10986 commit d72dfc9

File tree

1 file changed

+29
-29
lines changed

1 file changed

+29
-29
lines changed

example/openfeature_example.py

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,9 @@ def main():
7676
boolean_details = open_feature_client.get_boolean_details(
7777
"test-boolean-variable", False, context
7878
)
79-
logger.info(f"Variable Key: test-boolean-variable")
80-
logger.info(f"Value: {boolean_details.value}")
81-
logger.info(f"Reason: {boolean_details.reason}")
79+
logger.info("Variable Key: test-boolean-variable")
80+
logger.info("Value: {boolean_details.value}")
81+
logger.info("Reason: {boolean_details.reason}")
8282
if boolean_details.value:
8383
logger.info("✓ Boolean variable is ENABLED")
8484
else:
@@ -92,9 +92,9 @@ def main():
9292
string_details = open_feature_client.get_string_details(
9393
"test-string-variable", "default string", context
9494
)
95-
logger.info(f"Variable Key: test-string-variable")
96-
logger.info(f"Value: {string_details.value}")
97-
logger.info(f"Reason: {string_details.reason}")
95+
logger.info("Variable Key: test-string-variable")
96+
logger.info("Value: {string_details.value}")
97+
logger.info("Reason: {string_details.reason}")
9898

9999
logger.info("\n" + "=" * 60)
100100
logger.info("Testing Number Variable (Integer)")
@@ -104,9 +104,9 @@ def main():
104104
integer_details = open_feature_client.get_integer_details(
105105
"test-number-variable", 0, context
106106
)
107-
logger.info(f"Variable Key: test-number-variable")
108-
logger.info(f"Value: {integer_details.value}")
109-
logger.info(f"Reason: {integer_details.reason}")
107+
logger.info("Variable Key: test-number-variable")
108+
logger.info("Value: {integer_details.value}")
109+
logger.info("Reason: {integer_details.reason}")
110110

111111
logger.info("\n" + "=" * 60)
112112
logger.info("Testing Number Variable (Float)")
@@ -117,8 +117,8 @@ def main():
117117
float_value = open_feature_client.get_float_value(
118118
"test-number-variable", 0.0, context
119119
)
120-
logger.info(f"Variable Key: test-number-variable (as float)")
121-
logger.info(f"Value: {float_value}")
120+
logger.info("Variable Key: test-number-variable (as float)")
121+
logger.info("Value: {float_value}")
122122

123123
logger.info("\n" + "=" * 60)
124124
logger.info("Testing JSON Object Variable")
@@ -128,9 +128,9 @@ def main():
128128
json_details = open_feature_client.get_object_details(
129129
"test-json-variable", {"default": "value"}, context
130130
)
131-
logger.info(f"Variable Key: test-json-variable")
132-
logger.info(f"Value: {json_details.value}")
133-
logger.info(f"Reason: {json_details.reason}")
131+
logger.info("Variable Key: test-json-variable")
132+
logger.info("Value: {json_details.value}")
133+
logger.info("Reason: {json_details.reason}")
134134

135135
logger.info("\n" + "=" * 60)
136136
logger.info("Testing Object Variable - Empty Dictionary")
@@ -140,8 +140,8 @@ def main():
140140
empty_dict_result = open_feature_client.get_object_value(
141141
"test-json-variable", {}, context
142142
)
143-
logger.info(f"Variable Key: test-json-variable (with empty default)")
144-
logger.info(f"Value: {empty_dict_result}")
143+
logger.info("Variable Key: test-json-variable (with empty default)")
144+
logger.info("Value: {empty_dict_result}")
145145

146146
logger.info("\n" + "=" * 60)
147147
logger.info("Testing Object Variable - Mixed Types")
@@ -159,8 +159,8 @@ def main():
159159
mixed_result = open_feature_client.get_object_value(
160160
"test-json-variable", mixed_default, context
161161
)
162-
logger.info(f"Variable Key: test-json-variable (with mixed types)")
163-
logger.info(f"Value: {mixed_result}")
162+
logger.info("Variable Key: test-json-variable (with mixed types)")
163+
logger.info("Value: {mixed_result}")
164164
logger.info(
165165
f"Value types: {[(k, type(v).__name__) for k, v in mixed_result.items()]}"
166166
)
@@ -178,8 +178,8 @@ def main():
178178
string_dict_result = open_feature_client.get_object_value(
179179
"test-json-variable", string_dict_default, context
180180
)
181-
logger.info(f"Variable Key: test-json-variable (all strings)")
182-
logger.info(f"Value: {string_dict_result}")
181+
logger.info("Variable Key: test-json-variable (all strings)")
182+
logger.info("Value: {string_dict_result}")
183183

184184
logger.info("\n" + "=" * 60)
185185
logger.info("Testing Object Variable - Numeric Values")
@@ -190,8 +190,8 @@ def main():
190190
numeric_dict_result = open_feature_client.get_object_value(
191191
"test-json-variable", numeric_dict_default, context
192192
)
193-
logger.info(f"Variable Key: test-json-variable (numeric)")
194-
logger.info(f"Value: {numeric_dict_result}")
193+
logger.info("Variable Key: test-json-variable (numeric)")
194+
logger.info("Value: {numeric_dict_result}")
195195

196196
logger.info("\n" + "=" * 60)
197197
logger.info("Testing Object Variable - Boolean Flags")
@@ -202,8 +202,8 @@ def main():
202202
bool_dict_result = open_feature_client.get_object_value(
203203
"test-json-variable", bool_dict_default, context
204204
)
205-
logger.info(f"Variable Key: test-json-variable (booleans)")
206-
logger.info(f"Value: {bool_dict_result}")
205+
logger.info("Variable Key: test-json-variable (booleans)")
206+
logger.info("Value: {bool_dict_result}")
207207

208208
logger.info("\n" + "=" * 60)
209209
logger.info("Testing Object Variable - With None Values")
@@ -218,8 +218,8 @@ def main():
218218
none_dict_result = open_feature_client.get_object_value(
219219
"test-json-variable", none_dict_default, context
220220
)
221-
logger.info(f"Variable Key: test-json-variable (with None)")
222-
logger.info(f"Value: {none_dict_result}")
221+
logger.info("Variable Key: test-json-variable (with None)")
222+
logger.info("Value: {none_dict_result}")
223223

224224
logger.info("\n" + "=" * 60)
225225
logger.info("Testing Non-Existent Variable (Should Return Default)")
@@ -229,9 +229,9 @@ def main():
229229
nonexistent_details = open_feature_client.get_string_details(
230230
"doesnt-exist", "default fallback value", context
231231
)
232-
logger.info(f"Variable Key: doesnt-exist")
233-
logger.info(f"Value: {nonexistent_details.value}")
234-
logger.info(f"Reason: {nonexistent_details.reason}")
232+
logger.info("Variable Key: doesnt-exist")
233+
logger.info("Value: {nonexistent_details.value}")
234+
logger.info("Reason: {nonexistent_details.reason}")
235235

236236
logger.info("\n" + "=" * 60)
237237
logger.info("All tests completed!")

0 commit comments

Comments
 (0)