Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


FTP download install failed #1532

lucmult opened this Issue · 12 comments

6 participants

lucmult Simon Kennedy Piotr Dobrogost Donald Stufft Paul Moore Marcus Smith
(venv)ubuntu@box31:~/bex$ pip install
Cleaning up...
Traceback (most recent call last):
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/", line 122, in main
    status =, args)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/commands/", line 274, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/", line 1173, in prepare_files
    self.unpack_url(url, location, self.is_download)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/", line 1320, in unpack_url
    retval = unpack_http_url(link, location, self.download_cache, self.download_dir, self.session)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/", line 555, in unpack_http_url
    resp = session.get(target_url, stream=True)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/_vendor/requests/", line 395, in get
    return self.request('GET', url, **kwargs)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/", line 237, in request
    return super(PipSession, self).request(method, url, *args, **kwargs)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/_vendor/requests/", line 383, in request
    resp = self.send(prep, **send_kwargs)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/_vendor/requests/", line 481, in send
    adapter = self.get_adapter(url=request.url)
  File "/home/ubuntu/bex/venv/local/lib/python2.7/site-packages/pip/_vendor/requests/", line 526, in get_adapter
    raise InvalidSchema("No connection adapters were found for '%s'" % url)
InvalidSchema: No connection adapters were found for ''

Storing debug log for failure in /home/ubuntu/.pip/pip.log

pip --version

pip 1.5.2 from /home/ubuntu/bex/venv/local/lib/python2.7/site-packages (python 2.7)

I tried the same file using the master HEAD and got the same issue.


It works with pip 1.4.1


Ok, using git bisect I found this commit introduced the issue:

I'm running the test like:

python pip/ install
Simon Kennedy

The looks like it's the result of switching from using the urllib2 library (CacheFTPHandler) to the Requests library which does not provide an FTP Adapter. Until that is available you'll have this problem.

Piotr Dobrogost

@lucmult You can edit your comments – no need to put each update on it's own :)

Donald Stufft

Hmm, yes this was a result of the switch to requests. However I'm not sure we should continue to support use of ftp urls either way. As far as I'm aware ftp servers to not generally support TLS and without that we lose the ability to securely fetch files from these servers.

Donald Stufft

Any thoughts @qwcode and @pfmoore ?

Paul Moore

Personally, I have no need for ftp. The OP's use case is real, though - does only distribute libxml2-python over ftp. But that is a very old version - it's from 2004 as far as I can see.

So I don't have any strong objection to simply documenting that ftp support was discontinued with the move to requests. But if people come up with other genuine use cases, we should be prepared to reconsider (I have had ISPs in the past who only supported ftp hosting, and I can imagine having waned to host packages there)


I found an alternative HTTP link for this package:

HTTP isn't secure either ;-)

Donald Stufft

Nope! It's not. But HTTPS is and pip is discouraging the use of HTTP instead of HTTPS :)


@dstufft many hosts out there don't support HTTPS. In fact, this libxml example doesn't support HTTPS.

I agree with @pfmoore suggestion to "fix" this issue by documenting it.

Marcus Smith qwcode added the docs label
Donald Stufft dstufft added this to the 1.6 milestone
Donald Stufft dstufft closed this in #2133
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.