SpecificationTreeGraphView.renderGraphvizGraph() can fail without properly logging errors and warnings from subprocess
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Triaged
|
High
|
Unassigned |
Bug Description
Running "./bin/test blueprints -vv" in noticed failures in these doc tests
lib/lp/
lib/lp/
lib/lp/
The errors were not very enlightening; trying to access http://
A bit of debugging showed that SpecificationTr
def renderGraphvizG
"""Return graph data in the appropriate format.
Shell out to `dot` to do the work.
Raise ProblemRenderin
"""
assert format in ('png', 'cmapx')
input = self.getDotFile
# XXX sinzui 2008-04-03 bug=211568:
# This use of subprocess.Popen is far from ideal. There is extra
# risk of getting an OSError, or an command line issue that we
# represent as a ProblemRenderin
# to make the PNG/cmapx.
cmd = 'unflatten -l 2 | dot -T%s' % format
process = Popen(
cmd, shell=True, stdin=PIPE, stdout=PIPE, stderr=PIPE,
output = process.
err = process.
if err:
raise ProblemRenderin
We should at least log the content of err, if only to make debugging of real problems easier. Also, it might make sense to check if output contains anything that could be an image.And to raise an error only when this is not the case.
The fix of the failures in my case just required a small change of /etc/fonts/
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- Load per-user customization file -->
<include ignore_
<include ignore_
<!-- the following elements will be removed in the future -->
<include ignore_
<include ignore_
</fontconfig>
I just had to remove 'deprecated="yes"'
Changed in launchpad: | |
status: | New → Triaged |
importance: | Undecided → Critical |
importance: | Critical → High |
tags: | added: lp-blueprints specifications |
tags: | added: tech-debt |