title: lookbehind for start of string or a character
body: <p>The command</p>
  
  <pre><code>re.compile(ur"(?&lt;=,| |^)(?:next to|near|beside|opp).+?(?=,|$)", re.IGNORECASE)
  </code></pre>
  
  <p>throws a</p>
  
  <p><code>sre_constants.error: look-behind requires fixed-width pattern</code></p>
  
  <p>error in my program but <a href="https://regex101.com/" rel="noreferrer">regex101</a> shows it to be fine.</p>
  
  <p>What I'm trying to do here is to match landmarks from addresses (each address is in a separate string) like:</p>
  
  <ul>
  <li>"Opp foobar, foocity" --> Must match "Opp foobar"</li>
  <li>"Fooplace, near barplace, barcity" --> Must match "near barplace"</li>
  <li>"Fooplace, Shoppers Stop, foocity"--> Must match nothing</li>
  <li>"Fooplace, opp barplace"--> Must match "opp barplace"</li>
  </ul>
  
  <p>The lookbehind is to avoid matching words with <code>opp</code> in them (like in string 3).</p>
  
  <p>Why is that error thrown? Is there an alternative to what I'm looking for?</p>