follow-recommends throws an attribute error when passed None
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
germinate (Ubuntu) |
Fix Released
|
High
|
Colin Watson |
Bug Description
I'm running germinate from trunk, revision 461, and I get the following exception when running the command:
# /tmp/oneiric-
Traceback (most recent call last):
File "/tmp/oneiric-
main()
File "/tmp/oneiric-
g.reverse_
File "/tmp/oneiric-
if (self._
File "/tmp/oneiric-
if "follow-recommends" in seed.structure.
AttributeError: 'NoneType' object has no attribute 'structure'
The problem seems to be with the following method in the Germinator class:
def _follow_
"""Test whether we should follow Recommends for this seed."""
if seed is not None:
if "follow-recommends" in seed._features:
if "no-follow-
if "follow-recommends" in seed.structure.
return True
return False
When passed None, the last conditional statement throws the exception.
I was unable to reproduce this using the packaged version of germinate so I'll move the bug to the germinate project.