summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--git/objects/submodule/base.py5
-rw-r--r--git/types.py2
2 files changed, 2 insertions, 5 deletions
diff --git a/git/objects/submodule/base.py b/git/objects/submodule/base.py
index 6824528d..25f88b37 100644
--- a/git/objects/submodule/base.py
+++ b/git/objects/submodule/base.py
@@ -7,8 +7,6 @@ import stat
from unittest import SkipTest
import uuid
-from git import IndexFile
-
import git
from git.cmd import Git
from git.compat import (
@@ -58,6 +56,7 @@ from git.types import Commit_ish, PathLike
if TYPE_CHECKING:
from git.repo import Repo
+ from git.index import IndexFile
# -----------------------------------------------------------------------------
@@ -1012,7 +1011,7 @@ class Submodule(IndexObject, TraversableIterableObj):
return self
@unbare_repo
- def config_writer(self, index: Union[IndexFile, None] = None, write: bool = True) -> SectionConstraint:
+ def config_writer(self, index: Union['IndexFile', None] = None, write: bool = True) -> SectionConstraint:
""":return: a config writer instance allowing you to read and write the data
belonging to this submodule into the .gitmodules file.
diff --git a/git/types.py b/git/types.py
index 79f86f04..0f288e10 100644
--- a/git/types.py
+++ b/git/types.py
@@ -36,8 +36,6 @@ Commit_ish = Union['Commit', 'TagObject', 'Blob', 'Tree']
Lit_config_levels = Literal['system', 'global', 'user', 'repository']
-T = TypeVar('T', bound=Literal['system', 'global', 'user', 'repository'], covariant=True)
-
class ConfigLevels_NT(NamedTuple):
"""NamedTuple of allowed CONFIG_LEVELS"""