Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
Size: Mime:
B

$=6U\ûã@sddlZddlZddlZddlZddlZddlZddlZddlZddlZddl	Z	ddl
Z
ddlZddlm
Z
ddlmZej d¡r¤ddlmmmmZnejejZyeZWnek
rÐdZYnXeZddddgZd0d	d
„Zejd1dd„ƒZ ejd
d„ƒZ!ejdd„ƒZ"ejdd„ƒZ#Gdd„de$ƒZ%Gdd„dƒZ&ejdd„ƒZ'dd„Z(ejdd„ƒZ)ejdd„ƒZ*dd d!d"d#hZ+d$d%„Z,d&d'„Z-d(d„Z.Gd)d„dƒZ/e0ed*ƒrÀej1gZ2ngZ2Gd+d„de/ƒZ3e 4ej5d,d-„d. 6¡Dƒ¡Z7Gd/d„de
ƒZ8dS)2éN)ÚDistutilsError)Úworking_setÚjavaÚAbstractSandboxÚDirectorySandboxÚSandboxViolationÚ	run_setupc	CsJd}t||ƒ}| ¡}WdQRX|dkr.|}t||dƒ}t|||ƒdS)z.
    Python 3 implementation of execfile.
    ÚrbNÚexec)ÚopenÚreadÚcompiler
)ÚfilenameÚglobalsÚlocalsÚmodeÚstreamÚscriptÚcode©rú‘/build/wlanpi-profiler-7At3M6/wlanpi-profiler-1.0.10/debian/wlanpi-profiler/opt/wlanpi-profiler/lib/python3.7/site-packages/setuptools/sandbox.pyÚ	_execfile$src
csDtjdd…}|dk	r$|tjdd…<z
|VWd|tjdd…<XdS)N)ÚsysÚargv)ÚreplÚsavedrrrÚ	save_argv1s
rc
cs.tjdd…}z
|VWd|tjdd…<XdS)N)rÚpath)rrrrÚ	save_path<s
rccs2tj|ddtj}|t_z
dVWd|t_XdS)zL
    Monkey-patch tempfile.tempdir with replacement, ensuring it exists
    T)Úexist_okN)ÚosÚmakedirsÚtempfileÚtempdir)ÚreplacementrrrrÚ
override_tempEs
r%c	cs.t ¡}t |¡z
|VWdt |¡XdS)N)r ÚgetcwdÚchdir)ÚtargetrrrrÚpushdVs


r)c@seZdZdZedd„ƒZdS)ÚUnpickleableExceptionzP
    An exception representing another Exception that could not be pickled.
    c	CsJyt |¡t |¡fStk
rDddlm}| ||t|ƒƒ¡SXdS)z‰
        Always return a dumped (pickled) type and exc. If exc can't be pickled,
        wrap it in UnpickleableException first.
        r)r*N)ÚpickleÚdumpsÚ	ExceptionÚsetuptools.sandboxr*ÚdumpÚrepr)ÚtypeÚexcÚclsrrrr/es
