
    6h                    2    S SK Jr  SSKJr  SSKJr  SS jrg)    )annotations   )_)errorc                ^   ^ ^ T R                  SSU-   5      mT(       a  TS;  a  gU U4S jnU$ )a  Get a function that checks file handle position is as expected.

This is used to ensure that files haven't been modified outside of our
knowledge (such as on a networked filesystem, if `hg debuglocks` was used,
or writes to .hg that ignored locks happened).

Due to revlogs supporting a concept of buffered, delayed, or diverted
writes, we're allowing the files to be shorter than expected (the data may
not have been written yet), but they can't be longer.

Please note that this check is not perfect; it can't detect all cases (there
may be false-negatives/false-OKs), but it should never claim there's an
issue when there isn't (false-positives/false-failures).
   debugs   revlog.verifyposition.)s   log   warn   failNc                J  > U R                  5       U::  a  g [        S5      nTR                  SUS-   XR                  5       U5        TS:X  a(  TR                  US-   XR                  5       U4-  5        g TS:X  a)  [        R
                  " X1U R                  5       U4-  5      eg )Ns+   %s: file cursor at position %d, expected %dr      
r	   r
   )tellr   logwarnr   RevlogError)fhfnexpectedmsguivposs       K/usr/lib/python3/dist-packages/mercurial/revlogutils/concurrency_checker.py_checkerget_checker.<locals>._checker   s    779 >?
xub'')X>7?GGS5[RH$==>W_##Crwwy(*C$CDD     )config)r   revlog_namer   r   s   `  @r   get_checkerr      s6      99X8;FGD499
E Or   N)s	   changelog)
__future__r   i18nr    r   r    r   r   <module>r"      s    "  !r   