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

replace hashicorp/go-multierror with errors.Join #778

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Oct 2, 2024

@thaJeztah
Copy link
Member Author

Ah, right, this requires go1.20 as minimum, which perhaps by now may be fine?

@thaJeztah thaJeztah force-pushed the native_multierror branch 2 times, most recently from 87d4560 to 73b898b Compare October 2, 2024 11:35
@kolyshkin
Copy link
Contributor

@thaJeztah #776 is merged; time to rebase

@@ -144,21 +144,21 @@ func (v *Validator) CheckJSONSchema() (errs error) {

url, err := JSONSchemaURL(strings.TrimSuffix(v.spec.Version, "-dev"))
if err != nil {
errs = multierror.Append(errs, err)
errs = errors.Join(errs, err)
Copy link
Member Author

Choose a reason for hiding this comment

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

I need to check if I'm actually doing these right; I recently made a mistake with stdlib "multi-errors" because (IIRC) errors.Join is more an equivalent to errors.Wrap, and nests a new error, not making it on the same "level" as other errors when using a loop.

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