From 37cef2340d3e074a226c0e81eaf000b5b90dfa55 Mon Sep 17 00:00:00 2001 From: yobmod Date: Sat, 8 May 2021 18:31:38 +0100 Subject: flake8 fixes --- git/config.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'git/config.py') diff --git a/git/config.py b/git/config.py index 0c8d975d..ea7302f4 100644 --- a/git/config.py +++ b/git/config.py @@ -22,13 +22,23 @@ from git.compat import ( with_metaclass, is_win, ) -from git.compat.typing import Literal + from git.util import LockFile import os.path as osp import configparser as cp +# typing------------------------------------------------------- + +from typing import TYPE_CHECKING, Tuple + +from git.types import Literal + +if TYPE_CHECKING: + pass + +# ------------------------------------------------------------- __all__ = ('GitConfigParser', 'SectionConstraint') @@ -38,7 +48,8 @@ log.addHandler(logging.NullHandler()) # invariants # represents the configuration level of a configuration file -CONFIG_LEVELS = ("system", "user", "global", "repository") +CONFIG_LEVELS = ("system", "user", "global", "repository" + ) # type: Tuple[Literal['system'], Literal['user'], Literal['global'], Literal['repository']] # Section pattern to detect conditional includes. # https://git-scm.com/docs/git-config#_conditional_includes -- cgit v1.2.1