encode / uvicorn

An ASGI web server, for Python. 🦄
https://www.uvicorn.org/
BSD 3-Clause "New" or "Revised" License
8.57k stars 745 forks source link

Remove forced `raise_signal` calls #2314

Closed kleschenko closed 6 months ago

kleschenko commented 6 months ago

Summary

This change removes the raise_signal call which breaks default signal handling for subprocesses.

Closes https://github.com/encode/uvicorn/issues/2289 (and possibly https://github.com/encode/uvicorn/issues/2294)

Checklist

Kludex commented 6 months ago

Well... Then the goal of the previous PR is just ignored...

kleschenko commented 6 months ago

@Kludex I've just tested the snippet from the original issue https://github.com/encode/uvicorn/issues/1579 and it works as expected for me with this change

Kludex commented 6 months ago

Does this makes sense @maxfischer2781 ?

maxfischer2781 commented 6 months ago

I honestly don't know how the raise_signal is supposed to affect subprocesses in the first place; there is no clear repro for #2289 so I cannot say what is the actual issue.

2294 should definitely not be fixed by removing the raised signal. Yes, the server properly killing itself will lead to a traceback but if the traceback is undesired then only the traceback should be suppressed, not the proper killing.

maxfischer2781 commented 6 months ago

@Kludex I've created #2317 instead to fix the issues I could reproduce.