ó ïRec@@s=ddlmZddlZddlZddlZddlZddlZddlZddlmZm Z ddl m Z ddl m Z ddlmZddlmZyddlZWnek rÝddlZnXyddlmZWnek r dZnXdd lmZeZejƒZe d ƒZd efd „ƒYZe rte rhd „Z qd„Z ne r†d„Z n d„Z ej!dd„ƒZ"d„Z#dej$fd„ƒYZ%d„Z&dej'fd„ƒYZ(dej)j*fd„ƒYZ+defd„ƒYZ,defd„ƒYZ-d„Z.dS( i(tabsolute_importN(tFiltert getLogger(tPY2(tWINDOWS(tDEPRECATION_MSG_PREFIX(t ensure_dir(tcolorama(tForespip.subprocessortBrokenStdoutLoggingErrorcB@seZdZRS(sO Raised if BrokenPipeError occurs for the stdout stream while logging. (t__name__t __module__t__doc__(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR :scC@s%|tko$|jtjtjfkS(s1See the docstring for non-Windows Python 3 below.(tIOErrorterrnotEINVALtEPIPE(t exc_classtexc((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt_is_broken_pipe_errorHs cC@s1|tkp0|tko0|jtjtjfkS(s1See the docstring for non-Windows Python 3 below.(tBrokenPipeErrortOSErrorRRR(RR((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRNs  cC@s|tko|jtjkS(s1See the docstring for non-Windows Python 3 below.(R RR(RR((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRTscC@s |tkS(s£ Return whether an exception is a broken pipe error. Args: exc_class: an exception class. exc: an exception instance. (R(RR((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRYsicc@s;tƒt_tj|7_z dVWdtj|8_XdS(sv A context manager which will cause the log output to be indented for any log messages emitted inside it. N(tget_indentationt _log_statet indentation(tnum((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt indent_logds   cC@sttddƒS(NRi(tgetattrR(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRsstIndentingFormattercB@s#eZd„Zd„Zd„ZRS(cO@s2|jdtƒ|_tt|ƒj||ŽdS(sÎ A logging.Formatter that obeys the indent_log() context manager. :param add_timestamp: A bool indicating output lines should be prefixed with their record's timestamp. t add_timestampN(tpoptFalseRtsuperRt__init__(tselftargstkwargs((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR!yscC@s=|tjkrdS|jtƒr&dS|tjkr9dSdS(sv Return the start of the formatted log message (not counting the prefix to add to each line). ts WARNING: sERROR: (tloggingtWARNINGt startswithRtERROR(R"t formattedtlevelno((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pytget_message_startƒscC@s±tt|ƒj|ƒ}|j||jƒ}||}d}|jrm|j|dƒ}djtƒ}n|dtƒ7}dj g|j t ƒD]}||^q”ƒ}|S(s† Calls the standard formatter, but will indent all of the log message lines by our current indentation level. R%s%Y-%m-%dT%H:%M:%Ss{t},{record.msecs:03.0f} t ( R RtformatR,R+Rt formatTimetlocalsRtjoint splitlinestTrue(R"trecordR*t message_starttprefixtttline((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR.“s  &(R R R!R,R.(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRws c@s‡fd†}|S(Nc@s#djtˆƒ|tjjgƒS(NR%(R1tlistRtStylet RESET_ALL(tinp(tcolors(sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pytwrappedªs((R=R>((R=sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt _color_wrap©stColorizedStreamHandlercB@szeZer?ejeejƒfejeej ƒfgZ ngZ ddd„Z d„Z d„Zd„Zd„ZRS(cC@sDtjj||ƒ||_tr@tr@tj|jƒ|_ndS(N(R&t StreamHandlerR!t _no_colorRRt AnsiToWin32tstream(R"RDtno_color((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR!»s  cC@s/trtr|jjtjkS|jtjkS(sA Return whether the handler is using sys.stdout. (RRRDR>tsyststdout(R"((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt _using_stdoutÂs cC@s}t s|jrtSt|jtjƒs2|jn |jj}t|dƒr]|jƒr]t St j j dƒdkryt StS(NtisattytTERMtANSI( RRBRt isinstanceRDRCR>thasattrRIR3tostenvirontget(R"t real_stream((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt should_colorÌs cC@satjj||ƒ}|jƒr]x9|jD]+\}}|j|kr+||ƒ}Pq+q+Wn|S(N(R&RAR.RRtCOLORSR+(R"R4tmsgtleveltcolor((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR.ás   cC@sYtjƒd \}}|rC|jƒrCt||ƒrCtƒ‚ntt|ƒj|ƒS(Ni(RFtexc_infoRHRR R R@t handleError(R"R4RR((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRXís  N(R R RR&R)R?RtREDR'tYELLOWRStNoneR!RHRRR.RX(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR@¯s  tBetterRotatingFileHandlercB@seZd„ZRS(cC@s,ttjj|jƒƒtjjj|ƒS(N( RRNtpathtdirnamet baseFilenameR&thandlerstRotatingFileHandlert_open(R"((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRbüs(R R Rb(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR\ústMaxLevelFiltercB@seZd„Zd„ZRS(cC@s ||_dS(N(RU(R"RU((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyR!scC@s|j|jkS(N(R+RU(R"R4((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pytfilters(R R R!Rd(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRcs tExcludeLoggerFiltercB@seZdZd„ZRS(sQ A logging Filter that excludes records from a logger (or its children). cC@stt|ƒj|ƒ S(N(R ReRd(R"R4((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRds(R R R Rd(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyRe sc C@s·|dkrd}nE|dkr*d}n0|dkr?d}n|dkrTd}nd }tt|ƒ}|d2k }|rŠ|}d}n d }|}|d3kr¨dnd}id d 6d d6} idd6dd6} dddg|rñdgng} tjjidd6td6iidd6tjd6d6idd6tjd6d6id d6tjd6d!6d"6iit d6d#d$6d%6it d6d#d$6t d&6d'6d(6ii|d6| dd)6|d*6| d d6d!dgd"6d%d+6d6idd6| dd)6|d*6| dd6d!gd"6d%d+6d6i|d6| dd)6|d*6| dd6dgd"6d%d+6d6idd6| dd)6|d,6t d-6d'd+6d6d.6i|d6| d.6d/6ii|d6d06d16ƒ|S(4snConfigures and sets up all of the logging Returns the requested logging level, as its integer value. itDEBUGiÿÿÿÿR'iþÿÿÿR)iýÿÿÿtCRITICALtINFOs /dev/nullsext://sys.stdoutRGsext://sys.stderrtstderrs2pip._internal.utils.logging.ColorizedStreamHandlerRDs5pip._internal.utils.logging.BetterRotatingFileHandlertfiletconsoletconsole_errorstconsole_subprocesstuser_logtversiontdisable_existing_loggerss*pip._internal.utils.logging.MaxLevelFilters()RUtexclude_warningsslogging.Filtertnametrestrict_to_subprocesss/pip._internal.utils.logging.ExcludeLoggerFiltertexclude_subprocesstfilterss %(message)sR.tindentRtindent_with_timestampt formatterstclassREt formattertfilenametdelayR`troots pip._vendortloggersN(RhR)( RR&R[tconfigt dictConfigRR'tsubprocess_loggerRrRR3( t verbosityREt user_log_fileRUt level_numbertinclude_user_logtadditional_log_filet root_leveltvendored_log_levelt log_streamsthandler_classesR`((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pyt setup_loggings¢                             (/t __future__Rt contextlibRR&tlogging.handlersRNRFRRtpip._vendor.sixRtpip._internal.utils.compatRtpip._internal.utils.deprecationRtpip._internal.utils.miscRt threadingt ImportErrortdummy_threadingt pip._vendorRt _coloramat ExceptionR[tpip._vendor.coloramaRtlocalRRR RtcontextmanagerRRt FormatterRR?RAR@R`RaR\RcReR‹(((sŠ/builddir/build/BUILDROOT/alt-python27-pip-20.2.4-5.el8.x86_64/opt/alt/python27/lib/python2.7/site-packages/pip/_internal/utils/logging.pytsR                  2 K