Bug #3619

conda install does not install latest version

Added by Knödlseder Jürgen almost 3 years ago. Updated almost 3 years ago.

Status:ClosedStart date:04/26/2021
Priority:UrgentDue date:
Assigned To:Knödlseder Jürgen% Done:

100%

Category:-
Target version:-
Duration:

Description

When trying to install ctools using conda in a Python 2.7 environment it fetches an old ctools version (1.6.1):

$ conda create -n myenv python=2.7
$ conda activate myenv
$ conda install ctools 
The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    bzip2-1.0.8                |       h1de35cc_0          75 KB
    cfitsio-3.470              |       hee0f690_6         782 KB
    ctools-1.6.1               |   py27hc094b50_1         7.2 MB  cta-observatory
    gammalib-1.6.1             |   py27h8ba401d_1        25.7 MB  cta-observatory
    openssl-1.1.1k             |       h9ed2024_0         2.2 MB
    python-2.7.15              |    h932b40d_1008        12.1 MB  conda-forge
    ------------------------------------------------------------
                                           Total:        48.1 MB
$ conda activate myenv
(myenv) macp0135:~ jurgen$ python -c 'import ctools; ctools.test()'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/ctools/__init__.py", line 21, in <module>
    import gammalib
  File "/Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/gammalib/__init__.py", line 21, in <module>
    from gammalib.app import *
  File "/Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/gammalib/app.py", line 28, in <module>
    _app = swig_import_helper()
  File "/Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/gammalib/app.py", line 24, in swig_import_helper
    _mod = imp.load_module('_app', fp, pathname, description)
ImportError: dlopen(/Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/gammalib/_app.so, 2): Library not loaded: @rpath/libcfitsio.5.dylib
  Referenced from: /Users/jurgen/anaconda3/envs/myenv/lib/python2.7/site-packages/gammalib/_app.so
  Reason: image not found


Recurrence

No recurrence.


Related issues

Related to GammaLib - Bug #2958: Correct cfitsio library dependency Closed 07/15/2019

History

#1 Updated by Knödlseder Jürgen almost 3 years ago

  • Status changed from New to In Progress
  • % Done changed from 0 to 10

Changing the order of the channels by specifying the channel with --add does not solve the issue:

$ conda config --remove channels conda-forge
$ conda config --remove channels cta-observatory
$ conda config --add channels conda-forge
$ conda config --add channels cta-observatory

This issue seems to be described here: https://github.com/conda/conda/issues/2011.

#2 Updated by Knödlseder Jürgen almost 3 years ago

  • % Done changed from 10 to 20

Issue also described here: https://stackoverflow.com/questions/60973724/why-does-conda-not-install-the-most-recent-version-of-spyder-from-conda-forge. I’m wondering where the only solution is to remove ctools 1.6.1 (and probably older) from Anaconda.

#3 Updated by Knödlseder Jürgen almost 3 years ago

  • Related to Bug #2958: Correct cfitsio library dependency added

#4 Updated by Knödlseder Jürgen almost 3 years ago

Knödlseder Jürgen wrote:

I’m wondering where the only solution is to remove ctools 1.6.1 (and probably older) from Anaconda.

An alternative would be to build the old GammaLib packages again with the cfitsio version fixed, which includes
  • 1.4.3
  • 1.5.0
  • 1.5.1
  • 1.5.2
  • 1.5.3
  • 1.5.4
  • 1.6.0
  • 1.6.1

#5 Updated by Knödlseder Jürgen almost 3 years ago

This approach works as uploading a new package 1.6.1 with the cfitsio version fixed to 3.430 bumps the problem down to gammalib version 1.6.0. I will continue with that strategy.

#6 Updated by Knödlseder Jürgen almost 3 years ago

  • % Done changed from 20 to 30

I also needed to fix the conda readline version to 7.0.

#7 Updated by Knödlseder Jürgen almost 3 years ago

  • % Done changed from 30 to 50

I updated all packages prior to version 1.6.2, fixing the cfitsio and readline version numbers. Now need to check whether installation always provides the latest package version on all supported Python versions.

#8 Updated by Knödlseder Jürgen almost 3 years ago

  • % Done changed from 50 to 90

I checked the proper installation of ctools version 1.7.3 using

conda install ctools
including testing of ctools and GammaLib for Python 2.7, 3.5, 3.6, 3.7 and 3.8. Everything works fine now. Note that Python 3.9 is not yet supported for ctools 1.7.3.

#9 Updated by Knödlseder Jürgen almost 3 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

I did the same checks for the gammalib package alone. Everything seems to work. Close the issue now.

Also available in: Atom PDF