<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Gabriele</title>
    <description>The latest articles on DEV Community by Gabriele (@gabriele_955496641624d8d4).</description>
    <link>https://dev.to/gabriele_955496641624d8d4</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3818235%2F33cdb316-80cc-4eef-84a0-b619857498da.png</url>
      <title>DEV Community: Gabriele</title>
      <link>https://dev.to/gabriele_955496641624d8d4</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/gabriele_955496641624d8d4"/>
    <language>en</language>
    <item>
      <title>Debugging a Python requests proxy issue: works in curl but fails in script</title>
      <dc:creator>Gabriele</dc:creator>
      <pubDate>Wed, 11 Mar 2026 10:00:02 +0000</pubDate>
      <link>https://dev.to/gabriele_955496641624d8d4/debugging-a-python-requests-proxy-issue-works-in-curl-but-fails-in-script-5h2k</link>
      <guid>https://dev.to/gabriele_955496641624d8d4/debugging-a-python-requests-proxy-issue-works-in-curl-but-fails-in-script-5h2k</guid>
      <description>&lt;p&gt;While debugging a Python script that sends HTTP requests through a proxy, I ran into a strange issue.&lt;/p&gt;

&lt;p&gt;The proxy works perfectly when tested with curl:&lt;/p&gt;

&lt;p&gt;curl -x &lt;a href="http://user:pass@proxy:port" rel="noopener noreferrer"&gt;http://user:pass@proxy:port&lt;/a&gt; &lt;a href="https://quantumproxies.io" rel="noopener noreferrer"&gt;https://quantumproxies.io&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This returns the correct IP, so the proxy itself is clearly working.&lt;/p&gt;

&lt;p&gt;However the equivalent Python code fails:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
python
import requests

proxy = "http://user:pass@proxy:port"

proxies = {
    "http": proxy,
    "https": proxy
}

url = "https://httpbin.org/ip"

response = requests.get(
    url,
    proxies=proxies
    timeout=10
)

print(response.json())
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>python</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
