prevent legacy CLI crash caused by removal of convert option

- Compensatory change to the CLI that prevents it from crashing
  when it tries to import a model.
- Bug introduced when the "convert" option removed from the model
  manager.
This commit is contained in:
Lincoln Stein 2023-04-06 15:36:05 -04:00
parent d44151d6ff
commit 32857d81c5

View File

@ -160,12 +160,12 @@ def main():
# try to autoconvert new models # try to autoconvert new models
if path := opt.autoimport: if path := opt.autoimport:
gen.model_manager.heuristic_import( gen.model_manager.heuristic_import(
str(path), convert=False, commit_to_conf=opt.conf str(path), commit_to_conf=opt.conf
) )
if path := opt.autoconvert: if path := opt.autoconvert:
gen.model_manager.heuristic_import( gen.model_manager.heuristic_import(
str(path), convert=True, commit_to_conf=opt.conf str(path), commit_to_conf=opt.conf
) )
# web server loops forever # web server loops forever