Spaces:
Building
Building
Update config_provider.py
Browse files- config_provider.py +12 -12
config_provider.py
CHANGED
@@ -176,18 +176,18 @@ class ConfigProvider:
|
|
176 |
# Load current config for race condition check
|
177 |
try:
|
178 |
current_config = cls._load()
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
# Check for race condition
|
192 |
if config.last_update_date and current_config.last_update_date:
|
193 |
if not timestamps_equal(config.last_update_date, current_config.last_update_date):
|
|
|
176 |
# Load current config for race condition check
|
177 |
try:
|
178 |
current_config = cls._load()
|
179 |
+
|
180 |
+
# Ensure boolean values remain boolean in versions
|
181 |
+
if 'projects' in config_dict:
|
182 |
+
for project in config_dict['projects']:
|
183 |
+
if 'versions' in project:
|
184 |
+
for version in project['versions']:
|
185 |
+
# Force published to be boolean
|
186 |
+
if 'published' in version:
|
187 |
+
version['published'] = bool(version['published'])
|
188 |
+
if 'deleted' in version:
|
189 |
+
version['deleted'] = bool(version['deleted'])
|
190 |
+
|
191 |
# Check for race condition
|
192 |
if config.last_update_date and current_config.last_update_date:
|
193 |
if not timestamps_equal(config.last_update_date, current_config.last_update_date):
|