mirror of
https://github.com/theroyallab/tabbyAPI.git
synced 2026-03-14 15:57:27 +00:00
Config: Add warning on exceptions and clarify parameters
Due to how YAML works, double quotes are bad. Specify a linter in the top of the config_sample file. Signed-off-by: kingbri <bdashore3@proton.me>
This commit is contained in:
7
main.py
7
main.py
@@ -194,7 +194,12 @@ if __name__ == "__main__":
|
||||
try:
|
||||
with open('config.yml', 'r') as config_file:
|
||||
config = yaml.safe_load(config_file) or {}
|
||||
except:
|
||||
except Exception as e:
|
||||
print(
|
||||
"The YAML config couldn't load because of the following error:",
|
||||
f"\n\n{e}",
|
||||
"\n\nTabbyAPI will start anyway and not parse this config file."
|
||||
)
|
||||
config = {}
|
||||
|
||||
# If an initial model name is specified, create a container and load the model
|
||||
|
||||
Reference in New Issue
Block a user