Kozea / cairocffi

CFFI-based cairo bindings for Python.
https://doc.courtbouillon.org/cairocffi
BSD 3-Clause "New" or "Revised" License
208 stars 54 forks source link

Python 3.6 tests failing #185

Closed vrusinov closed 3 years ago

vrusinov commented 3 years ago

All tests on 3.6 are currently failing (and I suspect fresh pip installs may be broken too?) due to numpy dropping Python 3.6 support in v1.20.0.

Test logs (e.g. from pull #184 ):

Traceback (most recent call last):
  File "setup.py", line 13, in <module>
    'cairocffi/ffi_build.py:ffi_pixbuf']
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/__init__.py", line 143, in setup
    return distutils.core.setup(**attrs)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/ptr.py", line 202, in run
    installed_dists = self.install_dists(dist)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/ptr.py", line 153, in install_dists
    orig.test.install_dists(dist), self.install_extra_dists(dist)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/test.py", line 208, in install_dists
    tr_d = dist.fetch_build_eggs(dist.tests_require or [])
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/dist.py", line 586, in fetch_build_eggs
    replace_conflicting=True,
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/pkg_resources/__init__.py", line 780, in resolve
    replace_conflicting=replace_conflicting
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/pkg_resources/__init__.py", line 1063, in best_match
    return self.obtain(req, installer)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/pkg_resources/__init__.py", line 1075, in obtain
    return installer(requirement)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/ptr.py", line 84, in fetch_build_egg
    return cmd.easy_install(req)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 679, in easy_install
    return self.install_item(spec, dist.location, tmpdir, deps)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 705, in install_item
    dists = self.install_eggs(spec, download, tmpdir)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 890, in install_eggs
    return self.build_and_install(setup_script, setup_base)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 1158, in build_and_install
    self.run_setup(setup_script, setup_base, args)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 1144, in run_setup
    run_setup(setup_script, args)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 253, in run_setup
    raise
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/contextlib.py", line 99, in __exit__
    self.gen.throw(type, value, traceback)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 195, in setup_context
    yield
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/contextlib.py", line 99, in __exit__
    self.gen.throw(type, value, traceback)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 166, in save_modules
    saved_exc.resume()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 141, in resume
    six.reraise(type, exc, self._tb)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/_vendor/six.py", line 685, in reraise
    raise value.with_traceback(tb)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 154, in save_modules
    yield saved
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 195, in setup_context
    yield
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 250, in run_setup
    _execfile(setup_script, ns)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/site-packages/setuptools/sandbox.py", line 45, in _execfile
    exec(code, globals, locals)
  File "/tmp/easy_install-30jeuh_m/numpy-1.20.2/setup.py", line 30, in <module>
RuntimeError: Python version >= 3.7 required.
Error: Process completed with exit code 1.

Numpy 3.6 support drop: https://github.com/numpy/numpy/releases/tag/v1.20.0

Perhaps it's time to drop 3.6 support here too? It feels unnecessary to require numpy <1.20.0 due to this. Python 3.6 will be supported until 2021-12 though. I dunno if there's an easy way to change requirements based on python version in setup.cfg.

liZe commented 3 years ago

Thanks a lot for the bug report, we’ve dropped official Python 3.6 support.