Skip to content

Conversation

@AlexanderLanin
Copy link
Member

@AlexanderLanin AlexanderLanin commented Sep 15, 2025

📌 Description

Simply how metadata is stored internally. Improves type safety although/by removing lots of explicit casts.

Due to improved analysability by pyright, some tests were no longer required.

The key here was to extend ScoreNeedType with our mandatory/optional options/links. We already had the type! We just need to use it.

🚨 Impact Analysis

  • This change does not violate any tool requirements and is covered by existing tool requirements
  • This change does not violate any design decisions
  • Otherwise I have created a ticket for new tool qualification

✅ Checklist

  • Added/updated documentation for new or changed features
  • Added/updated tests to cover the changes
  • Followed project coding standards and guidelines

@github-actions
Copy link

github-actions bot commented Sep 15, 2025

License Check Results

🚀 The license check job ran with the Bazel command:

bazel run //src:license-check

Status: ⚠️ Needs Review

Click to expand output
[License Check Output]
Extracting Bazel installation...
Starting local Bazel server (8.3.0) and connecting to it...
INFO: Invocation ID: 88fd7ad6-1d6a-4657-a70e-5b3428feec28
Computing main repo mapping: 
Computing main repo mapping: 
Computing main repo mapping: 
Loading: 
Loading: 0 packages loaded
Loading: 0 packages loaded
    currently loading: src
Analyzing: target //src:license-check (1 packages loaded, 0 targets configured)
Analyzing: target //src:license-check (1 packages loaded, 0 targets configured)

Analyzing: target //src:license-check (71 packages loaded, 9 targets configured)

Analyzing: target //src:license-check (73 packages loaded, 9 targets configured)

Analyzing: target //src:license-check (124 packages loaded, 2294 targets configured)

Analyzing: target //src:license-check (129 packages loaded, 2435 targets configured)

INFO: Analyzed target //src:license-check (137 packages loaded, 4500 targets configured).
[5 / 13] Creating runfiles tree bazel-out/k8-fastbuild/bin/src/license.check.license_check.runfiles; 0s local
INFO: Found 1 target...
Target //src:license.check.license_check up-to-date:
  bazel-bin/src/license.check.license_check
  bazel-bin/src/license.check.license_check.jar
INFO: Elapsed time: 13.110s, Critical Path: 0.44s
INFO: 13 processes: 4 disk cache hit, 9 internal.
INFO: Build completed successfully, 13 total actions
INFO: Running command line: bazel-bin/src/license.check.license_check src/formatted.txt <args omitted>
usage: org.eclipse.dash.licenses.cli.Main [-batch <int>] [-cd <url>]
       [-confidence <int>] [-ef <url>] [-excludeSources <sources>] [-help] [-lic
       <url>] [-project <shortname>] [-repo <url>] [-review] [-summary <file>]
       [-timeout <seconds>] [-token <token>]

@github-actions
Copy link

The created documentation from the pull request is available at: docu-html

@AlexanderLanin AlexanderLanin marked this pull request as ready for review September 15, 2025 21:10
Copilot AI review requested due to automatic review settings September 15, 2025 21:10
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 refactors the internal metamodel storage by extending ScoreNeedType with type-safe fields for options and links, eliminating the need for explicit casts. The refactoring improves code analyzability and type safety while maintaining the same functionality.

  • Extends ScoreNeedType with mandatory/optional options and links fields
  • Replaces explicit casts and dynamic dict access with typed field access
  • Simplifies the YAML parser by using the proper type structure
  • Updates tests to reflect the new field names and removes no longer necessary test cases

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
yaml_parser.py Refactors metamodel data loading to use typed ScoreNeedType structure
metamodel_types.py Extends ScoreNeedType with mandatory/optional options and links fields
check_options.py Updates option checking logic to use new typed field access
test_metamodel_load.py Updates test assertions to match new field names
test_check_options.py Removes obsolete test cases and updates type definitions
init.py Updates logger property names and error handling
log.py Renames properties for consistency

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@AlexanderLanin AlexanderLanin merged commit 2dc7670 into main Sep 16, 2025
11 checks passed
@AlexanderLanin AlexanderLanin deleted the meta branch September 16, 2025 08:09
@github-project-automation github-project-automation bot moved this from Draft to Done in Infrastructure Sep 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants