human-readable error messages on parser failures, not python stacktraces
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu Image |
Fix Released
|
High
|
Barry Warsaw |
Bug Description
I introduced a bug in my test gadget.yaml, and ubuntu-image told :
$ ./ubuntu-image -w workdir -d --resume
DEBUG:ubuntu-
ERROR:ubuntu-
Traceback (most recent call last):
File "/home/
return func(*args, **kws)
File "/home/
validated = GadgetYAML(yaml)
File "/usr/lib/
return self._compiled([], data)
File "/usr/lib/
return base_validate(path, iteritems(data), out)
File "/usr/lib/
raise er.MultipleInva
voluptuous.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/
step()
File "/home/
self.gadget = parse_yaml(fp)
File "/home/
raise new_exc from exception
ValueError
ERROR:ubuntu-
Traceback (most recent call last):
File "/home/
return func(*args, **kws)
File "/home/
validated = GadgetYAML(yaml)
File "/usr/lib/
return self._compiled([], data)
File "/usr/lib/
return base_validate(path, iteritems(data), out)
File "/usr/lib/
raise er.MultipleInva
voluptuous.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/
list(
File "/home/
step()
File "/home/
self.gadget = parse_yaml(fp)
File "/home/
raise new_exc from exception
ValueError
We should give the user human-readable error messages here precisely identifying the yaml syntax problem, not a page of scrolly backtrace.
Changed in ubuntu-image: | |
milestone: | none → 0.11 |
assignee: | nobody → Barry Warsaw (barry) |
importance: | Undecided → High |
Changed in ubuntu-image: | |
status: | New → In Progress |
Changed in ubuntu-image: | |
status: | In Progress → Fix Committed |
Changed in ubuntu-image: | |
status: | Fix Committed → Fix Released |
Blocked currently on upstream voluptuous bug:
https:/ /github. com/alecthomas/ voluptuous/ issues/ 239
Trying to figure out a workaround and/or fix.