-
-
Notifications
You must be signed in to change notification settings - Fork 33.3k
gh-140729: Add __mp_main__ as a duplicate for __main__ for pickle to work #140735
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
|
test failed is flaky |
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
| with os_helper.temp_dir() as temp_dir: | ||
| script = script_helper.make_script( | ||
| temp_dir, 'test_process_pool_executor_pickle', test_script | ||
| ) | ||
| with SuppressCrashReport(): | ||
| with script_helper.spawn_python(script, stderr=subprocess.PIPE) as proc: | ||
| proc.wait() | ||
| stdout = proc.stdout.read() | ||
| stderr = proc.stderr.read() | ||
|
|
||
| if b"PermissionError" in stderr: | ||
| self.skipTest("Insufficient permissions for remote profiling") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This code doesn't seem to use the profiler in any way. I am missing something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry when change to spawn_python forget it, will bring it back
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
| @@ -0,0 +1,2 @@ | |||
| Fix: Add __mp_main__ as a duplicate for __main__ for pickle to work in | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to refer the profiler otherwise is not possible to undestand what this is fixing. Also this should say WHAT is fixed not HOW
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
addressed
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
|
Do not know why windows free thread failed root cause, will go to find a windows test it these days. |
It seems there is some kind of race condition because the other windows test failed with a timeout |
| with SuppressCrashReport(): | ||
| with script_helper.spawn_python( | ||
| "-m", "profiling.sampling.sample", | ||
| "-d", "1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You probaby need to sample for more time in case the machine is slow
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
got it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check other code in the test use 5 now
| stderr=subprocess.PIPE, | ||
| text=True | ||
| ) as proc: | ||
| proc.wait(timeout=10) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use SHORT_TIMEOUT from support (you are already importing it)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
passed now, thank you very much, learned that |
|
🤖 New build scheduled with the buildbot fleet by @pablogsal for commit 59c1c1d 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F140735%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again. |
|
Regarding our recent discussions, could you add the fix about the |
sorry for the comment, I think we should not fix it here
|
the fix is like gaogaotiantian/viztracer#423 viztracer fix