title: BeautifulSoup parent tag
body: <p>I have some html that I want to extract text from. Here's an example of the html:</p>
  
  <pre><code>&lt;p&gt;TEXT I WANT &lt;i&gt; &amp;#8211; &lt;/i&gt;&lt;/p&gt;
  </code></pre>
  
  <p>Now, there are, obviously, lots of <code>&lt;p&gt;</code> tags in this document. So, <code>find('p')</code> is not a good way to get at the text I want to extract. However, that <code>&lt;i&gt;</code> tag is the only one in the document. So, I thought I could just find the <code>&lt;i&gt;</code> and then go to the parent.</p>
  
  <p>I've tried:</p>
  
  <pre><code>up = soup.select('p i').parent
  </code></pre>
  
  <p>and     </p>
  
  <pre><code>up = soup.select('i')
  print(up.parent)
  </code></pre>
  
  <p>and I've tried it with <code>.parents</code>, I've tried <code>find_all('i')</code>, <code>find('i')</code>... But I always get:</p>
  
  <pre><code>'list' object has no attribute "parent"
  </code></pre>
  
  <p>What am I doing wrong?</p>