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:
1 parent
5920bed5a7
commit
17acaed41a
2 files changed
+9
-2
No files matched your search
@@ -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
|
||||
+6
-1
@@ -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",
|
||||
|
||||
Reference in new issue
Block a user