diff --git a/InvenTree/InvenTree/ready.py b/InvenTree/InvenTree/ready.py index 0847f3d0e0..c4e7ad0e44 100644 --- a/InvenTree/InvenTree/ready.py +++ b/InvenTree/InvenTree/ready.py @@ -1,6 +1,6 @@ """Functions to check if certain parts of InvenTree are ready.""" -import os +# import os import sys @@ -25,10 +25,11 @@ def isInMainThread(): - The RUN_MAIN env is set in that case. However if --noreload is applied, this variable is not set because there are no different threads. """ - if "runserver" in sys.argv and "--noreload" not in sys.argv: - return os.environ.get('RUN_MAIN', None) == "true" - return True + # if "runserver" in sys.argv and "--noreload" not in sys.argv: + # return os.environ.get('RUN_MAIN', None) == "true" + + # return True def canAppAccessDatabase(allow_test: bool = False, allow_plugins: bool = False, allow_shell: bool = False): @@ -87,6 +88,7 @@ def isPluginRegistryLoaded(): Returns: 'False' if the apps have not been reloaded already to prevent running the ready function twice """ - from plugin import registry + return True + # from plugin import registry - return registry.is_loading + # return registry.is_loading