5656T_OMD_value = TypeVar ("T_OMD_value" , str , bytes , int , float , bool )
5757
5858if sys .version_info [:3 ] < (3 , 7 , 2 ):
59- # typing.Ordereddict not added until py 3.7.2
59+ # typing.Ordereddict not added until Python 3.7.2.
6060 from collections import OrderedDict
6161
6262 OrderedDict_OMD = OrderedDict
7373log = logging .getLogger ("git.config" )
7474log .addHandler (logging .NullHandler ())
7575
76- # invariants
77- # represents the configuration level of a configuration file
78-
7976
77+ # The configuration level of a configuration file.
8078CONFIG_LEVELS : ConfigLevels_Tup = ("system" , "user" , "global" , "repository" )
8179
82-
8380# Section pattern to detect conditional includes.
8481# https://git-scm.com/docs/git-config#_conditional_includes
8582CONDITIONAL_INCLUDE_REGEXP = re .compile (r"(?<=includeIf )\"(gitdir|gitdir/i|onbranch):(.+)\"" )
@@ -603,7 +600,7 @@ def read(self) -> None: # type: ignore[override]
603600 files_to_read = [self ._file_or_files ]
604601 else : # for lists or tuples
605602 files_to_read = list (self ._file_or_files )
606- # end assure we have a copy of the paths to handle
603+ # end ensure we have a copy of the paths to handle
607604
608605 seen = set (files_to_read )
609606 num_read_include_files = 0
@@ -612,7 +609,7 @@ def read(self) -> None: # type: ignore[override]
612609 file_ok = False
613610
614611 if hasattr (file_path , "seek" ):
615- # Must be a file objectfile -object.
612+ # Must be a file-object.
616613 file_path = cast (IO [bytes ], file_path ) # TODO: Replace with assert to narrow type, once sure.
617614 self ._read (file_path , file_path .name )
618615 else :
@@ -626,7 +623,7 @@ def read(self) -> None: # type: ignore[override]
626623 continue
627624
628625 # Read includes and append those that we didn't handle yet.
629- # We expect all paths to be normalized and absolute (and will assure that is the case).
626+ # We expect all paths to be normalized and absolute (and will ensure that is the case).
630627 if self ._has_includes ():
631628 for _ , include_path in self ._included_paths ():
632629 if include_path .startswith ("~" ):
0 commit comments