zUnpickleableException.dumpN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ústaticmethodr/rrrrr*`sr*c@s(eZdZdZdd„Zdd„Zdd„ZdS)	ÚExceptionSaverz^
    A Context Manager that will save an exception, serialized, and restore it
    later.
    cCs|S)Nr)ÚselfrrrÚ	__enter__zszExceptionSaver.__enter__cCs |sdSt ||¡|_||_dS)NT)r*r/Ú_savedÚ_tb)r:r1r2ÚtbrrrÚ__exit__}s
zExceptionSaver.__exit__cCs2dt|ƒkrdSttj|jƒ\}}| |j¡‚dS)z"restore and re-raise any exceptionr<N)ÚvarsÚmapr+Úloadsr<Úwith_tracebackr=)r:r1r2rrrÚresumeˆszExceptionSaver.resumeN)r4r5r6r7r;r?rDrrrrr9tsr9c	#sVtj ¡‰tƒ}ˆVWdQRXtj ˆ¡‡fdd„tjDƒ}t|ƒ| ¡dS)z 
    Context in which imported modules are saved.

    Translates exceptions internal to the context into the equivalent exception
    outside the context.
    Nc3s$|]}|ˆkr| d¡s|VqdS)z
encodings.N)Ú
startswith)Ú.0Úmod_name)rrrú	<genexpr>¡szsave_modules.<locals>.<genexpr>)rÚmodulesÚcopyr9ÚupdateÚ_clear_modulesrD)Ú	saved_excZdel_modulesr)rrÚsave_modules’s


rNcCsxt|ƒD]}tj|=q
WdS)N)ÚlistrrI)Zmodule_namesrGrrrrL¬srLc	cs$t ¡}z
|VWdt |¡XdS)N)Ú
pkg_resourcesÚ__getstate__Ú__setstate__)rrrrÚsave_pkg_resources_state±s
rSccs–tj |d¡}tƒxtƒftƒTtƒtƒ<t|ƒ(t	|ƒt
dƒdVWdQRXWdQRXWdQRXWdQRXWdQRXWdQRXdS)NÚtempÚ
setuptools)r rÚjoinrSrNrÚhide_setuptoolsrr%r)Ú
__import__)Ú	setup_dirÚtemp_dirrrrÚ
setup_contextºs

r[rUÚ	distutilsrPZCythonÚ_distutils_hackcCs| dd¡d}|tkS)aH
    >>> _needs_hiding('setuptools')
    True
    >>> _needs_hiding('pkg_resources')
    True
    >>> _needs_hiding('setuptools_plugin')
    False
    >>> _needs_hiding('setuptools.__init__')
    True
    >>> _needs_hiding('distutils')
    True
    >>> _needs_hiding('os')
    False
    >>> _needs_hiding('Cython')
    True
    Ú.ér)ÚsplitÚ_MODULES_TO_HIDE)rGÚbase_modulerrrÚ
_needs_hidingÒsrccCs6tj dd¡}|dk	r| ¡tttjƒ}t|ƒdS)a%
    Remove references to setuptools' modules from sys.modules to allow the
    invocation to import the most appropriate setuptools. This technique is
    necessary to avoid issues such as #315 where setuptools upgrading itself
    would fail to find a function declared in the metadata.
    r]N)rrIÚgetZremove_shimÚfilterrcrL)r]rIrrrrWçs
rWcCsÎtj tj |¡¡}t|ƒ¨yl|gt|ƒtjdd…<tj d|¡t	 
¡t	j dd„¡t
|ƒt|dd}t||ƒWdQRXWn4tk
r¾}z|jr®|jdr®‚Wdd}~XYnXWdQRXdS)z8Run a distutils setup script, sandboxed in its directoryNrcSs| ¡S)N)Úactivate)ÚdistrrrÚ<lambda>ÿózrun_setup.<locals>.<lambda>Ú__main__)Ú__file__r4)r rÚabspathÚdirnamer[rOrrÚinsertrÚ__init__Ú	callbacksÚappendrÚdictrÚ
SystemExitÚargs)Zsetup_scriptrtrYÚnsÚvrrrrös

c@s.eZdZdZdZdd„Zdd„Zdd„Zd	d
„Zdd„Z	d
d„Z
x$dD]Zee
eƒrFe
eƒeƒe<qFWd$dd„Zer~edeƒZedeƒZx$dD]Zee
eƒrŽeeƒeƒe<qŽWdd„Zx$dD]Zee
eƒr¼eeƒeƒe<q¼Wdd„Zx$dD]Zee
eƒrêeeƒeƒe<qêWdd„Zdd„Zd d!„Zd"d#„ZdS)%rzDWrap 'os' module and 'open()' builtin for virtualizing setup scriptsFcs‡fdd„ttƒDƒˆ_dS)Ncs$g|]}| d¡stˆ|ƒr|‘qS)Ú_)rEÚhasattr)rFÚname)r:rrú
<listcomp>sz,AbstractSandbox.__init__.<locals>.<listcomp>)ÚdirÚ_osÚ_attrs)r:r)r:rros
zAbstractSandbox.__init__cCs&x |jD]}tt|t||ƒƒqWdS)N)r}Úsetattrr Úgetattr)r:ÚsourceryrrrÚ_copyszAbstractSandbox._copycCs(| |¡tr|jt_|jt_d|_dS)NT)rÚ_fileÚbuiltinsÚfileÚ_openrÚ_active)r:rrrr;s

zAbstractSandbox.__enter__cCs$d|_trtt_tt_| t¡dS)NF)r†r‚rƒr„r…rrr|)r:Úexc_typeÚ	exc_valueÚ	tracebackrrrr?!s
zAbstractSandbox.__exit__c	Cs||ƒSQRXdS)zRun 'func' under os sandboxingNr)r:ÚfuncrrrÚrun(szAbstractSandbox.runcsttˆƒ‰‡‡fdd„}|S)Ncs2|jr |jˆ||f|ž|Ž\}}ˆ||f|ž|ŽS)N)r†Ú_remap_pair)r:ÚsrcÚdstrtÚkw)ryÚoriginalrrÚwrap0sz3AbstractSandbox._mk_dual_path_wrapper.<locals>.wrap)rr|)ryr‘r)ryrrÚ_mk_dual_path_wrapper-s
z%AbstractSandbox._mk_dual_path_wrapper)ÚrenameÚlinkÚsymlinkNcs ˆpttˆƒ‰‡‡fdd„}|S)Ncs*|jr|jˆ|f|ž|Ž}ˆ|f|ž|ŽS)N)r†Ú_remap_input)r:rrtr)ryrrrr‘>sz5AbstractSandbox._mk_single_path_wrapper.<locals>.wrap)rr|)ryrr‘r)ryrrÚ_mk_single_path_wrapper;sz'AbstractSandbox._mk_single_path_wrapperr„r)ÚstatÚlistdirr'rÚchmodÚchownÚmkdirÚremoveÚunlinkÚrmdirÚutimeÚlchownÚchrootÚlstatZ	startfileÚmkfifoÚmknodÚpathconfÚaccesscsttˆƒ‰‡‡fdd„}|S)NcsB|jr2|jˆ|f|ž|Ž}| ˆˆ|f|ž|Ž¡Sˆ|f|ž|ŽS)N)r†r–Ú
_remap_output)r:rrtr)ryrrrr‘csz4AbstractSandbox._mk_single_with_return.<locals>.wrap)rr|)ryr‘r)ryrrÚ_mk_single_with_return`s
z&AbstractSandbox._mk_single_with_return)ÚreadlinkÚtempnamcsttˆƒ‰‡‡fdd„}|S)Ncs ˆ||Ž}|jr| ˆ|¡S|S)N)r†r¨)r:rtrÚretval)ryrrrr‘rs
z'AbstractSandbox._mk_query.<locals>.wrap)rr|)ryr‘r)ryrrÚ	_mk_queryos
zAbstractSandbox._mk_query)r&ÚtmpnamcCs|S)z=Called to remap or validate any path, whether input or outputr)r:rrrrÚ_validate_path~szAbstractSandbox._validate_pathcOs
| |¡S)zCalled for path inputs)r¯)r:Ú	operationrrtrrrrr–‚szAbstractSandbox._remap_inputcCs
| |¡S)zCalled for path outputs)r¯)r:r°rrrrr¨†szAbstractSandbox._remap_outputcOs0|j|d|f|ž|Ž|j|d|f|ž|ŽfS)z?Called for path pairs like rename, link, and symlink operationsz-fromz-to)r–)r:r°rrŽrtrrrrrŒŠszAbstractSandbox._remap_pair)N)r4r5r6r7r†rorr;r?r‹r’ryrxr|rr—r‚r…r©r­r¯r–r¨rŒrrrrr
s<












