ersilia-os / ersilia-pack

Module to pack Ersilia models with FastAPI
GNU General Public License v3.0
0 stars 0 forks source link

Ersilia Pack Linter currently only looks for metadata.json #7

Closed DhanshreeA closed 2 months ago

DhanshreeA commented 2 months ago

We are moving towards letting users specifying model metadata in a YAML syntax for ease of use and readability, however the current implementation of the linter in Ersilia Pack looks for adherence to the current model repository structure (the original eos-template).

Running ersilia_model_lint --repo_path <model> currently gives me:

Traceback (most recent call last):
  File "/home/.pyenv/versions/ersilia-pack/bin/ersilia_model_lint", line 33, in <module>
    sys.exit(load_entry_point('ersilia-pack', 'console_scripts', 'ersilia_model_lint')())
  File "/home/ersilia-project/ersilia-pack/src/linter.py", line 51, in main
    sml = SimpleModelLinter(args.repo_path)
  File "/home/ersilia-project/ersilia-pack/src/linter.py", line 9, in __init__
    self.model_id = self._get_model_id()
  File "/home/ersilia-project/ersilia-pack/src/linter.py", line 12, in _get_model_id
    with open(os.path.join(self.repo_path, "metadata.json")) as f:
FileNotFoundError: [Errno 2] No such file or directory: './eos-template-2/metadata.json'
DhanshreeA commented 2 months ago

This is addressed in ff879e4bcb138569360104b3bcbfd2d00cb494a3