Skip to content

fix(core): Let sanic manage the qworker process#295

Merged
ketiltrout merged 1 commit into
chime-upgradefrom
sanic_manages_qworker
Jul 15, 2026
Merged

fix(core): Let sanic manage the qworker process#295
ketiltrout merged 1 commit into
chime-upgradefrom
sanic_manages_qworker

Conversation

@ketiltrout

@ketiltrout ketiltrout commented Jul 13, 2026

Copy link
Copy Markdown
Member

This seems like the only robust way to have additional processes running in Sanic.

I haven't found a good way to write a unit test to check the workings here because of the way subprocess creation is working, but manually testing (by inserting a crash directly into the qworker) seems to indicate that a crashing qworker will now crash all of cocod, which will at least save us from the half-dead cocod situation (e.g. #249).

Closes #89
Closes #290

@ketiltrout ketiltrout linked an issue Jul 13, 2026 that may be closed by this pull request
This seems like the only robust way to have additional processes running
in Sanic.

I haven't found a good way to write a unit test to check the workings
here because of the way subprocess creation is working, but manually
testing (by inserting a crash directly into the qworker) seems to
indicate that a crashing qworker will now crash all of cocod, which will
at least save us from the half-dead cocod situation (e.g. #249).

Closes #290
@ketiltrout ketiltrout force-pushed the sanic_manages_qworker branch from 57c1650 to 3a30a04 Compare July 13, 2026 23:16
@ketiltrout ketiltrout mentioned this pull request Jul 13, 2026
50 tasks
@ketiltrout ketiltrout linked an issue Jul 13, 2026 that may be closed by this pull request
Comment thread coco/worker.py
@ketiltrout ketiltrout merged commit 608473a into chime-upgrade Jul 15, 2026
5 checks passed
@ketiltrout ketiltrout deleted the sanic_manages_qworker branch July 15, 2026 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

qworker crash not properly handled Coordinate coco shutdown

2 participants