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

Checker error template overrides #2

Merged
merged 3 commits into from
Jul 30, 2024
Merged

Conversation

perryqh
Copy link
Contributor

@perryqh perryqh commented Jul 30, 2024

Why is this change being made?

Allowing for checker violation error message overrides so that consumers can provide better contextual error messages.

What is this change doing?

Allows for new packwerk.yml checker_overrides.

Example

packwerk.yml

checker_overrides:
  privacy_error_template: "{{reference_location}}Privacy violation: `{{constant_name}}` is private to `{{defining_pack_name}}`, but referenced from `{{referencing_pack_name}}`. See https://go/pks-privacy"
  dependency_error_template: "{{reference_location}}Dependency violation: `{{constant_name}}` belongs to `{{defining_pack_name}}`, but `{{referencing_pack_relative_yml}}` does not specify a dependency on `{{defining_pack_name}}`. See https://go/pks-dependency"

@perryqh perryqh merged commit ea87ed9 into main Jul 30, 2024
8 checks passed
@perryqh perryqh deleted the ph/check-error-template-overrides branch July 30, 2024 19:18
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