Bug #76063 pypi package missing
Submitted: 26 Feb 2015 12:14 Modified: 25 Mar 2022 17:57
Reporter: Thomas Grainger Email Updates:
Status: Closed Impact on me:
None 
Category:Connector / Python Severity:S3 (Non-critical)
Version: OS:Any
Assigned to: CPU Architecture:Any

[26 Feb 2015 12:14] Thomas Grainger
Description:
The pypi packages hosted for mysql-connector-python is missing any uploaded packages.

pip consideres "externally hosted files" deprecated and it's recommended to avoid them.

How to repeat:
$ pip install mysql-connector-python
Downloading/unpacking mysql-connector-python
  Could not find any downloads that satisfy the requirement mysql-connector-python
  Some externally hosted files were ignored (use --allow-external mysql-connector-python to allow).
Cleaning up...
No distributions at all found for mysql-connector-python
Storing debug log for failure in /home/graingert/.pip/pip.log

Suggested fix:
wget https://cdn.mysql.com/Downloads/Connector-Python/mysql-connector-python-2.0.3.zip
unzip mysql-connector-python-2.0.3.zip
cd mysql-connector-python-2.0.3
python setup.py sdist register upload
[27 Feb 2015 12:57] MySQL Verification Team
Hello Thomas Grainger,

Thank you for the report.
Observed similar behavior on OL6.

Thanks,
Umesh
[27 Feb 2015 12:59] MySQL Verification Team
//

[root@cluster-repo 75755]# yum -y install python-pip
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package python-pip.noarch 0:1.3.1-4.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

==================================================================================================================================================================================================
 Package                                          Arch                                         Version                                           Repository                                  Size
==================================================================================================================================================================================================
Installing:
 python-pip                                       noarch                                       1.3.1-4.el6                                       epel                                       330 k

Transaction Summary
==================================================================================================================================================================================================
Install       1 Package(s)

Total download size: 330 k
Installed size: 1.0 M
Downloading Packages:
python-pip-1.3.1-4.el6.noarch.rpm                                                                                                                                          | 330 kB     00:01 ...
warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Importing GPG key 0x0608B895:
 Userid : EPEL (6) <epel@fedoraproject.org>
 Package: epel-release-6-8.noarch (installed)
 From   : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : python-pip-1.3.1-4.el6.noarch                                                                                                                                                  1/1
  Verifying  : python-pip-1.3.1-4.el6.noarch                                                                                                                                                  1/1

Installed:
  python-pip.noarch 0:1.3.1-4.el6

Complete!

//
[root@cluster-repo tmp]# pip install mysql-connector-pythonls
Downloading/unpacking mysql-connector-pythonls
  Cannot fetch index base URL https://pypi.python.org/simple/
  Could not find any downloads that satisfy the requirement mysql-connector-pythonls
No distributions at all found for mysql-connector-pythonls
Storing complete log in /root/.pip/pip.log

//

[root@cluster-repo tmp]# more /root/.pip/pip.log
Downloading/unpacking mysql-connector-pythonls

  Getting page https://pypi.python.org/simple/mysql-connector-pythonls/
  Could not fetch URL https://pypi.python.org/simple/mysql-connector-pythonls/: <urlopen error [Errno 113] No route to host>
  Will skip URL https://pypi.python.org/simple/mysql-connector-pythonls/ when looking for download links for mysql-connector-pythonls
  Getting page https://pypi.python.org/simple/
  Could not fetch URL https://pypi.python.org/simple/: timed out
  Will skip URL https://pypi.python.org/simple/ when looking for download links for mysql-connector-pythonls
  Cannot fetch index base URL https://pypi.python.org/simple/

  URLs to search for versions for mysql-connector-pythonls:
  * https://pypi.python.org/simple/mysql-connector-pythonls/
  Getting page https://pypi.python.org/simple/mysql-connector-pythonls/
  Could not fetch URL https://pypi.python.org/simple/mysql-connector-pythonls/: <urlopen error [Errno 113] No route to host>
  Will skip URL https://pypi.python.org/simple/mysql-connector-pythonls/ when looking for download links for mysql-connector-pythonls
  Could not find any downloads that satisfy the requirement mysql-connector-pythonls

