Working with Python behind a proxy server

If you’re working behind a proxy server, you may run into some unexpected issues when configuring a work environment with Python and Eclipse. Here are some quick fixes:

Configuring the proxy server in Eclipse:

  1. Window -> Preferences -> General -> Network Settings.
  2. Set the Active Provider drop-down box to Manual.
  3. Edit the HTTP entry in the Proxy Settings list.
  4. Fill in the proxy server and port number (user name and password if necessary).
  5. And here’s MKYong’s long version, with screenshots!

 

Configuring the proxy server for other tasks, like easy_install:

Set an environmental variable:

set http_proxy=http://user:some%20long%20password@webproxy.mycompany.com:80

(The %20‘s are only needed if you happen to have spaces in your password.)