jupyterhub / jupyterhub

Multi-user server for Jupyter notebooks

Home Page:https://jupyterhub.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

All CI pytest runs are failing

manics opened this issue · comments

Bug description

pytest runs are failing on GitHub CI, looks like it started between 1-4 December:
image

E.g. https://github.com/jupyterhub/jupyterhub/actions/runs/7151863739/job/19476589389

jupyterhub/tests/test_api.py::test_auth_api ERROR                        [  0%]
jupyterhub/tests/test_api.py::test_post_content_type[text/plain-403] ERROR [  0%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_auth_api ________________________

request = <SubRequest 'io_loop' for <Coroutine test_auth_api>>
kwargs = {'event_loop': <_UnixSelectorEventLoop running=False closed=False debug=False>}
setup = <function _wrap_async_fixture.<locals>._async_fixture_wrapper.<locals>.setup at 0x7fd5ec4cfbe0>

    @functools.wraps(fixture)
    def _async_fixture_wrapper(request: SubRequest, **kwargs: Any):
        func = _perhaps_rebind_fixture_func(
            fixture, request.instance, fixturedef.unittest
        )
        event_loop = kwargs.pop(event_loop_fixture_id)
    
        async def setup():
            res = await func(
                **_add_kwargs(func, kwargs, event_loop_fixture_id, event_loop, request)
            )
            return res
    
>       return event_loop.run_until_complete(setup())

/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pytest_asyncio/plugin.py:361: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/asyncio/base_events.py:649: in run_until_complete
    return future.result()
/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pytest_asyncio/plugin.py:356: in setup
    res = await func(
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

event_loop = <_UnixSelectorEventLoop running=False closed=False debug=False>
request = <SubRequest 'io_loop' for <Coroutine test_auth_api>>

    @fixture(scope='module')
    async def io_loop(event_loop, request):
        """Mostly obsolete fixture for tornado event loop
    
        Main purpose is to register cleanup (close) after we're done with the loop.
        The main reason to depend on this fixture is to ensure your cleanup
        happens before the io_loop is closed.
        """
        io_loop = AsyncIOMainLoop()
>       assert asyncio.get_event_loop() is event_loop
E       assert <_UnixSelectorEventLoop running=True closed=False debug=False> is <_UnixSelectorEventLoop running=False closed=False debug=False>
E        +  where <_UnixSelectorEventLoop running=True closed=False debug=False> = <built-in function get_event_loop>()
E        +    where <built-in function get_event_loop> = asyncio.get_event_loop

jupyterhub/tests/conftest.py:138: AssertionError