Skip to content

Commit 699069e

Browse files
authored
Merge pull request #52 from pawamoy/patch-1
Use ConfigParser directly Signed-off-by: Philippe Ombredanne <pombredanne@nexb.com>
2 parents 1d0fe72 + 796af29 commit 699069e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

dparse/parser.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
from io import StringIO
88

9-
from configparser import SafeConfigParser, NoOptionError
9+
from configparser import ConfigParser, NoOptionError
1010

1111

1212
from .regex import URL_REGEX, HASH_REGEX
@@ -274,7 +274,7 @@ def parse(self):
274274
275275
:return:
276276
"""
277-
parser = SafeConfigParser()
277+
parser = ConfigParser()
278278
parser.readfp(StringIO(self.obj.content))
279279
for section in parser.sections():
280280
try:
@@ -379,7 +379,7 @@ def parse(self):
379379

380380
class SetupCfgParser(Parser):
381381
def parse(self):
382-
parser = SafeConfigParser()
382+
parser = ConfigParser()
383383
parser.readfp(StringIO(self.obj.content))
384384
for section in parser.values():
385385
if section.name == 'options':

0 commit comments

Comments
 (0)