Use ConfigParser instead of SafeConfigParser in Python 3
The SafeConfigParser class has been renamed to ConfigParser in Python 3.2 [1]. The alias SafeConfigParser maybe removed in future versions of Python 3. Use ConfigParser instead of SafeConfigParser in Python 3 [1] http://bugs.python.org/issue10627 Change-Id: I1403de0ccc554472333d6fa0fbb55cdc31dce05f Closes-Bug: #1618666
This commit is contained in:
parent
eedae5b0d4
commit
c70c1dc36e
|
@ -128,8 +128,10 @@ class SupportMatrixDirective(rst.Directive):
|
||||||
|
|
||||||
:returns: SupportMatrix instance
|
:returns: SupportMatrix instance
|
||||||
"""
|
"""
|
||||||
|
if six.PY3:
|
||||||
cfg = configparser.SafeConfigParser()
|
cfg = configparser.ConfigParser()
|
||||||
|
else:
|
||||||
|
cfg = configparser.SafeConfigParser()
|
||||||
env = self.state.document.settings.env
|
env = self.state.document.settings.env
|
||||||
fname = self.arguments[0]
|
fname = self.arguments[0]
|
||||||
rel_fpath, fpath = env.relfn2path(fname)
|
rel_fpath, fpath = env.relfn2path(fname)
|
||||||
|
|
Loading…
Reference in New Issue