Why can't I send `None` as data in a POST request using Python's `requests` library?
<p>It seems that when a key in <code>data</code> has a value of <code>None</code>, the key isn't included by requests.</p>

<pre><code>&gt;&gt;&gt; req = requests.Request('POST', 'http://google.com', data=dict(a=None, b=1))
&gt;&gt;&gt; req.prepare().body
'b=1'
</code></pre>

<p>Why is this the case? I was expecting an empty string, or something like <code>json.dumps(d)</code> where <code>None</code> is rendered as <code>null</code>. I'm sure there's a good reason -- just curious about what it is. (One thing I can think of is that maybe there just isn't an encoding of <code>null</code> or <code>None</code> available to the POST request -- is that true?)</p>

<p>Additionally curious -- why does <code>requests</code> silently ignore such data instead of throwing an error?</p>