Response mess up when curl Django url
<pre><code>@csrf_exempt
def add_node(request, uid=None):
    resp = {
        'status': 0
    }
    return JsonResponse(resp)
</code></pre>

<p>Then I use <code>curl</code> to test it, which messed my terminal. But it works fine in browser.</p>

<p><img src="https://i.stack.imgur.com/ifQEM.png" alt="screenshot">
<img src="https://i.stack.imgur.com/vfFag.png" alt="screenshot"></p>

<p>Turns out it is because of my proxy configuration. Whenever <code>$http_proxy</code> variable is set, things go wrong.</p>

python django curl