Maintenance mode update (#6473)

- Add check for exiting maintenance mode after reloading plugin registry
This commit is contained in:
Oliver 2024-02-13 14:04:00 +11:00 committed by GitHub
parent 0c2f1cceb6
commit f3ca704e97
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -337,6 +337,8 @@ class PluginsRegistry:
collect,
)
_maintenance_mode = get_maintenance_mode()
with maintenance_mode_on():
if collect:
logger.info('Collecting plugins')
@ -347,6 +349,10 @@ class PluginsRegistry:
self.plugins_loaded = True
self._load_plugins(full_reload=full_reload)
# Check if we wish to exit maintenance mode
if not _maintenance_mode:
set_maintenance_mode(False)
self.update_plugin_hash()
self.loading_lock.release()