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

Prepare docs for OPA 1.0 compatibility #1328

Merged
merged 1 commit into from
Jan 13, 2025
Merged

Prepare docs for OPA 1.0 compatibility #1328

merged 1 commit into from
Jan 13, 2025

Conversation

anderseknert
Copy link
Member

  • Remove import rego.v1 from examples
  • Add new page covering Regal and OPA 1.0
  • Update logic of any rules obsolete in 1.0 to make sure they're automatically disabled when 1.0 is targeted, and continue to work when older versions are linted
  • Update a few tests to remove import rego.v1
  • Many minor fixes related to this theme

@anderseknert anderseknert force-pushed the opa1.0-docs branch 2 times, most recently from f8e036d to 0d5e9a5 Compare January 9, 2025 23:12
configuration. Note that this has lower precedence than Rego versions set by other means, and should not be considered
as anything but a convenience for testing.

## Rules disabled with OPA 1.0
Copy link
Member

Choose a reason for hiding this comment

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

Some rules are labelled Notice: Rule made obsolete by OPA 1.0, others Notice: Rule disabled with OPA 1.0 - is there a subtle difference I'm missing?

Copy link
Member Author

Choose a reason for hiding this comment

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

Theimport-shadows-import rule should have the "obsolete" header, and I'll fix that. The only other one that has "rule disabled" header is deprecated-builtin. That rule isn't really made obsolete — it's just that we currently don't have any deprecated built-ins in OPA 1.0. But that may very well change, and the rule will be enabled once that happens.

Copy link
Member

@charlieegan3 charlieegan3 left a comment

Choose a reason for hiding this comment

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

LGTM!

- Remove `import rego.v1` from examples
- Add new page covering Regal and OPA 1.0
- Update logic of any rules obsolete in 1.0 to make sure
  they're automatically disabled when 1.0 is targeted, and
  continue to work when older versions are linted
- Update a few tests to remove `import rego.v1`
- Many minor fixes related to this theme

Signed-off-by: Anders Eknert <[email protected]>
@anderseknert anderseknert merged commit 0e338c3 into opa1.0 Jan 13, 2025
5 checks passed
@anderseknert anderseknert deleted the opa1.0-docs branch January 13, 2025 11:11
anderseknert added a commit that referenced this pull request Jan 13, 2025
- Remove `import rego.v1` from examples
- Add new page covering Regal and OPA 1.0
- Update logic of any rules obsolete in 1.0 to make sure
  they're automatically disabled when 1.0 is targeted, and
  continue to work when older versions are linted
- Update a few tests to remove `import rego.v1`
- Many minor fixes related to this theme

Signed-off-by: Anders Eknert <[email protected]>
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.

2 participants