diff options
author | x-santiaga-x <santa4github@yandex.ru> | 2021-01-28 14:16:53 +0300 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2021-01-28 23:37:53 +0800 |
commit | 3c19a6e1004bb8c116bfc7823477118490a2eef6 (patch) | |
tree | 24e8c83e79410a8a46d0fe7fb8c336060cf3efe3 | |
parent | 4a1339a3d6751b2e7c125aa3195bdc872d45a887 (diff) | |
download | gitpython-3c19a6e1004bb8c116bfc7823477118490a2eef6.tar.gz |
fix universal_newlines TypeError
Fixes #1116
-rw-r--r-- | git/cmd.py | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -785,7 +785,9 @@ class Git(LazyMixin): watchdog.cancel() if kill_check.isSet(): stderr_value = ('Timeout: the command "%s" did not complete in %d ' - 'secs.' % (" ".join(command), kill_after_timeout)).encode(defenc) + 'secs.' % (" ".join(command), kill_after_timeout)) + if not universal_newlines: + stderr_value = stderr_value.encode(defenc) # strip trailing "\n" if stdout_value.endswith(newline): stdout_value = stdout_value[:-1] |