Údevnullc@s–eZdZdZe dddddddd	d
ddd
dg
¡ZgZefdd„Z	dd„Z
erVd&dd„Zd'dd„Zdd„Z
dd„Zdd„Zdd„Zd d!„Zd(d#d$„Zd%S))rz<Restrict operations to a single subdirectory - pseudo-chrootrršr›rœrržrŸr r¡r¢r¤r¥r«cCsFtj tj |¡¡|_tj |jd¡|_dd„|Dƒ|_t 	|¡dS)NÚcSs g|]}tj tj |¡¡‘qSr)r rÚnormcaseÚrealpath)rFrrrrrz´sz-DirectorySandbox.__init__.<locals>.<listcomp>)
r rr³r´Ú_sandboxrVÚ_prefixÚ_exceptionsrro)r:ZsandboxÚ
exceptionsrrrro°szDirectorySandbox.__init__cOsddlm}||||ƒ‚dS)Nr)r)r.r)r:r°rtrrrrrÚ
_violation¸szDirectorySandbox._violationÚrcOs:|dkr(| |¡s(|jd||f|ž|Žt||f|ž|ŽS)N)rºÚrtr	ÚrUÚUr„)Ú_okr¹r‚)r:rrrtrrrrr‚¿szDirectorySandbox._filecOs:|dkr(| |¡s(|jd||f|ž|Žt||f|ž|ŽS)N)rºr»r	r¼r½r)r¾r¹r…)r:rrrtrrrrr…ÄszDirectorySandbox._opencCs| d¡dS)Nr®)r¹)r:rrrr®ÉszDirectorySandbox.tmpnamcCsN|j}z:d|_tj tj |¡¡}| |¡p@||jkp@| |j¡S||_XdS)NF)	r†r rr³r´Ú	_exemptedrµrEr¶)r:rÚactiver´rrrr¾Ìs

