Skip to content

mavisp crashes in some cases in which the metadata.yaml file of one entry is not in the right format #414

@mtiberti

Description

@mtiberti

command line:

mavisp -d /data/raw_data/computational_data/mavisp_data_saturation/ -o 11112025_ALL -e ARID3A,CDKN2A-ARF -f

traceback:

Traceback (most recent call last):
  File "/usr/local/envs/mavisp/bin/mavisp", line 8, in <module>
    sys.exit(main())
             ~~~~^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/mavisp/mavisp.py", line 145, in main
    mfs = MAVISpFileSystem( data_dir=in_path,
                            exclude_proteins=excluded_proteins,
                            include_proteins=included_proteins,
                            modes=args.modes)
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/mavisp/core.py", line 64, in __init__
    self.dataset_tables[mode_name] = self._gen_dataset_table(mode, include=include_proteins, exclude=exclude_proteins)
                                     ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/mavisp/core.py", line 93, in _gen_dataset_table
    metadata, metadata_mavisp_criticals = mode.parse_metadata(self.data_dir, system)
                                          ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/mavisp/modes.py", line 98, in parse_metadata
    metadata = self._parse_metadata_file(data_dir, system, self.name)
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/mavisp/modes.py", line 34, in _parse_metadata_file
    return yaml.safe_load(fh)
           ~~~~~~~~~~~~~~^^^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/__init__.py", line 125, in safe_load
    return load(stream, SafeLoader)
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/__init__.py", line 81, in load
    return loader.get_single_data()
           ~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/constructor.py", line 49, in get_single_data
    node = self.get_single_node()
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/composer.py", line 36, in get_single_node
    document = self.compose_document()
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/composer.py", line 55, in compose_document
    node = self.compose_node(None, None)
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/composer.py", line 84, in compose_node
    node = self.compose_mapping_node(anchor)
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/composer.py", line 127, in compose_mapping_node
    while not self.check_event(MappingEndEvent):
              ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/parser.py", line 98, in check_event
    self.current_event = self.state()
                         ~~~~~~~~~~^^
  File "/usr/local/envs/mavisp/lib/python3.13/site-packages/yaml/parser.py", line 438, in parse_block_mapping_key
    raise ParserError("while parsing a block mapping", self.marks[-1],
            "expected <block end>, but found %r" % token.id, token.start_mark)
yaml.parser.ParserError: while parsing a block mapping
  in "/data/raw_data/computational_data/mavisp_data_saturation/AMER1/simple_mode/metadata.yaml", line 1, column 1
expected <block end>, but found '-'
  in "/data/raw_data/computational_data/mavisp_data_saturation/AMER1/simple_mode/metadata.yaml", line 8, column 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions