semvec/pypi-packages huggingface dataset:
eth-datacite-validator 0.1.0
Validator for ETH DataCite metadata standards
Requires Python: >=3.10
Keywords: eth, datacite

# DataCite XML Validator CLI

This is a simple Python CLI tool to validate DataCite files in XML format against the [ETH Zurich metadata standard](https://www.dora.lib4ri.ch/psi/islandora/object/psi%3A81336/datastream/PDF/Felder-2025-Recommendation_on_how_to_implement-%28published_version%29.pdf)s. 
This tool has been tested with Python version 3.8 to 3.13, it works for 3.10 to 3.13.

### Results
- If your XML file does not comply with the agreed upon standards, it will not continue to throw warnings.
- If your file complies with the standards, it will then get checked against our recommendations. These are called warnings.
- You can also opt to just get the result.

## Installation

Clone the repository and open the folder.

(Optional) Create a virtual environment:

```bash
python -m venv .venv
# On Unix/macOS:
source .venv/bin/activate
# On Windows:
.venv\Scripts\activate
```

Then simply install the project:
```bash
pip install .
```

## Usage

Within your python environment run the CLI tool with:

```bash
(python) validate-datacite <file-path>
```

Note that this package has the functions validate_datacite_from_file and validate_datacite_from_doi which can be used in scripts.


### Flags
We are providing three flags:
- ``--skip-warnings`` will not check for any warnings (recommendations will not be checked)
- ``--hide-warnings`` will only give you the amount of warnings found, it will hide the actual warnings
- ``--result-only`` will only show you the result, not any info on the actual errors or warnings.

## License
MIT License

## Author

Developed by Yasmin Waldeck at WSL