HEX

Warning: set_time_limit() [function.set-time-limit]: Cannot set time limit - prohibited by configuration in /home/u547966/brikov.ru/www/wp-content/plugins/admin-menu-editor/menu-editor.php on line 745
Server: Apache
System: Linux 4.19.0-0.bpo.9-amd64 x86_64 at red40
User: u547966 (5490)
PHP: 5.3.29-mh2
Disabled: syslog, dl, popen, proc_open, proc_nice, proc_get_status, proc_close, proc_terminate, posix_mkfifo, chown, chgrp, accelerator_reset, opcache_reset, accelerator_get_status, opcache_get_status, pcntl_alarm, pcntl_fork, pcntl_waitpid, pcntl_wait, pcntl_wifexited, pcntl_wifstopped, pcntl_wifsignaled, pcntl_wifcontinued, pcntl_wexitstatus, pcntl_wtermsig, pcntl_wstopsig, pcntl_signal, pcntl_signal_dispatch, pcntl_get_last_error, pcntl_strerror, pcntl_sigprocmask, pcntl_sigwaitinfo, pcntl_sigtimedwait, pcntl_exec, pcntl_getpriority, pcntl_setpriority
Upload Files
File: //usr/lib/python2.7/dist-packages/mercurial/repoview.pyc
σ
ΫXc@@s&ddlmZddlZddlZddlZddlZddlmZddlm	Z	m
Z
mZmZ
d„Zd„Zd„ZdZd	Zd
„Zd„Zd„Zd
„Zd„Zd„Zd„Zd„Zied6ed6ed6ed6Zd„Zdefd„ƒYZdS(i(tabsolute_importNi(tnullrev(terrortobsoletetphasesttagscC@stj|dƒS(saRevision candidates to be hidden

    This is a standalone function to allow extensions to wrap it.

    Because we use the set of immutable changesets as a fallback subset in
    branchmap (see mercurial.branchmap.subsettable), you cannot set "public"
    changesets as "hideable". Doing so would break multiple code assertions and
    lead to crashes.R(Rtgetrevs(trepo((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pythideablerevss	c
C@sT|jjst‚tt|ƒƒ}|rP|jj}|jj}g|jjƒD]}|||ƒrS|^qS}t	j
|ƒt	j}t	j}tƒ}x°|rL||ƒ}	|	|k}
x‡||	ƒD]y}|t
krδqΜn|
rϊ|j|ƒnt|ƒ}|j|ƒ|t|ƒkrΜ|||	ƒrΜ|||ƒqΜqΜWq Wn|S(snRevision to be hidden (disregarding dynamic blocker)

    To keep a consistent graph, we cannot hide any revisions with
    non-hidden descendants. This function computes the set of
    revisions that could be hidden while keeping the graph consistent.

    A second pass will be done to apply "dynamic blocker" like bookmarks or
    working directory parents.

    (t	changelogtfilteredrevstAssertionErrortsetRt_phasecachetphaset
parentrevstheadrevstheapqtheapifytheappoptheappushRtdiscardtlentadd(
Rthiddentgetphaset
getparentrevstrtheapRRtseentrevtblockertparenttpre((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt_getstatichidden#s.2
				

!c@sΩ|j}tƒ}|jg|djƒD]}|jƒ^q)ƒ|jg|jjƒD]}|j|ƒ^qXƒi}tj	|j
||iƒ|rΥ|j|j‰‰|j‡‡fd†|jƒDƒƒn|S(sNon-cacheable revisions blocking hidden changesets from being filtered.

    Get revisions that will block hidden changesets and are likely to change,
    but unlikely to create hidden blockers. They won't be cached, so be careful
    with adding additional computation.c3@s/|]%}|dˆkrˆ|dƒVqdS(iN((t.0tt(tnodemapR(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>\sN(R	RtupdatetNonetparentsRt
_bookmarkstvaluesttagsmodt
readlocaltagstuiR%(RtcltblockerstpartbmR((R%Rs6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt_getdynamicblockersLs		02)scache/hiddencC@sQtjƒ}|jdj|jƒƒƒ|jttt|ƒƒƒƒ|jƒS(s3return sha1 hash of repository data to identify a valid cache.

    We calculate a sha1 of repo heads and the content of the obsstore and write
    it to the cache. Upon reading we can easily validate by checking the hash
    against the stored one and discard the cache in case the hashes don't match.
    t(	thashlibtsha1R&tjointheadststrthasht	frozensettdigest(Rthideableth((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt	cachehashbscC@sYtjdt|ƒt|ƒŒ}|jtjdtƒƒ|j|ƒ|j|ƒdS(s!write hidden data to a cache files>%iis>HN(tstructtpackRtsortedtwritetcacheversion(t	cachefileR>Rtdata((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt_writehiddencachens"
cC@sΠd}}z«yZ|jdtƒ}t||ƒ}|jjtddtƒ}t|||ƒ|j	ƒWnJt
tfk
r|jj
dƒn$tjk
r³|jj
dƒnXWd|rΛ|jƒnXdS(swrite cache of hidden changesets to disk

    Will not write the cache if a wlock cannot be obtained lazily.
    The cache consists of a head of 22byte:
       2 byte    version number of the cache
      20 byte    sha1 to validate the cache
     n*4 byte    hidden revs
    twaitsw+bt
atomictemps&error writing hidden changesets cache
s4cannot obtain lock to write hidden changesets cache
N(R'twlocktFalseR>tvfstopenRDtTrueRFtclosetIOErrortOSErrorR-tdebugRtLockHeldtrelease(RR<RRItfhtnewhash((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyttrywritehiddencacheus	
c	C@s9d	}}zyΑ|jjtƒrΙ|jjtdƒ}tjd|jdƒƒ\}|jdƒ}t||ƒ}t	|f||fkrΙ|jƒ}t
|ƒd}ttjd||ƒƒ}qΙn|SWnLtjk
rυ|j
jdƒd	Sttfk
r|j
jdƒd	SXWd	|r4|jƒnXd	S(
sFread a cache if the cache exists and is valid, otherwise returns None.trbs>Hiiis>%iiscorrupted hidden cache
scannot read hidden cache
N(R'RKtexistsRDRLR?tunpacktreadR>RCRR:RR-RQRORPRN(	RR<RRTtversiontoldhashRUREtcount((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyttryreadcacheŽs*
"	c@sΘ|jjst‚tƒ}t|ƒ}|rΔ|j}t||ƒ}|dkrwtt|ƒƒ}t|||ƒn|t	|ƒ@}|rΔ|j
|dtƒ‰t‡fd†|Dƒƒ}qΔn|S(sbcompute the set of hidden revision to filter

    During most operation hidden should be filtered.t	inclusivec3@s!|]}|ˆkr|VqdS(N((R#R(tblocked(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>ΌsN(R	R
RR:RR^R'R"RVR2t	ancestorsRM(RRR<R.tdynamic((R`s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt
computehidden¨s		"c@sΏˆjjst‚tˆdƒ}tjˆƒr·ˆj‰tj‰ˆjj‰t	‡fd†ˆjj
ˆDƒƒ}ˆjd|ƒ}t‡‡‡fd†|Dƒƒ}t
||BƒS|SdS(s†compute the set of revision that should be filtered when used a server

    Secret and hidden changeset should not pretend to be here.tvisiblec3@s|]}ˆj|ƒVqdS(N(R(R#tn(R.(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>Κststartc3@s*|] }ˆˆ|ƒˆkr|VqdS(N((R#R(RRtsecret(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>ΜsN(R	R
Rt
filterrevsRt	hassecretRgR
Rtmint
phaserootstrevsRR:(RthiddenstfirstRltsecrets((R.RRRgs6/usr/lib/python2.7/dist-packages/mercurial/repoview.pytcomputeunservedΏs		&"c@shˆjjst‚tˆjjdƒraˆjj‰tˆdƒ}t‡‡fd†|DƒƒStƒS(s†compute the set of revision that should be filtered when used a server

    Secret and hidden changeset should not pretend to be here.itbasec3@s$|]}ˆˆ|ƒr|VqdS(N((R#R(RR(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>Ϊs(	R	R
RtanyR
RkRRhR:(Rt
maymutable((RRs6/usr/lib/python2.7/dist-packages/mercurial/repoview.pytcomputemutableΡsc@s™|jjst‚|j‰tˆƒ}xF|jjdD]4}|r9t|t‡fd†|Dƒƒƒ}q9q9Wtd|ƒ}tt	|tˆƒƒƒS(s.Everything impactable by mutable revision

    The immutable filter still have some chance to get invalidated. This will
    happen when:

    - you garbage collect hidden changeset,
    - public phase is moved backward,
    - something is changed in the filtering (this could be fixed)

    This filter out any mutable changeset and any public changeset that may be
    impacted by something happening to a mutable revision.

    This is achieved by filtered everything with a revision number egal or
    higher than the first mutable changeset is filtered.ic3@s|]}ˆj|ƒVqdS(N(R(R#R(R.(s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pys	<genexpr>ρsi(
R	R
RRR
RkRjtmaxR:txrange(Rtfirstmutabletroots((R.s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pytcomputeimpactableέs	,Rdtservedt	immutableRqcC@s@||jkr5t|}||jƒƒ|j|<n|j|S(s5returns set of filtered revision for this filter name(tfilteredrevcachetfiltertablet
unfiltered(Rt
filternametfunc((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyRhs
trepoviewcB@sbeZdZd„Zed„ƒZd„Zd„Zd„Zd„Z	d„Z
ed„ƒZRS(	sζProvide a read/write view of a repo through a filtered changelog

    This object is used to access a filtered version of a repository without
    altering the original repository object itself. We can not alter the
    original object for two main reasons:
    - It prevents the use of a repo with multiple filters at the same time. In
      particular when multiple threads are involved.
    - It makes scope of the filtering harder to control.

    This object behaves very closely to the original repository. All attribute
    operations are done on the original repository:
    - An access to `repoview.someattr` actually returns `repo.someattr`,
    - A write to `repoview.someattr` actually sets value of `repo.someattr`,
    - A deletion of `repoview.someattr` actually drops `someattr`
      from `repo.__dict__`.

    The only exception is the `changelog` property. It is overridden to return
    a (surface) copy of `repo.changelog` with some revisions filtered. The
    `filtername` attribute of the view control the revisions that need to be
    filtered.  (the fact the changelog is copied is an implementation detail).

    Unlike attributes, this object intercepts all method calls. This means that
    all methods are run on the `repoview` object with the filtered `changelog`
    property. For this purpose the simple `repoview` class must be mixed with
    the actual class of the repository. This ensures that the resulting
    `repoview` object have the very same methods than the repo object. This
    leads to the property below.

        repoview.method() --> repo.__class__.method(repoview)

    The inheritance has to be done dynamically because `repo` can be of any
    subclasses of `localrepo`. Eg: `bundlerepo` or `statichttprepo`.
    cC@sPtj|d|ƒtj|d|ƒtj|ddƒtj|ddƒdS(Nt_unfilteredrepoRt_clcachekeyt_clcache(tobjectt__setattr__R'(tselfRR((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt__init__+sc	C@sχ|j}|j}|j}t|ƒd}||dd}t||jƒ}|j}||t|ƒ|jf}|dk	r¦|j|k	s||j
kr¦d}n|dkrσtj|ƒ}||_t
j|d|ƒt
j|d|ƒn|S(s_return a filtered version of the changeset

        this changelog must not be used for writingiiR„RƒN(R‚R	tindexRRhRR„R9t_delayedR'RƒtcopyR
R…R†(	R‡tunfit
unfichangelogt	unfiindextunfilentunfinodeRlR.tnewkey((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyR	2s"						cC@s|jS(s&Return an unfiltered version of a repo(R‚(R‡((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyR~OscC@s&||jkr|S|jƒj|ƒS(s)Return a filtered version of a repository(RR~tfiltered(R‡tname((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyR’SscC@st|j|ƒS(N(tgetattrR‚(R‡tattr((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt__getattr__ZscC@st|j||ƒS(N(tsetattrR‚(R‡R•tvalue((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyR†]scC@st|j|ƒS(N(tdelattrR‚(R‡R•((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt__delattr__`scC@s
|jjS(N(R‚trequirements(R‡((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyR›fs(t__name__t
__module__t__doc__RˆtpropertyR	R~R’R–R†RšR›(((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyRs!						(t
__future__RR‹R4RR?tnodeRR3RRRRR+RR"R2RCRDR>RFRVR^RcRpRtRyR}RhR…R(((s6/usr/lib/python2.7/dist-packages/mercurial/repoview.pyt<module>	s2"		)