No distributions at all found for mysql-connector-pythonls

Exception information:
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pip/basecommand.py", line 139, in main
    status = self.run(options, args)
  File "/usr/lib/python2.6/site-packages/pip/commands/install.py", line 266, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/usr/lib/python2.6/site-packages/pip/req.py", line 1026, in prepare_files
    url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
  File "/usr/lib/python2.6/site-packages/pip/index.py", line 171, in find_requirement
    raise DistributionNotFound('No distributions at all found for %s' % req)
DistributionNotFound: No distributions at all found for mysql-connector-pythonls
[2 Mar 2015 10:12] Geert Vanderkelen
Hello, thanks for your bug report and yes, we know how to upload to pypi.
We will do it whenever we can. For now, externally hosted is the only way.
[2 Mar 2015 10:57] Thomas Grainger
typo
[11 Jan 2016 17:42] Chris Lasher
pip is no longer able to download mysql-python-connector. To resolve this issue, package maintainers should refer to the information contained in following URLs:

https://www.python.org/dev/peps/pep-0438/#api-for-submitting-external-distribution-urls

http://stackoverflow.com/questions/19690971/registering-a-package-to-pypi-with-an-external...
[15 Jan 2016 0:11] Ben Jolitz
PyPi no longer will show download URIs and is in the process of removing them from existing entries.

https://pypi.python.org/simple/mysql-connector-python/ is already empty.

There is now no way to install mysql-connector-python using package managers.

Oracle is urged to either set up a PyPi index of their own so that users can use '--extra-index-url' to point their pip's at Oracle to install MySQL/connector-Python or upload the package to PyPi using 'sdist and bdist_wheel' commands in setup.py
[5 Mar 2016 3:01] Jimmy Schementi
Installing mysql-connector-python through pip no longer works:

❯ pip --version
pip 8.0.3 from /Users/jimmy/src/mysqlpiptest/env/lib/python2.7/site-packages (python 2.7)

❯ python --version
Python 2.7.10

❯ pip install mysql-connector-python --allow-external mysql-connector-python
DEPRECATION: --allow-external has been deprecated and will be removed in the future. Due to changes in the repository protocol, it no longer has any effect.
Collecting mysql-connector-python
  Could not find a version that satisfies the requirement mysql-connector-python (from versions: )
No matching distribution found for mysql-connector-python
[1 Aug 2016 14:39] Ed Morley
Please can someone take a look at this?

For the Python ecosystem PyPI is the recommended means of obtaining packages, and the package there is still v2.0.4 (ie bug 78982), as well as externally hosted - so longer possible to download using pip.
[2 Aug 2016 9:49] Thomas Grainger
So it turns out Oracle is actually being reasonable, if a little silent on the issue.

The terms of use at https://www.python.org/about/legal/ provide in pertinent part as follows:

"third party content providers grant the PSF and all other users of the web site an irrevocable, worldwide, royalty-free, nonexclusive license to reproduce, distribute, transmit, display, perform, and publish such content, including in digital form"

Unfortunately this does not say the PSF and its users are getting a license under the GPL. e.g., the GPL is not an irrevocable license - it contains an express termination provision that is invoked if you do not comply with its terms). If content providers are bound by those terms to begin with, for someone to upload GPLed content under that license probably either means they are violating the GPL (e.g., if someone else uploaded Oracle's GPL licensed content), or, if they are the sole copyright holder, they are granting the PSF and all its users a different license than the GPL to that material. That doesn't work for the obvious reasons.

https://github.com/PyMySQL/mysqlclient-python/issues/44#issuecomment-236719294
[11 Oct 2018 10:52] MySQL Verification Team
Bug #80208 marked as duplicate of this one
[25 Mar 2022 17:57] Javier Treviño
As for 8.0.5 mysql-connector-python is officially available on PyPI.