On Fri, Aug 15, 2014 at 2:15 AM, Glyph wrote:
> On Aug 14, 2014, at 3:54 PM, Piper Masden wrote:
>
> The core of the code looks like this:
>
> resource = WSGIResource(reactor, reactor.getThreadPool(),
> WSGIHandler())
> endpoint = 'tcp:port=8000'
Hi Twistedeers!
I have a twisted plugin that I created to replace the Django dev server
for our devs. It sets up a separate twisted service for serving media, so
we don't need any urls.py tomfoolery in dev. It also sets up an
experimental REST api server which we hope to make javascript requests
I have some Klein code that uses deferToThread for I/O. It looks something
like this:
@app.route('/', methods=['GET']
def index(request, *args, **kwargs):
d = deferToThread(some_blocking_db_select_function)
def serialize(db_object):
return json.dumps({
'id': db_object,
On Tue, Aug 6, 2013 at 2:33 PM, Benjamin BERTRAND wrote:
>
> I guess it's possible to use a synthetic transport, but that wouldn't help
> much without a "fake" redis server.
> That would indeed be nice to have for testing.
>
> I actually just found a dummy txredis client that implements everythin