-
Notifications
You must be signed in to change notification settings - Fork 1
feat(curations): Minor fix and tests #12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- VcsType was not properly accepting correct string values, but list instead. Fixed to proper validate entry - Added VcsInfoCurationData and replaced VcsInfo in PackageCurationData - Add Ort documentation examples as a test set Signed-off-by: Helio Chissini de Castro <helio.chissini.de.castro@cariad.technology>
Signed-off-by: Helio Chissini de Castro <helio.chissini.de.castro@cariad.technology>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds support for package curations with VCS type handling improvements and test coverage. The version is bumped from 0.3.0 to 0.3.1, and CI testing workflows are reorganized.
- Introduced
VcsInfoCurationDatamodel for package curations with optional VCS fields - Refactored
VcsTypevalidation to use a simpler string-based model with pre-validation - Added test coverage for package curation examples and consolidated YAML loading utilities
- Added
richlibrary as a dev dependency - Reorganized testing workflows into separate build and testing pipelines
Reviewed Changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| uv.lock | Updated package version to 0.3.1, added rich, markdown-it-py, and mdurl dependencies |
| pyproject.toml | Bumped version to 0.3.1, added rich dev dependency, removed hatch config, updated pytest config |
| src/ort/models/vcstype.py | Simplified VcsType model from list-based aliases to string-based name with pre-validation |
| src/ort/models/vcsinfo_curation_data.py | New model for VCS info in curations with all optional fields |
| src/ort/models/package_curation_data.py | Changed vcs field from VcsInfo to VcsInfoCurationData |
| tests/utils/load_yaml_config.py | New utility function for loading YAML test configuration files |
| tests/test_package_curation.py | New tests validating package curation examples from ORT documentation |
| tests/test_ort_repository_configuration.py | Refactored to use shared load_yaml_config utility |
| tests/data/example_simple_curation.yml | New test data file with simple curation example |
| tests/data/example_curations.yml | New test data file with comprehensive curation examples |
| .github/workflows/testing.yml | New dedicated pytest workflow for running tests |
| .github/workflows/build.yml | Removed test execution (moved to separate testing workflow) |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| curations: | ||
| comment: 'Repository moved to https://gitlab.ow2.org.' | ||
| vcs: | ||
| type: 'Giot' |
Copilot
AI
Nov 7, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corrected spelling of 'Giot' to 'Git'.
| type: 'Giot' | |
| type: 'Git' |
| DATA_CONFIG_DIR = Path(__file__).parent.parent / "data" | ||
|
|
||
|
|
||
| def load_yaml_config(filename: str, data_dir: Path = DATA_CONFIG_DIR) -> Any: |
Copilot
AI
Nov 7, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mixing implicit and explicit returns may indicate an error, as implicit returns always return None.
No description provided.