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:
Luong Anh Tuan 2016-11-28 09:07:14 +07:00 committed by Tuan Luong-Anh
parent eedae5b0d4
commit c70c1dc36e
1 changed files with 4 additions and 2 deletions

View File

@ -128,7 +128,9 @@ class SupportMatrixDirective(rst.Directive):
:returns: SupportMatrix instance
"""
if six.PY3:
cfg = configparser.ConfigParser()
else:
cfg = configparser.SafeConfigParser()
env = self.state.document.settings.env
fname = self.arguments[0]