title: Regex Matching Error
body: <p>I am new to Python (I dont have any programming training either), so please keep that in mind as I ask my question.</p>
  
  <p>I am trying to search a retrieved webpage and find all links using a specified pattern.  I have done this successfully in other scripts, but I am getting an error that says </p>
  
  <blockquote>
  <pre><code>raise error, v # invalid expression
  </code></pre>
    
    <p>sre_constants.error: multiple repeat</p>
  </blockquote>
  
  <p>I have to admit I do not know why, but again, I am new to Python and Regular Expressions.  However, even when I don't use patterns and use a specific link (just to test the matching), I do not believe I return any matches (nothing is sent to the window when I print match.group(0).  The link I tested is commented out below.</p>
  
  <p>Any ideas?  It usually is easier for me to learn by example, but any advice you can give is greatly appreciated!</p>
  
  <p>Brock</p>
  
  <pre><code>import urllib2
  from BeautifulSoup import BeautifulSoup
  import re
  
  url = "http://forums.epicgames.com/archive/index.php?f-356-p-164.html"
  page = urllib2.urlopen(url).read()
  soup = BeautifulSoup(page)
  
  pattern = r'&lt;a href="http://forums.epicgames.com/archive/index.php?t-([0-9]+).html"&gt;(.?+)&lt;/a&gt; &lt;i&gt;((.?+) replies)'
  #pattern = r'href="http://forums.epicgames.com/archive/index.php?t-622233.html"&gt;Gears of War 2: Horde Gameplay&lt;/a&gt; &lt;i&gt;(20 replies)'
  
  for match in re.finditer(pattern, page, re.S):
      print match(0)
  </code></pre>