403Webshell
Server IP : 182.53.201.61  /  Your IP : 216.73.217.175
Web Server : Apache/2.2.15 (Fedora)
System : Linux km10.dyndns.org 2.6.31.5-127.fc12.i686.PAE #1 SMP Sat Nov 7 21:25:57 EST 2009 i686
User : apache ( 48)
PHP Version : 5.3.3
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/lib/python2.6/site-packages/paste/debug/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python2.6/site-packages/paste/debug/profile.pyc
Ñò
ÊIc@s×dZddkZddkZddkZddkZddkZddkZddkZddkl	Z	ddk
lZddgZde
fd„ƒYZd„Zd	„Zd
e
fd„ƒYZdd
d„ZdS(se
Middleware that profiles the request and displays profiling
information at the bottom of each page.
iÿÿÿÿN(tStringIO(tresponsetProfileMiddlewaretprofile_decoratorcBs/eZdZdZdddd„Zd„ZRS(s•
    Middleware that profiles all requests.

    All HTML pages will have profiling information appended to them.
    The data is isolated to that single request, and does not include
    data from previous requests.

    This uses the ``hotshot`` module, which affects performance of the
    application.  It also runs in a single-threaded mode, so it is
    only usable in development environments.
    sWclear: both; background-color: #ff9; color: #000; border: 2px solid #000; padding: 5px;sprofile.log.tmpi(cCs.||_tiƒ|_||_||_dS(N(tappt	threadingtLocktlocktlog_filenametlimit(tselfRtglobal_confRR	((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyt__init__&s		c
sŒg‰g‰d‡‡‡fd†‰‡‡‡‡fd†}ˆiiƒz.tiˆiƒ}|idˆiddƒƒz|i|ƒWd|i	ƒXdi
ˆƒ‰ˆd}ti|dƒ}|djp|i
dƒoˆgStiiˆiƒ}|iƒ|id	d
ƒt|iˆiƒ}t|iˆiƒ}	ˆdˆiti|ƒti|	ƒf7‰ˆgSWdˆiiƒXdS(Ncs*ˆi||gƒˆ|||ƒˆiS(N(textendtappend(tstatustheaderstexc_info(tbodytstart_responsetcatch_response(s7/usr/lib/python2.6/site-packages/paste/debug/profile.pytreplace_start_response1scsIˆiˆˆƒ}zˆi|ƒWdt|dƒo|iƒnXdS(Ntclose(RR
thasattrR(tapp_iter(RRR
tenviron(s7/usr/lib/python2.6/site-packages/paste/debug/profile.pytrun_app5s
tURLt	PATH_INFOtiscontent-types	text/htmlttimetcallss<pre style="%s">%s
%s</pre>(tNoneRtacquirethotshottProfileRtaddinfotgettruncallRtjoinRtheader_valuet
startswithtstatstloadt
strip_dirst
sort_statstcapture_outputtprint_statsR	t
print_callerststyletcgitescapetrelease(
R
RRRtprofRtcontent_typeR*toutputtoutput_callers((RRRR
RRs7/usr/lib/python2.6/site-packages/paste/debug/profile.pyt__call__.s4


&N(t__name__t
__module__t__doc__R1R RR9(((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRscOsCtƒ}ti}|t_z|||ŽWd|t_X|iƒS(N(Rtsyststdouttgetvalue(tfunctargstkwtoutt
old_stdout((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyR.Vs			
cs1ˆidƒod„}|S‡fd†}|S(sú
    Profile a single function call.
    
    Used around a function, like::

        @profile_decorator(options...)
        def ...

    All calls to the function will be profiled.  The options are
    all keywords, and are:

        log_file:
            The filename to log to (or ``'stdout'`` or ``'stderr'``).
            Default: stderr.
        display_limit:
            Only show the top N items, default: 20.
        sort_stats:
            A list of string-attributes to sort on.  Default
            ``('time', 'calls')``.
        strip_dirs:
            Strip directories/module names from files?  Default True.
        add_info:
            If given, this info will be added to the report (for your
            own tracking).  Default: none.
        log_filename:
            The temporary filename to log profiling data to.  Default;
            ``./profile_data.log.tmp``
        no_profile:
            If true, then don't actually profile anything.  Useful for
            conditional profiling.
    t
no_profilecSs|S(N((R@((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyt	decorator…scs‡‡fd†}|S(Ncstˆˆ||ŽS(N(tDecoratedProfile(RARB(R@toptions(s7/usr/lib/python2.6/site-packages/paste/debug/profile.pytreplacement‰s((R@RI(RH(R@s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRFˆs(R%(RHRF((RHs7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRbs
"	RGcBs8eZeiƒZd„Zd„Zd„Zd„ZRS(cKs||_||_dS(N(R@RH(R
R@RH((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyR’s	cOs<|iiƒz|i|i||ŽSWd|iiƒXdS(N(RR!tprofileR@R4(R
RARB((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyR9–s
cOsq|i}|iddƒ}ti|ƒ}|id|i|||Žƒ|idƒo|id|dƒnd}zKtiƒ}y|i|||Ž}	Wnt	i
ƒ}nXtiƒ}
Wd|iƒXtii
|ƒ}ti|ƒ|idtƒo|iƒn|i|iddƒŒ|id
dƒ}t|i|ƒ}
t|i|ƒ}|idƒ}|djo
t	i}nY|djo
t	i}n?t|dƒ}|idddƒ|idtidƒƒ|id|i|||Žƒ|id|
|ƒ|i|
ƒ|i|ƒ|djo|iƒn|o|d|d|d‚n|	S(NRsprofile_data.log.tmps
Function Calltadd_infos
Extra infoR,R-RRt
display_limititlog_filetstderrt-R>tas
%s
i<s	Date: %s
s%csFunction call: %s
sWall time: %0.2f seconds
iii(stimescalls(Nsstderr(ROsstdout(NROsstdoutsstderr(RHR%R"R#R$tformat_functionR RR&R=RRR*R+tostunlinktTrueR,R-R.R/R0RNR>topentwritetstrftime(R
R@RARBtopst
prof_filenameR5Rt
start_timetresulttend_timeR*RLR7R8toutput_filetf((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRJsX		




		


cOsgtt|ƒ}|ig}|iƒD]\}}|d||fq&~ƒd|idi|ƒfS(Ns%s=%rs%s(%s)s, (tmaptreprR
titemsR:R'(R
R@RARBt_[1]tktv((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRQÎs8(	R:R;RRRRR9RJRQ(((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyRGŽs
			1sprofile.log.tmpi(cCs"t|ƒ}t|d|d|ƒS(s

    Wrap the application in a component that will profile each
    request.  The profiling data is then appended to the output
    of each page.

    Note that this serializes all requests (i.e., removing
    concurrency).  Therefore never use this in production.
    RR	(tintR(RRRR	((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pytmake_profile_middlewareÕs(R<R=RRR"t
hotshot.statsRR2Rt	cStringIORtpasteRt__all__tobjectRR.RRGRf(((s7/usr/lib/python2.6/site-packages/paste/debug/profile.pyt<module>s A		,I

Youez - 2016 - github.com/yon3zu
LinuXploit