GithubHelp home page GithubHelp logo

Comments (14)

notatallshaw avatar notatallshaw commented on August 26, 2024 2

Python 2.7.18 is still provided as standard installation in Anaconda 3. it is weird that this does not work

Just because a software is available to download and install does not mean it is supported. Anaconda has stopped supporting Python 2.7, Python Foundation has stopped supporting Python 2.7, PyPA has stopped supporting Python 2.7, RHEL still supports Python 2.7 for the next couple of months but you must pay for that support and they don't support using pip to install libraries.

It is still possible to use 2.7, but it means you need to support it yourself, so you need to figure out how to install old packages yourself or go to help forums and ask there.

I think the main issue you're having is pip is trying to resolve packages that are too new to install into Python 2.7. This is a common problem with old Python versions, and there are lots of reasons it can't be automatically solved.

But there are workarounds, I would recommend you do this:

  1. In a separate terminal create a separate conda environment with Python 3
  2. Install pypi-timemachine in that conda environment, and read it's documentation
  3. Run pypi-timemachine set to 2019-12-31 or earlier
  4. Use pip in your Python 2 environment and point it to pypi-timemachine following the documentation
  5. Optionally, you may also need to use the legacy resolver option for pip

By doing this you won't get any newer packages than what were available on 2019-12-31, which should in general resolve your this particular issue with continuing to use Python 2.7.

Hope this helps and good luck.

from pip.

ichard26 avatar ichard26 commented on August 26, 2024 2

tables 3.5.2 which is the last release with Python 2.7 wheels depends on numexpr >= 2.6.2. In your situation (by looking at the logs), pip selects numexpr 2.8.1 which declares a build-time dependency on oldest-supported-numpy. The build step is necessary as this numexpr release has no Python 2.7 wheels.

Anyway, it looks like you'll need to use older versions of these packages. At the bare minimum, numexpr 2.7.3 is the last version to ship with Python 2.7 wheels (which won't need oldest-supported-numpy)

from pip.

pfmoore avatar pfmoore commented on August 26, 2024 1

Another approach which might have helped here (and might be of use to others hitting similar issues) is to use --only-binary :all:. This will stop pip from using anything but pre-built wheels. If everything you need still has some Python 2 compatible binary wheel available, then pip would probably be able to find them. And by not allowing builds from source, if you are missing binaries that matter, you'll get a slightly more understandable message ("could not find a version of foo that is compatible") in place of a complicated build error traceback.

from pip.

RonnyPfannschmidt avatar RonnyPfannschmidt commented on August 26, 2024

Python 2.7 is eol since years

Please try and python version under active maintenance

from pip.

matx93 avatar matx93 commented on August 26, 2024

Thanks but this is not helping unfortunately. Python 2.7.18 is still provided as standard installation in Anaconda 3. it is weird that this does not work

from pip.

pfmoore avatar pfmoore commented on August 26, 2024

You'd need to take that up with Anaconda. Pip doesn't support Python 2.7 any more.

from pip.

matx93 avatar matx93 commented on August 26, 2024

Ha! Funny. I have opened this originally in conda but devs pointed to pip!
conda/conda#13830

@pfmoore is there perhaps an earlier version of pip that I could try?

from pip.

RonnyPfannschmidt avatar RonnyPfannschmidt commented on August 26, 2024

That version is already being used,

I suspect there simply is no python 2 version of the package you asked for

from pip.

matx93 avatar matx93 commented on August 26, 2024

I was using this package on py2.7 before I had to re-build a py2.7 environment.
I suspect the cause is either upgraded pip does not work with library tables or there is some issue with dependencies

from pip.

RonnyPfannschmidt avatar RonnyPfannschmidt commented on August 26, 2024

https://pypi.org/project/oldest-supported-numpy/0.1/#data

Even the oldest version of this is python 3 only

So again stop using python 2

If anaconda still has that as a default I consider it a absolutely failure on them

from pip.

RonnyPfannschmidt avatar RonnyPfannschmidt commented on August 26, 2024

What version of python is provided if you don't explicitly pick 2.7 as you do?

from pip.

matx93 avatar matx93 commented on August 26, 2024

Although I can pick py3, I have scripts in py2 that I would like to run, and tables is the library I would need.
I understand moving to py3 is a solution, but not the one I am looking for.

The key question is: why is now tables asking for oldest-supported-numpy? this was never a requirement as this library is not supported in py2

from pip.

RonnyPfannschmidt avatar RonnyPfannschmidt commented on August 26, 2024

@matx93 because there is no python2 wheel, so pip tries to build it, and the latest version of tables (python3.9+) does not support python2

python2 has been completely eol since the start of 2020 - if you still need something in python2 to work, its completely on you to correctly pin all of the severely outdated versions of the packages you need

from pip.

matx93 avatar matx93 commented on August 26, 2024

tables 3.5.2 which is the last release with Python 2.7 wheels depends on numexpr >= 2.6.2. In your situation (by looking at the logs), pip selects numexpr 2.8.1 which declares a build-time dependency on oldest-supported-numpy. The build step is necessary as this numexpr release has no Python 2.7 wheels.

Anyway, it looks like you'll need to use older versions of these packages. At the bare minimum, numexpr 2.7.3 is the last version to ship with Python 2.7 wheels (which won't need oldest-supported-numpy)

This actually made the trick! Thank you so much!! @ichard26

from pip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.