1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

python 3 compatibility: import guard around ConfigParser

In python3 `ConfigParser` has become `configparser`. Added
an import guard that aliases it back to the old name.
This commit is contained in:
James Elford 2017-05-29 15:47:45 +01:00 committed by Toshio Kuratomi
parent 53c46df323
commit bc9dbf38b0

View file

@ -138,9 +138,13 @@ import sys
import re
import argparse
from time import time
import ConfigParser
import ast
try:
import ConfigParser
except ImportError:
import configparser as ConfigParser
try:
import json
except ImportError: