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

gh-117657: Log TSAN warnings to separate files and archive them#118747

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
colesbury merged 5 commits intopython:mainfrommpage:gh-117657-tsan-log-to-file
May 10, 2024

Conversation

mpage
Copy link
Contributor

@mpagempage commentedMay 7, 2024
edited by bedevere-appbot
Loading

This ensures we don't lose races that occur in subprocesses or interleave races from workers running in parallel.

Log files are collected and packaged into a zipfile than can be downloaded from the "Artifacts" section of the workflow run (example).

Thehandle_segv=0 change to the TSAN options is necessary to avoid logs likethis in default builds. I don't know what's causing this, but our ASAN builds alsoset the option.

The additional thread leak suppression was also required.

This ensures we don't lose races that occur in subprocesses or interleaveraces from workers running in parallel.
@mpagempage requested a review fromhugovkMay 8, 2024 16:46
@colesbury
Copy link
Contributor

Should wecat the TSAN logs so that they are visible directly from the GitHub actions page?

@hugovk
Copy link
Member

The example athttps://github.com/mpage/cpython/actions/runs/8993391354 is a 170 KB zip containing 33 files, so it might not be practical to cat them all.

@mpage
Copy link
ContributorAuthor

The example athttps://github.com/mpage/cpython/actions/runs/8993391354 is a 170 KB zip containing 33 files, so it might not be practical to cat them all.

I don't feel super strongly either way.

On the one hand, that doesn't seem that bad? It's also with ~all the suppressions removed, so it's roughly the worst case scenario. In the common case (i.e. a new race appears), I would imagine it would be a lot less output.

On the other hand, downloading a zip file to look at the reported races doesn't feel particularly onerous.

hugovk reacted with thumbs up emoji

Copy link
Contributor

@colesburycolesbury left a comment

Choose a reason for hiding this comment

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

LGTM

I might just be lazy, but having the logs available in the GitHub UI seems nice to have. We currently print the logs and I wouldn't expect them to be significantly longer with this change. If we are concerned about super long logs, we could also justhead -n 1000 or some other reasonably large length.

mpage reacted with thumbs up emoji
@mpage
Copy link
ContributorAuthor

@hugovk@colesbury - The most recent version of this should be a happy medium and includes a few changes:

  1. We always show the first 1000 lines of each log.
  2. The "Archive TSAN logs" step no longer shows a warning if no files are found.

You can look at thisworkflow run as an example of what things look like on both success and failure. I removed suppressions from the free-threaded build so the TSAN job fails.

hugovk reacted with thumbs up emoji

@colesburycolesbury added the needs backport to 3.13bugs and security fixes labelMay 10, 2024
@colesbury
Copy link
Contributor

Great!

We probably want to backport this to 3.13, right?

@mpage
Copy link
ContributorAuthor

We probably want to backport this to 3.13, right?

Yeah, I think that's worth doing.

@colesburycolesbury merged commitb88889e intopython:mainMay 10, 2024
@miss-islington-app
Copy link

Thanks@mpage for the PR, and@colesbury for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestMay 10, 2024
…pythonGH-118747)This ensures we don't lose races that occur in subprocesses orinterleave races from workers running in parallel.Log files are collected and packaged into a zipfile that can bedownloaded from the "Artifacts" section of the workflow run.(cherry picked from commitb88889e)Co-authored-by: mpage <mpage@meta.com>
@bedevere-app
Copy link

GH-118931 is a backport of this pull request to the3.13 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.13bugs and security fixes labelMay 10, 2024
colesbury pushed a commit that referenced this pull requestMay 10, 2024
GH-118747) (#118931)This ensures we don't lose races that occur in subprocesses orinterleave races from workers running in parallel.Log files are collected and packaged into a zipfile that can bedownloaded from the "Artifacts" section of the workflow run.(cherry picked from commitb88889e)Co-authored-by: mpage <mpage@meta.com>
estyxx pushed a commit to estyxx/cpython that referenced this pull requestJul 17, 2024
…python#118747)This ensures we don't lose races that occur in subprocesses orinterleave races from workers running in parallel.Log files are collected and packaged into a zipfile that can bedownloaded from the "Artifacts" section of the workflow run.
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@colesburycolesburycolesbury approved these changes

@hugovkhugovkhugovk approved these changes

@swtaarrsswtaarrsAwaiting requested review from swtaarrs

@corona10corona10Awaiting requested review from corona10

@ezio-melottiezio-melottiAwaiting requested review from ezio-melottiezio-melotti is a code owner

Assignees
No one assigned
Labels
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@mpage@colesbury@hugovk

[8]ページ先頭

©2009-2025 Movatter.jp