How can I see if a child exists in Python?
<p>I have an <code>lxml</code> object called <code>item</code> and it may have a child called <code>item.brand</code>, however it's possible that there is none as this is returned from an API. How can I check this in Python?</p>
