Re: streaming patches reloaded

2006-05-17 Thread Istvan Albert
yeah, this is really a huge wart , what Django does here - holds everything in memory - works only for the simplest cases thus makes django unsuited for a whole slew of web applications too bad that in a news environment uploading larger files is not a typical use case, that's why this fix takes

Re: Convince us to continue using setuptools

2006-08-03 Thread Istvan Albert
Never really understood why you needed this in the first place. The automatic setuptools installation has caused me some grief as it installs an obsolete version ... I forgot the exact specifics but it took me quite a while to track down that installing django was causing all kinds of strange prob

Re: Call for comment: Forms/manipulator replacement, take 1

2006-10-27 Thread Istvan Albert
>{{ form.message.errors }} >Message: {{ form.message }} A very common use case is to format/highlight the error message or input area upon error. I can already see myself extending the Form class to include something of the sorts {{ form.message.errors }} Message: {{ form.message }} whe

Re: New newforms code

2007-01-11 Thread Istvan Albert
Adrian Holovaty wrote: > Have you guys checked out the Widget class / capability in newforms? > That's the part that lets you define how a field should be output as > HTML. I'm definitely interested in hearing whether/how that doesn't > let you do what you want to do. Yes it worked out well. Bu

Re: Django with CherryPy 3.0

2007-01-22 Thread Istvan Albert
There is an easy way to turn on multi-threading for the default server, see the diff below: Index: basehttp.py === --- basehttp.py (revision 4183) +++ basehttp.py (working copy) @@ -7,10 +7,16 @@ been reviewed for security issu

Re: Django with CherryPy 3.0

2007-01-22 Thread Istvan Albert
Jeremy Dunck wrote: > That said, most of the time, this is good stuff. Perhaps a management > option to turn it off? My understanding is that no part of basehttp.py is used when Django is deployed via modpython. If that is correct then this addition would make no difference in a production envi

a simple patch for streaming uploads

2007-02-05 Thread Istvan Albert
There is ticket (and a patch) for enabling streaming uploads, but it seemed a little complicated and until it gets accepted (or reworked) here is nice workaround to do the same. See patch at the end. It is backward compatible, the current behavior stays the same, you can use still request.FILES t

Re: django documentation - editing

2007-03-27 Thread Istvan Albert
On Mar 25, 8:06 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > I fear that one day I will achieve that and will then be asked to leave > the safety of the monastery and journey the world righting injustice in > episodic television format... that is quite funny ... one more reason to read t

Re: Newforms: colon after label

2007-03-29 Thread Istvan Albert
I think the OP is correct, if you want the label to end with a colon ... then add the colon to the label. It doesn't get any simpler than that. Any other solution just gets in the way. i. --~--~-~--~~~---~--~~ You received this message because you are subscribed

Re: Streaming uploads to temp files

2006-03-26 Thread Istvan Albert
> But I have concerns about performance in the common case. File upload is inherently a slow process strictly limited by the connection speed so it is not clear that any kind of performace problems would be noticable at all (even if there were such problems) Loading files into memory is *extreme

Re: HttpResponse with file-like objects

2006-04-01 Thread Istvan Albert
Two observations: 1. It is hard to believe that Django does not already do this ... it is somewhat depressing to see that trivial behavior such as streaming output was never implemented 2. I'm commenting here as an outsider, but looking at the patch it seems that the _is_string attribute is unne

Re: HttpResponse with file-like objects

2006-04-02 Thread Istvan Albert
but it is not an arbitraty iterator one is writing to, it is the the HttpResponse, why couldn't it handle new content being added just because some content is present as an interator? once it exhausts the original iterator it could continue on (if new content was added after it) or why not let th

Re: HttpResponse with file-like objects

2006-04-02 Thread Istvan Albert
> just can't imagine any practical application of this... suppose one wants to return content created by two generators ... they could wrap it themselves into a single one but why not write it both to the response and let that iterate thru each, if your code would support that it would end up be

Re: Connections not being closed in m-r

2006-04-05 Thread Istvan Albert
> I don't understand how the traceback module ends up being None > Adding a check for None will make the warning message go away fixing up code to make a mysterious error message go away is vey very suboptimal (ok ... so I've done I it myself a few times as well ...) --~--~-~--~~--

Re: Django 100% threadsafe with DB?

2007-09-25 Thread Istvan Albert
Django is 0% threadsafe (as in nada, null or zilch) it is not supposed to be run that way, but if you must keep locking around every operation. i. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django develo

Re: Django 100% threadsafe with DB?

2007-09-26 Thread Istvan Albert
On Sep 25, 10:58 pm, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > ensure there own code is multithread safe, but now again someone is > saying that Django itself is not multithread safe. :-( Well, I was just repeating the what I heard from the developers. Not so long ago a proposal was made th