summaryrefslogtreecommitdiff
path: root/git/compat.py
diff options
context:
space:
mode:
authorKostis Anagnostopoulos <ankostis@gmail.com>2016-09-28 01:47:49 +0200
committerKostis Anagnostopoulos <ankostis@gmail.com>2016-09-28 03:35:39 +0200
commitcf2335af23fb693549d6c4e72b65f97afddc5f64 (patch)
tree4198d6dd1dccc7608eccabd90367edb17f2e4b1c /git/compat.py
parenta5db3d3c49ebe559cb80983d7bb855d4adf1b887 (diff)
downloadgitpython-cf2335af23fb693549d6c4e72b65f97afddc5f64.tar.gz
Win, hook, #519: Consume Hook Popen-proc out of GIL
+ HookException thrown on Popen, and were missed on Windows. + No SHELL on Popen?? + Minor fixes: + Try harder to delete trees - no remorses. + Simplify exception reprs. + Unittest-ize test_index assertions.
Diffstat (limited to 'git/compat.py')
-rw-r--r--git/compat.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/git/compat.py b/git/compat.py
index cbfb5785..d6be6ede 100644
--- a/git/compat.py
+++ b/git/compat.py
@@ -62,7 +62,8 @@ def safe_decode(s):
return s
elif isinstance(s, bytes):
return s.decode(defenc, 'replace')
- raise TypeError('Expected bytes or text, but got %r' % (s,))
+ elif s is not None:
+ raise TypeError('Expected bytes or text, but got %r' % (s,))
def with_metaclass(meta, *bases):