Skip to content

Commit c94cfd0

Browse files
committed
fix tests
1 parent 868eef8 commit c94cfd0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

reflex/environment.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,9 @@ def interpret_env_var_value(
232232
if len(args) != 2:
233233
msg = f"Invalid mapping type for environment variable {field_name}: {field_type}. Must have exactly two type arguments."
234234
raise ValueError(msg)
235-
items = value.split(":")
235+
if not value.strip():
236+
return {}
237+
items = value.strip().split(":")
236238
if len(items) % 2 != 0:
237239
msg = f"Invalid mapping value: {value!r} for {field_name}. Must be in the format key1:value1:key2:value2"
238240
raise EnvironmentVarValueError(msg)

0 commit comments

Comments
 (0)