title: BeautifulSoup: "TypeError: 'str' object is not callable" when using .h1.text()
body: <p>EDIT - this a concurrent futures issue, not a BS4 issue. Concurrent futures was returning an empty list after retrieving data - which resulted in the NoneType error from BS4.</p>
  <p>I'm attempting to scrape H1s from a list of URLs using Beautiful Soup, but getting the error <code>TypeError: 'str' object is not callable</code> on one of the URLs.</p>
  <p>If I print the output, I can see I have retrieved 3 of the h1's before the error.</p>
  <p>If I remove <code>.h1.text.strip()</code> I get a different error, although curiously it prints the html 4 times not 3.</p>
  <p>e.g. I changed <code>bsh_h1 = bsh.h1.text.strip()</code> to <code>bsh_h1 = bsh</code> and it ran four times instead and produced the error: <code>TypeError: unhashable type: 'ResultSet'</code></p>
  <p>I've tried placing try / except block but it seems to product errors elsewhere in the code, so feel I'm  missing something fundamental. Maybe BS4 is returning NoneType and I need to skip it?</p>
  <p>Here's my code.</p>
  <pre><code>import concurrent.futures
  from bs4 import BeautifulSoup
  from urllib.request import urlopen
  
  CONNECTIONS = 1
  
  archive_url_list = [
      &quot;https://web.archive.org/web/20171220015929/http://www.manueldrivingschool.co.uk:80/prices.php&quot;,
      &quot;https://web.archive.org/web/20160313085709/http://www.manueldrivingschool.co.uk/lessons_prices.php&quot;,
      &quot;https://web.archive.org/web/20171220002420/http://www.manueldrivingschool.co.uk:80/prices&quot;,
      &quot;https://web.archive.org/web/20201202094502/https://www.manueldrivingschool.co.uk/success&quot;,
  ]
  
  archive_h1_list = []
  def get_archive_h1(h1_url):
      html = urlopen(h1_url)
      bsh = BeautifulSoup(html.read(), 'lxml')
      bsh = bsh.h1.text.strip()
      return bsh.h1.text.strip()
  
  def concurrent_calls():
      with concurrent.futures.ThreadPoolExecutor(max_workers=CONNECTIONS) as executor:
          f1 = executor.map(get_archive_h1, archive_url_list)
          for future in concurrent.futures.as_completed(f1):
              try:
                  data = future.result()
                  archive_h1_list.append(data)
              except Exception:
                  archive_h1_list.append(&quot;No Data Received!&quot;)
                  pass
  
  if __name__ == '__main__':
      concurrent_calls()
      print(archive_h1_list)
  </code></pre>
  <p>PS: I'm using concurrent futures for multithreading. I initially thought that was the issue, but I'm leaning towards BS4 now..</p>