Add labels for passwords, fix output of exceptions, fix passwd output.

Passwords didn't have internationalizable labels.

Exceptions that occured during required input weren't printed as unicode
so weren't being translated properly.

Don't use output_for_cli() directly in the passwd plugin, use output.Output.

ticket 352
This commit is contained in:
Rob Crittenden
2010-12-02 16:31:42 -05:00
parent 6c393e53b0
commit a41e69fba3
3 changed files with 14 additions and 9 deletions

View File

@@ -903,7 +903,7 @@ class cli(backend.Executioner):
error = None
while True:
if error is not None:
print '>>> %s: %s' % (param.label, error)
print '>>> %s: %s' % (unicode(param.label), unicode(error))
raw = self.Backend.textui.prompt(param.label, default)
try:
value = param(raw, **kw)