Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Make Cython a proper setup_requirement #24

Closed
mjpieters opened this issue Jun 16, 2017 · 0 comments
Closed

Make Cython a proper setup_requirement #24

mjpieters opened this issue Jun 16, 2017 · 0 comments

Comments

@mjpieters
Copy link

Currently, if a user doesn't have Cython installed, trying to install this package results in an error:

Collecting tsne
  Using cached tsne-0.1.7.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-9w8mswlw/tsne/setup.py", line 18, in <module>
        from Cython.Distutils import build_ext
    ImportError: No module named 'Cython'

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-9w8mswlw/tsne/

Please specify Cython in setup_requires, and leave handling compilation of .pyx files to setuptools; as of version 18.0 setuptools supports this natively:

setup(name='tsne',
      version=versioneer.get_version(),
      cmdclass=versioneer.get_cmdclass(),
      author='Daniel Rodriguez',
      author_email='df.rodriguez@gmail.com',
      url='https://github.com/danielfrg/py_tsne',
      description='TSNE implementations for python',
      license='Apache License Version 2.0, January 2004',
      packages=find_packages(),
      ext_modules=ext_modules,
      setup_requires=['cython'],
      install_requires=required
)

(dropping the Cython imports and the two lines that use those imports)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants