fix(gateway): hold _run_restart on _restart_task + explicit cancel-loop skip

Follow-up on the cherry-picked #13173 fix. Holds the _run_restart task in
self._restart_task (a bare asyncio.create_task keeps only a weak reference,
so a still-pending task can be GC'd mid-flight) and explicitly skips it in
the _stop_impl cancel loop alongside _stop_task. Adds AUTHOR_MAP entry for
the contributor and a regression test that fails when the task is cancellable.

Refs #12875
This commit is contained in:
teknium1 2026-06-27 03:45:07 -07:00 committed by Teknium
parent 1ce5d6d974
commit f2ca3e3d84
3 changed files with 67 additions and 14 deletions

View file

@ -153,6 +153,7 @@ AUTHOR_MAP = {
"290859878+synapsesx@users.noreply.github.com": "synapsesx",
"157689911+itsflownium@users.noreply.github.com": "itsflownium",
"dirtyren@users.noreply.github.com": "dirtyren",
"--email": "andryypaez@gmail.com",
"mucio@mucio.net": "francescomucio",
"291572938+thestral123@users.noreply.github.com": "thestral123",
"tkwong@inspiresynergy.com": "tkwong",