mercurial/__main__.py
author Arseniy Alekseyev <aalekseyev@janestreet.com>
Fri, 26 Apr 2024 19:10:35 +0100
changeset 51626 865efc020c33
parent 50697 e7ef11b75fdc
permissions -rw-r--r--
dirstate: remove the python-side whitelist of allowed matchers This whitelist is too permissive because it allows matchers that contain disallowed ones deep inside, for example through `intersectionmatcher`. It is also too restrictive because it doesn't pass through some of the matchers we support, such as `patternmatcher`. It's also unnecessary because unsupported matchers raise `FallbackError` and we fall back anyway. Making this change makes more of the tests use rust code path, and therefore subtly change behavior. For example, rust status in largefiles repos seems to have strange behavior.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
50697
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     1
def run():
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     2
    from . import demandimport
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     3
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     4
    with demandimport.tracing.log('hg script'):
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     5
        demandimport.enable()
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     6
        from . import dispatch
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     7
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     8
        dispatch.run()
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
     9
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
    10
50696
eb01d3a65ad8 library: enable runpy invocation on mercurial package
Jason R. Coombs <jaraco@jaraco.com>
parents:
diff changeset
    11
if __name__ == '__main__':
50697
e7ef11b75fdc library: incorporate demandimport into runpy invocation
Jason R. Coombs <jaraco@jaraco.com>
parents: 50696
diff changeset
    12
    run()