title: python regex: to match space character or end of string
body: <p>I want to match space chars or end of string in a text.</p>
  
  <pre><code>import re
  
  
  uname='abc'
  assert re.findall('@%s\s*$' % uname, '@'+uname)
  assert re.findall('@%s\s*$' % uname, '@'+uname+'  '+'aa')
  assert not re.findall('@%s\s*$' % uname, '@'+uname+'aa')
  </code></pre>
  
  <p>The pattern is not right.<br>
  How to use python?</p>