feat(config): split out parse_args and read_config logic from get_config

Having this all in the `get_config` function makes testing hard. Move these two functions to their own methods, and call them on app startup explicitly.
This commit is contained in:
psychedelicious
2024-03-12 00:02:53 +11:00
parent 77b86e9ad5
commit b9884a6166
2 changed files with 16 additions and 19 deletions

View File

@ -4,6 +4,8 @@
from invokeai.app.services.config.config_default import get_config
app_config = get_config()
app_config.parse_args()
app_config.read_config()
if True: # hack to make flake8 happy with imports coming after setting up the config
import asyncio