title: Python: Splitting a path string containing double quotes
body: <p>I am using a file containing brackets in Windows, which requires quotes in external processes.</p>
  
  <p>I am trying to manipulate the location, but as the string is being passed with the quotes, when I use os.path.split, the double quotes are also being split.  Is there a better way to do this so that I don't need to do checks on the input string and strip and/or replace the double quotes?  I will be joining the filename to a new path that doesn't have double quotes.</p>
  
  <pre><code>fileWithPath = r'"C:\TEMP\my(file).txt"'
  ... do some stuff ...
  sourcepath, filename = os.path.split(fileWithPath)
  </code></pre>
  
  <p>sourcepath has value: '"C:\TEMP'</p>
  
  <p>filename has value: 'my(file).txt"'</p>