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-100192: add moreasyncio subprocess tests#100194

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
kumaraditya303 merged 5 commits intopython:mainfromkumaraditya303:subprocess-tests
Dec 28, 2022

Conversation

kumaraditya303
Copy link
Contributor

@kumaraditya303kumaraditya303 commentedDec 12, 2022
edited by bedevere-bot
Loading

Comment on lines 699 to 701
task = asyncio.create_task(proc.wait())
await asyncio.sleep(0)
self.assertEqual(task.result(), proc.returncode)
Copy link
Member

Choose a reason for hiding this comment

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

Why notawait task instead ofsleep(0) andtask.result()? At this point we already know the process has exited, since the returncode is 0 on the previous line.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

At this point we already know the process has exited, since the returncode is 0 on the previous line.

Yes, awaiting can take more than one cycle but we are checking that wait will be done immediately so usingsleep(0) trick.

@kumaraditya303kumaraditya303 linked an issueDec 28, 2022 that may beclosed by this pull request
@kumaraditya303kumaraditya303 merged commite97afef intopython:mainDec 28, 2022
@kumaraditya303kumaraditya303 deleted the subprocess-tests branchDecember 28, 2022 04:12
@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 RHEL7 3.x has failed when building commite97afef.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/15/builds/3671) and take a look at the build logs.
  4. Check if the failure is related to this commit (e97afef) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/15/builds/3671

Failed tests:

  • test_asyncio

Failed subtests:

  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_exec

Summary of the results of the build (if available):

== Tests result: FAILURE then FAILURE ==

409 tests OK.

10 slowest tests:

  • test_concurrent_futures: 2 min 30 sec
  • test_multiprocessing_spawn: 2 min 8 sec
  • test_capi: 1 min 38 sec
  • test_multiprocessing_forkserver: 1 min 26 sec
  • test_multiprocessing_fork: 1 min 8 sec
  • test_asyncio: 1 min 8 sec
  • test_signal: 56.3 sec
  • test_tokenize: 50.3 sec
  • test_socket: 39.4 sec
  • test_io: 38.2 sec

1 test failed:
test_asyncio

23 tests skipped:
test_check_c_globals test_devpoll test_gdb test_idle test_ioctl
test_kqueue test_launcher test_msilib test_peg_generator
test_smtpnet test_ssl test_startfile test_tcl test_tix
test_tkinter test_ttk test_ttk_textonly test_turtle
test_winconsoleio test_winreg test_winsound test_wmi
test_zipfile64

1 re-run test:
test_asyncio

Total duration: 3 min 29 sec

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/test/test_asyncio/test_subprocess.py", line707, intest_create_subprocess_env_shellself.loop.run_until_complete(self.check_stdout_output(main(),b'bar'))  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'bar'Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/test/test_asyncio/test_subprocess.py", line719, intest_create_subprocess_env_execself.loop.run_until_complete(self.check_stdout_output(main(),b'baz'))  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/home/buildbot/buildarea/3.x.cstratak-RHEL7-x86_64/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'baz'

@kumaraditya303
Copy link
ContributorAuthor

kumaraditya303 commentedDec 28, 2022
edited
Loading

Hi! The buildbot AMD64 RHEL7 3.x has failed when building commite97afef.

Created#100569 to fix this, it failed because the buildbot uses env vars to pass shared library location.

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 RHEL8 FIPS Only Blake2 Builtin Hash 3.x has failed when building commite97afef.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/469/builds/3963) and take a look at the build logs.
  4. Check if the failure is related to this commit (e97afef) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/469/builds/3963

Failed tests:

  • test_asyncio

Failed subtests:

  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_exec

Summary of the results of the build (if available):

== Tests result: FAILURE then FAILURE ==

416 tests OK.

10 slowest tests:

  • test_gdb: 6 min 55 sec
  • test_concurrent_futures: 2 min 43 sec
  • test_capi: 2 min 1 sec
  • test_asyncio: 1 min 53 sec
  • test_multiprocessing_spawn: 1 min 50 sec
  • test_multiprocessing_forkserver: 1 min 15 sec
  • test_tokenize: 1 min 7 sec
  • test_multiprocessing_fork: 59.2 sec
  • test_signal: 49.4 sec
  • test_socket: 45.6 sec

1 test failed:
test_asyncio

16 tests skipped:
test_check_c_globals test_devpoll test_ioctl test_kqueue
test_launcher test_msilib test_peg_generator test_startfile
test_tix test_tkinter test_ttk test_winconsoleio test_winreg
test_winsound test_wmi test_zipfile64

1 re-run test:
test_asyncio

Total duration: 9 min 54 sec

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/test/test_asyncio/test_subprocess.py", line719, intest_create_subprocess_env_execself.loop.run_until_complete(self.check_stdout_output(main(),b'baz'))  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'baz'Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/test/test_asyncio/test_subprocess.py", line707, intest_create_subprocess_env_shellself.loop.run_until_complete(self.check_stdout_output(main(),b'bar'))  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/home/buildbot/buildarea/3.x.cstratak-RHEL8-fips-x86_64.no-builtin-hashes-except-blake2/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'bar'

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 Ubuntu Shared 3.x has failed when building commite97afef.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/506/builds/3853) and take a look at the build logs.
  4. Check if the failure is related to this commit (e97afef) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/506/builds/3853

Failed tests:

  • test_asyncio

Failed subtests:

  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_exec
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_shell - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_create_subprocess_env_shell
  • test_create_subprocess_env_exec - test.test_asyncio.test_subprocess.SubprocessFastWatcherTests.test_create_subprocess_env_exec

Summary of the results of the build (if available):

== Tests result: FAILURE then FAILURE ==

412 tests OK.

10 slowest tests:

  • test_tools: 8 min 37 sec
  • test_multiprocessing_spawn: 4 min 32 sec
  • test_concurrent_futures: 3 min 19 sec
  • test_capi: 3 min 8 sec
  • test_gdb: 2 min 46 sec
  • test_asyncio: 2 min 28 sec
  • test_tokenize: 1 min 49 sec
  • test_multiprocessing_forkserver: 1 min 43 sec
  • test_lib2to3: 1 min 38 sec
  • test_multiprocessing_fork: 1 min 26 sec

1 test failed:
test_asyncio

20 tests skipped:
test_check_c_globals test_devpoll test_idle test_ioctl test_kqueue
test_launcher test_msilib test_peg_generator test_startfile
test_tcl test_tix test_tkinter test_ttk test_ttk_textonly
test_turtle test_winconsoleio test_winreg test_winsound test_wmi
test_zipfile64

1 re-run test:
test_asyncio

Total duration: 34 min 2 sec

Click to see traceback logs
Traceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_asyncio/test_subprocess.py", line707, intest_create_subprocess_env_shellself.loop.run_until_complete(self.check_stdout_output(main(),b'bar'))  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'bar'Traceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_asyncio/test_subprocess.py", line719, intest_create_subprocess_env_execself.loop.run_until_complete(self.check_stdout_output(main(),b'baz'))  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_asyncio/test_subprocess.py", line692, incheck_stdout_outputself.assertEqual(stdout, output)AssertionError:b'' != b'baz'

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@gvanrossumgvanrossumgvanrossum approved these changes

@1st11st1Awaiting requested review from 1st11st1 is a code owner

@asvetlovasvetlovAwaiting requested review from asvetlovasvetlov is a code owner

Assignees
No one assigned
Labels
skip newstestsTests in the Lib/test dirtopic-asyncio
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Add more tests forasyncio subprocess
3 participants
@kumaraditya303@bedevere-bot@gvanrossum

[8]ページ先頭

©2009-2025 Movatter.jp