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

Add a global validate function #152

Merged
merged 3 commits into from
Oct 2, 2024
Merged

Add a global validate function #152

merged 3 commits into from
Oct 2, 2024

Conversation

bufdev
Copy link
Member

@bufdev bufdev commented Oct 2, 2024

Having used this library for a while, I think it's finally time to add this function. It's what 99.99% of users want to do, and having to pass around a protovalidate.Validator really messes with a ton of functions downstream. There's no actual state that we care about being shared, other than a cache, and I think this is an exception to our no-global rule.

If there's major downsides, let's hear them, but I think this is an extremely user-favorable move.

@bufdev bufdev requested a review from rodaine October 2, 2024 18:18
Copy link

github-actions bot commented Oct 2, 2024

The latest Buf updates on your PR. Results from workflow Buf / validate-protos (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedOct 2, 2024, 7:03 PM

@rodaine rodaine merged commit 1ca4047 into main Oct 2, 2024
8 checks passed
@rodaine rodaine deleted the add-global-validate branch October 2, 2024 19:23
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.

3 participants