8000 gh-121723: Relax constraints on queue objects for `logging.handlers.QueueHandler`. by picnixz · Pull Request #122154 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-121723: Relax constraints on queue objects for logging.handlers.QueueHandler. #122154

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

Merged
merged 15 commits into from
Aug 2, 2024
Prev Previous commit
Next Next commit
fix start methods selection on MS-Windows
  • Loading branch information
picnixz committed Jul 24, 2024
commit b770787e1f634b4fff39f77954e3708aa2c7e7df
10 changes: 7 additions & 3 deletions Lib/test/test_logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -4002,9 +4002,13 @@ def test_config_queue_handler_invalid_config_does_not_create_multiprocessing_man
@unittest.skipUnless(support.Py_DEBUG, "requires a debug build")
def test_config_queue_handler_multiprocessing_context(self):
# regression test for gh-121723
for startmethod in ['fork', 'spawn', 'forkserver']:
with self.subTest(startmethod=startmethod):
ctx = multiprocessing.get_context(startmethod)
if support.MS_WINDOWS:
start_methods = ['spawn']
else:
start_methods = ['spawn', 'fork', 'forkserver']
for start_method in start_methods:
with self.subTest(start_method=start_method):
ctx = multiprocessing.get_context(start_method)
with ctx.Manager() as manager:
q = manager.Queue()
records = []
Expand Down
Loading
0