Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

test: stop running Test_sshConfigProxyCommandEscape in parallel#20009

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
spikecurtis merged 1 commit intomainfromspike/internal-1035-no-parallel
Sep 29, 2025

Conversation

spikecurtis
Copy link
Contributor

@spikecurtisspikecurtis commentedSep 29, 2025
edited
Loading

Fixescoder/internal#1035

Or, at least, closes a remaining race that seems pretty likely.

The tests in question write a file, close the file, then execute the file. Sometimes Linux errors saying "text file busy" which means the file is still open for writing.

What I think is going on is:

  1. Test_sshConfigProxyCommandEscape goroutine opens the file and begins writing.
  2. Some other, unrelated test execs a command, which causes afork() syscall. The child process now has a copy of the file descriptor to our open file.
  3. Test_sshConfigProxyCommandEscape goroutine executes the file and gets "text file busy".
  4. The child process calls theexec syscall, which closes the file (due toCLOEXEC being set).

The race is very tight because 3 has to happen before 4 (and, 3 involves it's own fork/exec), but it's not impossible on a busy system.

c.f.#14233 which was an earlier attempt to fix this. It only prevented the subtests from running in parallel. When the subtests were all running in parallel, the flake was fairly likely because you've got all this fork() activity happening at the same time. But, since the main test was in parallel there is still a chance a totally different test isfork'ing at in inopportune time.

@spikecurtisGraphite App
Copy link
ContributorAuthor

This stack of pull requests is managed byGraphite. Learn more aboutstacking.

@spikecurtisspikecurtis marked this pull request as ready for reviewSeptember 29, 2025 12:26
@spikecurtisGraphite App
Copy link
ContributorAuthor

a more thorough discussion:golang/go#22315

Copy link
Member

@ethanndicksonethanndickson left a comment
edited
Loading

Choose a reason for hiding this comment

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

a more thorough discussion:golang/go#22315

nice find! I remember this flake being quite perplexing the first time around, so that's a satisfying conclusion

@spikecurtisspikecurtis merged commit988ee39 intomainSep 29, 2025
38 checks passed
@spikecurtisspikecurtis deleted the spike/internal-1035-no-parallel branchSeptember 29, 2025 13:01
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsSep 29, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@ethanndicksonethanndicksonethanndickson approved these changes

Assignees

@spikecurtisspikecurtis

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

flake: Test_sshConfigProxyCommandEscape/windows_path
2 participants
@spikecurtis@ethanndickson

[8]ページ先頭

©2009-2025 Movatter.jp