Skip to content

Random failure of the test_kbd_interrupt_in_wait_with_limited_concurrency unit test #1369

@vkarak

Description

@vkarak

The following failures happens randomly from time to time. I don't know if it actually corresponds to a bug in the code or is it a problem of this particular unit test.

_____________ test_kbd_interrupt_in_wait_with_limited_concurrency ______________
async_runner = (reframe.frontend.executors.Runner(_max_retries=0, _policy=reframe.frontend.executors.policies.AsynchronousExecutionPo...cs.TestStats(...)@0x7fdbd38f2908)@0x7fdbd38f2c18, <unittests.test_policies._TaskEventMonitor object at 0x7fdbd38f2208>)
make_cases = <function make_cases.<locals>._make_cases at 0x7fdbd34edc80>
make_async_exec_ctx = <function make_async_exec_ctx.<locals>._make_async_exec_ctx at 0x7fdbd34f46a8>
    def test_kbd_interrupt_in_wait_with_limited_concurrency(
            async_runner, make_cases, make_async_exec_ctx):
        # The general idea for this test is to allow enough time for all the
        # four checks to be submitted and at the same time we need the
        # KeyboardInterruptCheck to finish first (the corresponding wait should
        # trigger the failure), so as to make the framework kill the remaining
        # three.
        ctx = make_async_exec_ctx(2)
        next(ctx)
    
        runner, _ = async_runner
        with pytest.raises(KeyboardInterrupt):
            runner.runall(make_cases([
                KeyboardInterruptCheck(), SleepCheck(10),
>               SleepCheck(10), SleepCheck(10)
            ]))
E           Failed: DID NOT RAISE <class 'KeyboardInterrupt'>
unittests/test_policies.py:525: Failed
=========================== short test summary info ============================
FAILED unittests/test_policies.py::test_kbd_interrupt_in_wait_with_limited_concurrency
================== 1 failed, 619 passed, 88 skipped in 38.85s ==================

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions