OK, I guess this is what needs to be done:
---
if __name__ == "__main__":
app.run( web.http.profiler )
---
Testing this on my Vista (ouch) machine I get this error, I guess this
is related to my environment:
---
Traceback (most recent call last):
File "c:\Python25\lib\site-packages\web\wsgiserver\__init__.py",
line 1174, in communicate
req.respond()
File "c:\Python25\lib\site-packages\web\wsgiserver\__init__.py",
line 544, in respond
self._respond()
File "c:\Python25\lib\site-packages\web\wsgiserver\__init__.py",
line 556, in _respond
response = self.wsgi_app(self.environ, self.start_response)
File "c:\Python25\lib\site-packages\web\httpserver.py", line 201, in
__call__
return self.app(environ, xstart_response)
File "c:\Python25\Lib\site-packages\web\http.py", line 132, in
profile_internal
out, result = profile(app)(e, o)
File "c:\Python25\Lib\site-packages\web\utils.py", line 736, in
__call__
prof = hotshot.Profile(temp.name)
File "c:\Python25\lib\hotshot\__init__.py", line 13, in __init__
logfn, self.lineevents, self.linetimings)
IOError: [Errno 13] Permission denied: 'c:\\users\\asmo\\appdata\\local
\\temp\\tmpnimxms'
---
On Feb 2, 6:13 pm, asmo <[email protected]> wrote:
> Any change to get a code example of this? Can this be used with any
> server configuration?
>
> > Simple, simple, simple!
> > Very webpy style!
> > Thanks.
>
> > On Dec 26, 6:04 pm, "Aaron Swartz" <[email protected]> wrote:
>
> > > It's middleware, so you pass it to app.run.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web.py" 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/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---