refactor(waitgroup): replace Add/Done goroutines with WaitGroup.Go#37764
Merged
Conversation
Agent-Logs-Url: https://github.com/go-gitea/gitea/sessions/198f461d-8dbf-44d3-9a29-13da5e19ce08 Co-authored-by: wxiaoguang <2114189+wxiaoguang@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
wxiaoguang
May 18, 2026 13:09
View session
wxiaoguang
approved these changes
May 18, 2026
lunny
approved these changes
May 18, 2026
silverwind
added a commit
to silverwind/gitea
that referenced
this pull request
May 19, 2026
* origin/main: (104 commits) fix(deps): update module github.com/go-git/go-git/v5 to v5.19.1 [security] (go-gitea#37786) fix(pull): handle empty pull request files view to allow reviews (go-gitea#37783) fix(markup): make RenderString never fail (go-gitea#37779) fix(markup): wrap indented code blocks for the code-copy button (go-gitea#37748) fix(permissions): Fix reading permission (go-gitea#37769) fix: add natural sort to sortTreeViewNodes (go-gitea#37772) fix: package creation unique conflict (go-gitea#37774) fix(deps): update npm dependencies (go-gitea#37768) fix(deps): update module gitlab.com/gitlab-org/api/client-go/v2 to v2.26.0 (go-gitea#37771) ci: split giteabot workflow (go-gitea#37770) [skip ci] Updated translations via Crowdin fix: Unify public-only token filtering in API queries and repo access checks (go-gitea#37118) fix(deps): update module google.golang.org/grpc to v1.81.1 (go-gitea#37762) chore: make DefaultTitleSource default to auto to match GitHub (go-gitea#37767) ci: fix cache-related issues (go-gitea#37761) chore: fix tests (go-gitea#37760) refactor(waitgroup): replace Add/Done goroutines with WaitGroup.Go (go-gitea#37764) fix(deps): update go dependencies (go-gitea#37752) chore(deps): update action dependencies (go-gitea#37751) fix(deps): update module github.com/google/go-github/v85 to v86 (go-gitea#37754) ... # Conflicts: # .github/workflows/pull-db-tests.yml # modules/storage/s3_test.go
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This refactors legacy
sync.WaitGroupgoroutine launch sites to the modernWaitGroup.GoAPI. It removes manual waitgroup bookkeeping in eligible paths without changing concurrency semantics.Scope
sync.WaitGroupgoroutine launches inmodules/sshand the affected Go test files undermodules/templatesandtests/integration.What changed
wg.Add(1)+go func() { ...; wg.Done() }()patterns withwg.Go(func() { ... }).Result
Example