Browse Source

Merge pull request #1176 from progval/stricter-type

Define a stricter return type for _parse_message
Jelmer Vernooij 1 year ago
parent
commit
24a5b3ad3f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      dulwich/objects.py

+ 1 - 1
dulwich/objects.py

@@ -651,7 +651,7 @@ class Blob(ShaFile):
         return ret
 
 
-def _parse_message(chunks: Iterable[bytes]) -> Iterator[Tuple[Optional[bytes], Optional[bytes]]]:
+def _parse_message(chunks: Iterable[bytes]) -> Iterator[Union[Tuple[None, None], Tuple[Optional[bytes], bytes]]]:
     """Parse a message with a list of fields and a body.
 
     Args: