In getparams() we now check for optparse modules via optik as well. The optparse module is only available in Python 2.3, it is available as Optik in older versions. If missing the installer handles this.

This commit is contained in:
2004-01-28 21:43:59 +00:00
parent 5920bed5a7
commit 17acaed41a
2 changed files with 9 additions and 2 deletions

4
BUGS
View File

@@ -1,6 +1,8 @@
Open bugs:
- optparse only included with python 2.3. Make sure installer detects.
- Find out if a record is modifiable, otherwise return info. CNAME and A records.
Fixed bugs
- optparse only included with python 2.3. Make sure installer detects.
Solution:
from optik import OptionParser

View File

@@ -35,7 +35,12 @@ def get_ipaddress():
def getparams(msg):
# Read command line parameters and input values
from optparse import OptionParser
# OptionParser is part of Python 2.3 and called optik if installed under
# Python 2.x
try:
from optparse import OptionParser
except:
from optik import OptionParser
usage = "usage: %prog [OPTIONS]"
parser = OptionParser(usage)
parser.add_option("-c", "--config",