Thanks, but does self.response.out affects speed very much?
I couldn't benchmark it, strange...


On 28 מאי, 22:25, David Wilson <[email protected]> wrote:
> Using self.response.out will also delay sending your entire response
> until it is sure to succeed.
>
> If you start generating output using 'print', and then e.g. a
> Datastore request times out, or a bug in your code is triggered, you
> have no chance to display a friendly error message. Instead the user
> will get a half-rendered page with a stack trace embedded in it, or
> worse.
>
> David.
>
> 2009/5/28 Shedokan <[email protected]>:
>
>
>
>
>
>
>
> > so I can't print binary data like Images?
>
> > On 28 מאי, 21:03, 风笑雪 <[email protected]> wrote:
> >> Print is also OK, but you need handle header by yourself, and it can only
> >> output 
> >> text.http://code.google.com/intl/en/appengine/docs/python/gettingstarted/h...
>
> >> print 'Content-Type: text/plain'
> >> print ''
> >> print 'Hello, world!'
>
> >> 2009/5/29 Shedokan <[email protected]>
>
> >> > I am wondering why should I use self.response.out.write and not print
> >> > everything.
>
> >> > because I am making this app where I have to output from a lot
> >> > ofdifferent functions and I am passing the object 'self' everywhere.
>
> >> > thanks.
>
> --
> It is better to be wrong than to be vague.
>   — Freeman Dyson
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to