Reduce plugin related warning messages during migrations (#13428)

- Database is not accessible during this time
This commit is contained in:
Oliver authored and GitHub committed 2026-12-02 22:54:00 +11:00
1 parent a22b5da937
commit 39c22d2b9f
1 file changed
+6 -2
@@ -266,7 +266,10 @@ class PluginsRegistry:
InvenTree.cache.set_session_cache(cache_key, configs)
except (ProgrammingError, OperationalError):
# The database is not ready yet
logger.warning('plugin.registry.get_plugin_configs: Database not ready')
if not InvenTree.ready.isRunningMigrations():
logger.warning(
'plugin.registry.get_plugin_configs: Database not ready'
)
return None
return configs
@@ -422,7 +425,8 @@ class PluginsRegistry:
if configs is None:
# The database is not ready yet
logger.warning('plugin.registry.with_mixin: Database not ready')
if not InvenTree.ready.isRunningMigrations():
logger.warning('plugin.registry.with_mixin: Database not ready')
return []
mixin = str(mixin).lower().strip()