adjust complies link validation#268
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adjusts the metamodel's complies link validation based on process community requirements. The key change is replacing regex patterns with need type references for complies link validation, making it more restrictive and type-safe.
- Modified metamodel.yaml to use specific need types (std_req, std_wp) instead of regex patterns for complies links
- Updated test infrastructure to provide better error messages with clearer formatting
- Added new type alias and improved link validation logic to handle mixed regex/type references
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/extensions/score_metamodel/metamodel.yaml | Updated complies link validation from regex patterns to specific need types |
| src/extensions/score_metamodel/metamodel_types.py | Added AllowedLinksType alias for mixed regex/type reference support |
| src/extensions/score_metamodel/checks/check_options.py | Refactored validation logic to handle new link type structure |
| src/extensions/score_metamodel/log.py | Added warning_for_link method for better link validation error messages |
| src/extensions/score_metamodel/init.py | Updated link resolution to handle mixed regex and type references |
| src/extensions/score_metamodel/tests/test_rules_file_based.py | Improved test error messages with better formatting |
| src/extensions/score_metamodel/tests/rst/options/*.rst | Added new test files and updated existing ones for new validation rules |
| docs/internals/extensions/rst_filebased_testing.md | Updated documentation to reflect terminology change from "option" to "attribute" |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
License Check Results🚀 The license check job ran with the Bazel command: bazel run //src:license-checkStatus: Click to expand output |
|
@AlexanderLanin , >>Note that this change INCREASES the warnings in process_description. I guess something went wrong? |
| .. | ||
| Ensuring that empty content is detected correctly | ||
| .. #EXPECT: stkh_req__test_no_content: is missing required option: `content` | ||
| .. #EXPECT: stkh_req__test_no_content: is missing required attribute: `content` |
There was a problem hiding this comment.
normally we call the text below the need description, but content should also be understandable
There was a problem hiding this comment.
content is a technical term here dictated by sphinx-needs, but we can look into renaming it...
Here I renamed option to attribute, since that is way clearer for me personally.
|
CODE walkthough today 13:00 CEST in case anyone is interested. Only code - not the process! |
|
The created documentation from the pull request is available at: docu-html |
There was a problem hiding this comment.
In metamodel.yaml:
- the "logic_arc_int" fulfils "comp_req" - but it should fulfil "feat_req", see https://eclipse-score.github.io/process_description/main/process_areas/architecture_design/guidance/architecture_process_reqs.html#gd_req__arch_traceability
- the "comp_arc_sta" uses/implements "real_arc_int, real_arc_int_op" - but it should link to "logic_arc_int" only, as shown in https://eclipse-score.github.io/process_description/main/process_areas/architecture_design/guidance/architecture_process_reqs.html#gd_req__arch_build_blocks_corr
- this will resolve some warnings
masc2023
left a comment
There was a problem hiding this comment.
See comment to metamodel
There was a problem hiding this comment.
We have discussed the usage of satisfies from process requirements to workflows again, see updated image hier https://github.com/eclipse-score/process_description/pull/184/files#diff-7c454b5e2e89ac0ce4216be34bbb05b5c7b5e1b63835a78aba14e72a44b74590
Also the template for process needs is updated accordingly, we can discuss that again on the next process meeting, 07.10, but if agreed, it would have impact on the metamodel again for additional check
aschemmel-tech
left a comment
There was a problem hiding this comment.
revert to comment to unblock
aschemmel-tech
left a comment
There was a problem hiding this comment.
ok to merge, my comments will be covered in doc-as-code PR #263
📌 Description
Adjust metamodel as requested by process community
🚨 Impact Analysis
✅ Checklist
I'll address requriements adjustment in a separate PR. This one is horrible enough.
@masc2023 please review changes in
metamodel.ymland in the examples inrstfiles. Note that this change INCREASES the warnings in process_description. I guess something went wrong?