Skip to content

Fix bug where Twiggy's run loop exits after a streaming request is cut off #41

Merged
merged 2 commits into from Jan 3, 2015

2 participants

@hoelzro
hoelzro commented Apr 29, 2014

Hello,

I found a bug in Twiggy where if you're using a streaming writer and the client stops the request, the PSGI application dies in such a way that Twiggy itself shuts down. A test file and fix are included. The fix isn't the cleanest, but maybe it's a starting point you could improve upon!

-Rob

hoelzro added some commits Apr 28, 2014
@hoelzro hoelzro Add test checking for a stream being broken
Twiggy (as of version 0.1024) shuts down after servicing
a request that writes streaming contents to a PSGI writer, and
the connection is broken.
26ad32a
@hoelzro hoelzro Fix bug where Twiggy stops servicing requests 18ab18b
@hoelzro
hoelzro commented May 30, 2014

@miyagawa Have you had a chance to look at this?

@hoelzro
hoelzro commented Jan 3, 2015

@miyagawa If you have time, would you mind taking a look at this change?

@miyagawa miyagawa merged commit a590fff into miyagawa:master Jan 3, 2015
@miyagawa
Owner
miyagawa commented Jan 3, 2015

sorry that it's taken such a long time. I don't really understand the fix, but sounds trivial enough to merge.

@hoelzro
hoelzro commented Jan 3, 2015

No problem, I had forgotten about it myself. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.