diff --git a/README.md b/README.md index dbcc3db3..3765c912 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,8 @@ pyNeuroML [![GitHub Org's stars](https://img.shields.io/github/stars/NeuroML?style=social)](https://github.com/NeuroML) [![Twitter Follow](https://img.shields.io/twitter/follow/NeuroML?style=social)](https://twitter.com/NeuroML) [![Gitter](https://badges.gitter.im/NeuroML/community.svg)](https://gitter.im/NeuroML/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) +[![DOI](https://zenodo.org/badge/27832592.svg)](https://zenodo.org/doi/10.5281/zenodo.5744044) + [![All Contributors](https://img.shields.io/badge/all_contributors-17-orange.svg?style=flat-square)](#contributors-) diff --git a/pyneuroml/pynml.py b/pyneuroml/pynml.py index 42d629b2..65f26583 100644 --- a/pyneuroml/pynml.py +++ b/pyneuroml/pynml.py @@ -874,13 +874,13 @@ def _evaluate_arguments(args): exit(0) elif args.validate: - file_types = ["nml"] + file_types = ["nml","xml"] pre_args = "-validate" exit_on_fail = True run_multi = True elif args.validatev1: - file_types = ["nml"] + file_types = ["nml","xml"] pre_args = "-validatev1" exit_on_fail = True run_multi = True diff --git a/pyneuroml/runners.py b/pyneuroml/runners.py index 185394d5..448c2a8c 100644 --- a/pyneuroml/runners.py +++ b/pyneuroml/runners.py @@ -770,14 +770,11 @@ def run_jneuroml( return False if report_jnml_output: - logger.debug( + logger.info( "Successfully ran the following command using pyNeuroML v%s: \n %s" % (__version__, command) ) - logger.debug("Output:\n\n%s" % output) - - # except KeyboardInterrupt as e: - # raise e + logger.info("Output:\n\n%s" % output) except Exception as e: logger.error("*** Execution of jnml has failed! ***") diff --git a/pyneuroml/utils/__init__.py b/pyneuroml/utils/__init__.py index 6bf43fd1..5a7dd075 100644 --- a/pyneuroml/utils/__init__.py +++ b/pyneuroml/utils/__init__.py @@ -35,12 +35,6 @@ logger = logging.getLogger(__name__) logger.setLevel(logging.INFO) -try: - import libsedml -except ModuleNotFoundError: - logger.warning("Please install optional dependencies to use SED-ML features:") - logger.warning("pip install pyneuroml[combine]") - MAX_COLOUR = (255, 0, 0) # type: typing.Tuple[int, int, int] MIN_COLOUR = (255, 255, 0) # type: typing.Tuple[int, int, int] @@ -721,6 +715,13 @@ def get_model_file_list( lems_def_dir = get_model_file_list(inc, filelist, rootdir, lems_def_dir) elif rootfile.endswith(".sedml"): + + try: + import libsedml + except ModuleNotFoundError: + logger.error("Please install optional dependencies to use SED-ML features:") + logger.error("pip install pyneuroml[combine]") + if pathlib.Path(rootfile).is_absolute(): rootdoc = libsedml.readSedMLFromFile(rootfile) else: