--version causes type error
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
VMBuilder |
Confirmed
|
Medium
|
Unassigned | ||
vm-builder (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Expected result: a version number
Actual result:
root@rock:
Traceback (most recent call last):
File "/usr/bin/
cli.main()
File "/usr/lib/
(dummy, args) = optparser.
File "/usr/lib/
stop = self._process_
File "/usr/lib/
self.
File "/usr/lib/
option.
File "/usr/lib/
self.action, self.dest, opt, value, values, parser)
File "/usr/lib/
self.
File "/usr/lib/
VMBuilder.
TypeError: %d format: a number is required, not str
Using:
Ubuntu 12.04 server
Just did apt-get update && apt-get upgrade
This seems to have been broken for quite some time.
Simplist fix is to just remove 'revno' from the output message:
=== modified file 'VMBuilder/ contrib/ cli.py' contrib/ cli.py 2011-10-27 20:01:00 +0000 contrib/ cli.py 2012-05-24 13:13:29 +0000
optparser .add_option_ group(optgroup)
--- VMBuilder/
+++ VMBuilder/
@@ -277,7 +277,7 @@
def versioninfo(self, option, opt, value, parser): d.%(minor) d.%(micro) s.r%(revno) d' % d.%(minor) d.%(micro) s' %
VMBuilder. get_version_ info())
sys.exit( 0)
- print ('%(major)
+ print ('%(major)