feat: add settings.lnbits_running (#2450)

* feat: add `settings.lnbits_runing `
This commit is contained in:
Vlad Stan
2024-04-22 12:33:53 +03:00
committed by GitHub
parent e91096c535
commit 4ac30116a9
21 changed files with 41 additions and 26 deletions
+6
View File
@@ -423,6 +423,12 @@ class TransientSettings(InstalledExtensionsSettings):
# - are cleared on server restart
first_install: bool = Field(default=False)
# Indicates that the server should continue to run.
# When set to false it indicates that the shutdown procedure is ongoing.
# If false no new tasks, threads, etc should be started.
# Long running while loops should use this flag instead of `while True:`
lnbits_running: bool = Field(default=True)
@classmethod
def readonly_fields(cls):
return [f for f in inspect.signature(cls).parameters if not f.startswith("_")]