Skip to content

Conversation

@heliocastro
Copy link
Owner

No description provided.

- 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>
@heliocastro heliocastro self-assigned this Nov 7, 2025
Copilot AI review requested due to automatic review settings November 7, 2025 13:36
Copy link

Copilot AI left a 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 VcsInfoCurationData model for package curations with optional VCS fields
  • Refactored VcsType validation to use a simpler string-based model with pre-validation
  • Added test coverage for package curation examples and consolidated YAML loading utilities
  • Added rich library 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'
Copy link

Copilot AI Nov 7, 2025

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'.

Suggested change
type: 'Giot'
type: 'Git'

Copilot uses AI. Check for mistakes.
DATA_CONFIG_DIR = Path(__file__).parent.parent / "data"


def load_yaml_config(filename: str, data_dir: Path = DATA_CONFIG_DIR) -> Any:
Copy link

Copilot AI Nov 7, 2025

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.

Copilot uses AI. Check for mistakes.
@heliocastro heliocastro merged commit ca389f1 into heliocastro:main Nov 7, 2025
19 checks passed
@heliocastro heliocastro deleted the tests/curations branch November 7, 2025 13:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant