Skip to content
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

Fix detached-metadata issues #1143

Merged
merged 1 commit into from
Sep 26, 2024
Merged

Fix detached-metadata issues #1143

merged 1 commit into from
Sep 26, 2024

Conversation

anderseknert
Copy link
Member

Build a more robust system for determining this regardless of scope. Lean in on the OPA parser failing anyway when scope is invalid.

Fixes #1138

@@ -29,3 +28,16 @@ _annotation_at_row(row) := annotation if {

util.to_location_object(annotation.location).row == row
}

_allow_detached(last_row, i, blocks, lines) if {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand this now, but a comment might be helpful in a few months time! 😅

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure! :) I'll add one 👍

Build a more robust system for determining this regardless of scope.
Lean in on the OPA parser failing anyway when scope is invalid.

Fixes #1138

Signed-off-by: Anders Eknert <anders@styra.com>
@anderseknert anderseknert merged commit efd4420 into main Sep 26, 2024
4 checks passed
@anderseknert anderseknert deleted the detached-package-scope branch September 26, 2024 13:03
srenatus pushed a commit to srenatus/regal that referenced this pull request Oct 1, 2024
Build a more robust system for determining this regardless of scope.
Lean in on the OPA parser failing anyway when scope is invalid.

Fixes StyraInc#1138

Signed-off-by: Anders Eknert <anders@styra.com>
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.

False positive in detached-metadata when both package and subpackages scope in use
2 participants