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

ong/sync: concat errors #429

Merged
merged 8 commits into from
Apr 22, 2024
Merged

ong/sync: concat errors #429

merged 8 commits into from
Apr 22, 2024

Conversation

komuw
Copy link
Owner

@komuw komuw commented Apr 22, 2024

  • Change sync.WaitGroup.Go so that it does not return on the first non-nil error.
    Instead, concat any errors using errors.Join and return that instead.
  • This is because, most of the times that you are using a sync.WaitGroup, you want all the functions to run irrespective of if one fails.

@komuw komuw merged commit c008423 into main Apr 22, 2024
3 of 4 checks passed
@komuw komuw deleted the sync/oneErr branch April 22, 2024 21:17
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