Python: prevent %s substitution on a string
<p>Is there a way to mark a string such that it will not trigger python's % string substitution?</p>

<p>In particular, I'm attempting to download a file whose name includes a % using the python <code>sftp</code> module. The sftp module attempts to log the name of the file using the logging module:</p>

<pre><code>self.logger.log(level, msg, *args)
</code></pre>

<p>and <code>logging</code> complains about string formatting because of the % signs:</p>

<pre><code>  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/logging/__init__.py", line 328, in getMessage
    msg = msg % self.args
TypeError: not enough arguments for format string
</code></pre>

<p>So: since I don't control the filename nor the sftp module, can I mark the filename as not participating in string substitution? </p>