zDirectorySandbox._okcs<‡fdd„|jDƒ}‡fdd„|jDƒ}t ||¡}t|ƒS)Nc3s|]}ˆ |¡VqdS)N)rE)rFÚ	exception)ÚfilepathrrrHÛsz-DirectorySandbox._exempted.<locals>.<genexpr>c3s|]}t |ˆ¡VqdS)N)ÚreÚmatch)rFÚpattern)rÂrrrHÞs)r·Ú_exception_patternsÚ	itertoolsÚchainÚany)r:rÂZ
start_matchesZpattern_matchesÚ
candidatesr)rÂrr¿ÙszDirectorySandbox._exemptedcOs4||jkr0| |¡s0|j|tj |¡f|ž|Ž|S)zCalled for path inputs)Ú	write_opsr¾r¹r rr´)r:r°rrtrrrrr–ãszDirectorySandbox._remap_inputcOs2| |¡r| |¡s*|j|||f|ž|Ž||fS)z?Called for path pairs like rename, link, and symlink operations)r¾r¹)r:r°rrŽrtrrrrrŒészDirectorySandbox._remap_pairéÿcOs@|t@r*| |¡s*|jd|||f|ž|Žtj|||f|ž|ŽS)zCalled for low-level os.open()zos.open)ÚWRITE_FLAGSr¾r¹r|r)r:r„ÚflagsrrtrrrrrïszDirectorySandbox.openN)rº)rº)rÌ)r4r5r6r7rrÚfromkeysrËrÆÚ_EXCEPTIONSror¹r‚r…r®r¾r¿r–rŒrrrrrr˜s6



cCsg|]}tt|dƒ‘qS)r)rr|)rFÚarrrrzùsrzz4O_WRONLY O_RDWR O_APPEND O_CREAT O_TRUNC O_TEMPORARYc@s&eZdZdZe d¡ ¡Zdd„ZdS)rzEA setup script attempted to modify the filesystem outside the sandboxa
        SandboxViolation: {cmd}{args!r} {kwargs}

        The package setup script has attempted to modify files on your system
        that are not within the EasyInstall build area, and has been aborted.

        This package cannot be safely installed by EasyInstall, and may not
        support alternate installation locations even if you run its setup
        script by hand.  Please inform the package's author and the EasyInstall
        maintainers to find out if a fix or workaround is available.
        cCs|j\}}}|jjftƒŽS)N)rtÚtmplÚformatr)r:ÚcmdrtÚkwargsrrrÚ__str__szSandboxViolation.__str__N)	r4r5r6r7ÚtextwrapÚdedentÚlstriprÒrÖrrrrrÿs
)N)N)9r rr"ÚoperatorÚ	functoolsrÇrÃÚ
contextlibr+r×rƒrPÚdistutils.errorsrrÚplatformrEZ$org.python.modules.posix.PosixModuleÚpythonrIÚposixZPosixModuler|ryr„r‚Ú	NameErrorrr…Ú__all__rÚcontextmanagerrrr%r)r-r*r9rNrLrSr[rarcrWrrrxr±rÐrÚreduceÚor_r`rÍrrrrrÚ<module>sp 



	
		
^