view mercurial/interfaces/types.py @ 53040:cdd7bf612c7b stable tip

bundle-spec: properly format boolean parameter (issue6960) This was breaking automatic clone bundle generation. This changeset fixes it and add a test to catch it in the future.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Tue, 11 Mar 2025 02:29:42 +0100
parents 3e8a3db5f5e8
children
line wrap: on
line source

# mercurial/interfaces/types.py - type alias for interfaces
#
# This software may be used and distributed according to the terms of the
# GNU General Public License version 2 or any later version.
#
# This is the main entry point for Mercurial code writing type annotations.
#
# The general principle can be summarized when dealing with <FooBar> object:
# - to type your code: use FooBarT from `mercurial.interface.types`
# - to subclass <FooBar>: use IFooBar from `mercurial.interface.foo_bar`

from __future__ import annotations

from ._basetypes import (  # noqa: F401 (ignore imported but not used)
    CallbackCategoryT,
    FsPathT,
    HgPathT,
    RepoT,
    UiT,
    UserMsgT,
    VfsKeyT,
    VfsT,
)

from . import (
    matcher,
    transaction,
)

MatcherT = matcher.IMatcher
TransactionT = transaction.ITransaction