jupyterhub / wrapspawner

Mechanism for runtime configuration of spawners for JupyterHub
BSD 3-Clause "New" or "Revised" License
60 stars 57 forks source link

No child spawner exists yet - cannot get progress yet #53

Open rcthomas opened 2 years ago

rcthomas commented 2 years ago

I think this exception is harmless, but it shows up a lot in my log and I'm wondering if there might be an alternate approach to what this exception does:

    Traceback (most recent call last):
      File "/usr/local/lib/python3.8/dist-packages/tornado/web.py", line 1704, in _execute
        result = await result
      File "/usr/local/lib/python3.8/dist-packages/jupyterhub/apihandlers/users.py", line 737, in get
        async for event in events:
      File "/usr/local/lib/python3.8/dist-packages/jupyterhub/utils.py", line 570, in iterate_until
        yield item_future.result()
      File "/usr/local/lib/python3.8/dist-packages/jupyterhub/spawner.py", line 1146, in _generate_progress
        async with aclosing(self.progress()) as progress:
      File "/usr/local/lib/python3.8/dist-packages/wrapspawner/wrapspawner.py", line 152, in progress
        raise RuntimeError("No child spawner yet exists - can not get progress yet")
    RuntimeError: No child spawner yet exists - can not get progress yet

This exception was added in #21 to prevent hitting a recursion limit. Is throwing an exception the only way out of that?