title: Why does comparing strings using either '==' or 'is' sometimes produce a different result?
body: <p>Two string variables are set to the same value. <code>s1 == s2</code> always returns <code>True</code>, but <code>s1 is s2</code> sometimes returns <code>False</code>.</p>
  <p>If I open my Python interpreter and do the same <code>is</code> comparison, it succeeds:</p>
  <pre><code>&gt;&gt;&gt; s1 = 'text'
  &gt;&gt;&gt; s2 = 'text'
  &gt;&gt;&gt; s1 is s2
  True
  </code></pre>
  <p>Why is this?</p>