title: Replace single quotes (') with double quotes (") except apostrophe
body: <p>I have a dataset with invalid json, see snippet below:</p>
  
  <pre><code>{'id': 613, 'name': "new year's eve"}
  </code></pre>
  
  <p>I want to replace all the single quotes except apostrophes like in: new <strong>year's</strong>. So the string above should result in valid json like: </p>
  
  <pre><code>{"id": 613, "name": "new year's eve"}
  </code></pre>
  
  <p>I have tried a simple string replace in Python: <strong>string.replace("'", "\"")</strong>, but this also changes the apostrophe resulting in:</p>
  
  <pre><code>{"id": 613, "name": "new year"s eve"}
  </code></pre>
  
  <p>Is there a way to fix this with regex, like <strong>replace all ' except when encapsulated by "</strong>?</p>