We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1f66e25 commit 3953d71Copy full SHA for 3953d71
git/compat.py
@@ -30,7 +30,10 @@
30
is_win = (os.name == 'nt')
31
is_posix = (os.name == 'posix')
32
is_darwin = (os.name == 'darwin')
33
-defenc = sys.getdefaultencoding()
+if hasattr(sys, 'getfilesystemencoding'):
34
+ defenc = sys.getfilesystemencoding()
35
+if defenc is None:
36
+ defenc = sys.getdefaultencoding()
37
38
if PY3:
39
import io
git/repo/base.py
@@ -4,6 +4,7 @@
4
# This module is part of GitPython and is released under
5
# the BSD License: http://www.opensource.org/licenses/bsd-license.php
6
7
+from builtins import str
8
from collections import namedtuple
9
import logging
10
import os
0 commit comments