Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tricky to use fiona from defaults #60

Closed
ceball opened this issue May 28, 2018 · 1 comment
Closed

Tricky to use fiona from defaults #60

ceball opened this issue May 28, 2018 · 1 comment
Assignees

Comments

@ceball
Copy link

ceball commented May 28, 2018

I can't seem to import fiona from defaults (unless I constrain the version of poppler), whereas I can from conda-forge (as long as I make sure gdal is also from conda-forge).

defaults

$ conda create -n popplertest python=3.6
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/popplertest

  added / updated specs: 
    - python=3.6


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    certifi-2018.4.16          |           py36_0         142 KB

The following NEW packages will be INSTALLED:

    ca-certificates: 2018.03.07-0           
    certifi:         2018.4.16-py36_0       
    libedit:         3.1.20170329-h6b74fdf_2
    libffi:          3.2.1-hd88cf55_4       
    libgcc-ng:       7.2.0-hdf63c60_3       
    libstdcxx-ng:    7.2.0-hdf63c60_3       
    ncurses:         6.1-hf484d3e_0         
    openssl:         1.0.2o-h20670df_0      
    pip:             10.0.1-py36_0          
    python:          3.6.5-hc3d631a_2       
    readline:        7.0-ha6073c6_4         
    setuptools:      39.1.0-py36_0          
    sqlite:          3.23.1-he433501_0      
    tk:              8.6.7-hc745277_3       
    wheel:           0.31.1-py36_0          
    xz:              5.2.4-h14c3975_4       
    zlib:            1.2.11-ha838bed_2      

Proceed ([y]/n)? y


Downloading and Extracting Packages
certifi-2018.4.16    |  142 KB | : 100% 1.0/1 [00:00<00:00,  8.16it/s]               
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate popplertest
#
# To deactivate an active environment, use
#
#     $ conda deactivate

$ conda activate popplertest
(popplertest)$ conda install poppler fiona
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/popplertest

  added / updated specs: 
    - fiona
    - poppler


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    poppler-data-0.4.9         |                0         3.5 MB
    click-plugins-1.0.3        |           py36_0           9 KB
    cligj-0.4.0                |           py36_0          14 KB
    ------------------------------------------------------------
                                           Total:         3.6 MB

The following NEW packages will be INSTALLED:

    blas:           1.0-mkl              
    bzip2:          1.0.6-h14c3975_5     
    cairo:          1.14.12-h8948797_3   
    click:          6.7-py36h5253387_0   
    click-plugins:  1.0.3-py36_0         
    cligj:          0.4.0-py36_0         
    curl:           7.60.0-h84994c4_0    
    expat:          2.2.5-he0dffb1_0     
    fiona:          1.7.10-py36h48a52f0_0
    fontconfig:     2.13.0-h9420a91_0    
    freetype:       2.9.1-h8a8886c_0     
    freexl:         1.0.5-h14c3975_0     
    gdal:           2.2.2-py36hc209d97_1 
    geos:           3.6.2-heeff764_2     
    giflib:         5.1.4-h26a3ec6_1     
    glib:           2.56.1-h000015b_0    
    hdf4:           4.2.13-h3ca952b_2    
    hdf5:           1.10.1-h9caa474_1    
    icu:            58.2-h9c2bf20_1      
    intel-openmp:   2018.0.0-8           
    jpeg:           9b-h024ee3a_2        
    json-c:         0.12.1-ha6a3662_2    
    kealib:         1.4.7-h79811e5_5     
    krb5:           1.16-h3f6afd0_6      
    libboost:       1.65.1-habcd387_4    
    libcurl:        7.60.0-h1ad7b7a_0    
    libdap4:        3.19.0-h5bd89bb_2    
    libgdal:        2.2.2-h804cdde_1     
    libgfortran-ng: 7.2.0-hdf63c60_3     
    libkml:         1.3.0-h9d32c78_3     
    libnetcdf:      4.4.1.1-h816af47_8   
    libpng:         1.6.34-hb9fc6fc_0    
    libpq:          10.3-h1ad7b7a_0      
    libspatialite:  4.3.0a-h72746d6_18   
    libssh2:        1.8.0-h9cfc8f7_4     
    libtiff:        4.0.9-he85c1e1_1     
    libuuid:        1.0.3-h1bed415_2     
    libxcb:         1.13-h1bed415_1      
    libxml2:        2.9.8-h26e45fe_1     
    mkl:            2018.0.2-1           
    mkl_fft:        1.0.1-py36h3010b51_0 
    mkl_random:     1.0.1-py36h629b387_0 
    munch:          2.3.2-py36_0         
    numpy:          1.14.3-py36hcd700cb_1
    numpy-base:     1.14.3-py36h9be14a7_1
    openjpeg:       2.3.0-h05c96fa_1     
    pcre:           8.42-h439df22_0      
    pixman:         0.34.0-hceecf20_3    
    poppler:        0.65.0-h581218d_1    
    poppler-data:   0.4.9-0              
    proj4:          4.9.3-hc8507d1_7     
    shapely:        1.6.4-py36h0c48222_0 
    six:            1.11.0-py36h372c433_1
    xerces-c:       3.2.1-hac72e42_0     

Proceed ([y]/n)? y


Downloading and Extracting Packages
poppler-data-0.4.9   |  3.5 MB | : 100% 1.0/1 [00:00<00:00,  1.06it/s]               
click-plugins-1.0.3  |    9 KB | : 100% 1.0/1 [00:00<00:00, 31.51it/s]
cligj-0.4.0          |   14 KB | : 100% 1.0/1 [00:00<00:00, 26.03it/s]
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(popplertest)$ python -c "import fiona"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/cio/mc3/envs/popplertest/lib/python3.6/site-packages/fiona/__init__.py", line 69, in <module>
    from fiona.collection import Collection, BytesCollection, vsi_path
  File "/cio/mc3/envs/popplertest/lib/python3.6/site-packages/fiona/collection.py", line 9, in <module>
    from fiona.ogrext import Iterator, ItemsIterator, KeysIterator
ImportError: libpoppler.so.71: cannot open shared object file: No such file or directory
(popplertest)$ ls -l /cio/mc3/envs/popplertest/lib/*poppler*
lrwxrwxrwx 1 ceball ceball      23 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler-cpp.so -> libpoppler-cpp.so.0.5.0
lrwxrwxrwx 1 ceball ceball      23 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler-cpp.so.0 -> libpoppler-cpp.so.0.5.0
-rwxrwxr-x 2 ceball ceball  123312 May 25 16:17 /cio/mc3/envs/popplertest/lib/libpoppler-cpp.so.0.5.0
lrwxrwxrwx 1 ceball ceball      24 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler-glib.so -> libpoppler-glib.so.8.9.0
lrwxrwxrwx 1 ceball ceball      24 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler-glib.so.8 -> libpoppler-glib.so.8.9.0
-rwxrwxr-x 2 ceball ceball  488400 May 25 16:17 /cio/mc3/envs/popplertest/lib/libpoppler-glib.so.8.9.0
lrwxrwxrwx 1 ceball ceball      20 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler.so -> libpoppler.so.76.0.0
lrwxrwxrwx 1 ceball ceball      20 May 28 15:39 /cio/mc3/envs/popplertest/lib/libpoppler.so.76 -> libpoppler.so.76.0.0
-rwxrwxr-x 1 ceball ceball 3056976 May 28 15:38 /cio/mc3/envs/popplertest/lib/libpoppler.so.76.0.0
(popplertest)$ conda deactivate

If I install an older version of poppler, things seem to be ok:

(popplertest)$ conda install "poppler<=0.60.1"
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/popplertest

  added / updated specs:
    - poppler[version='<=0.60.1']


The following packages will be DOWNGRADED:

    cairo:      1.14.12-h8948797_3 --> 1.14.12-h77bcde2_0
    fontconfig: 2.13.0-h9420a91_0  --> 2.12.6-h49f89f6_0
    freetype:   2.9.1-h8a8886c_0   --> 2.8-hab7d2ae_1
    glib:       2.56.1-h000015b_0  --> 2.53.6-h5d9569c_2
    poppler:    0.65.0-h581218d_1  --> 0.60.1-hc909a00_0

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(popplertest)$ python -c "import fiona"
(popplertest)$

conda-forge

$ conda create -c conda-forge -n cfpopplertest python=3.6
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/cfpopplertest

  added / updated specs: 
    - python=3.6


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    certifi-2018.4.16          |           py36_0         142 KB  conda-forge

The following NEW packages will be INSTALLED:

    ca-certificates: 2018.4.16-0       conda-forge
    certifi:         2018.4.16-py36_0  conda-forge
    libgcc-ng:       7.2.0-hdf63c60_3             
    ncurses:         5.9-10            conda-forge
    openssl:         1.0.2o-0          conda-forge
    pip:             9.0.3-py36_0      conda-forge
    python:          3.6.5-1           conda-forge
    readline:        7.0-0             conda-forge
    setuptools:      39.2.0-py36_0     conda-forge
    sqlite:          3.20.1-2          conda-forge
    tk:              8.6.7-0           conda-forge
    wheel:           0.31.0-py36_0     conda-forge
    xz:              5.2.3-0           conda-forge
    zlib:            1.2.11-h470a237_2 conda-forge

Proceed ([y]/n)? y


Downloading and Extracting Packages
certifi-2018.4.16    |  142 KB | : 100% 1.0/1 [00:01<00:00,  1.25s/it]               
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate cfpopplertest
#
# To deactivate an active environment, use
#
#     $ conda deactivate

$ conda activate cfpopplertest
(cfpopplertest)$ conda install -c conda-forge poppler fiona gdal
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/cfpopplertest

  added / updated specs: 
    - fiona
    - gdal
    - poppler


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    cligj-0.4.0                |           py36_0          12 KB  conda-forge
    poppler-data-0.4.9         |                0         3.5 MB  conda-forge
    click-plugins-1.0.3        |           py36_0           7 KB  conda-forge
    ------------------------------------------------------------
                                           Total:         3.6 MB

The following NEW packages will be INSTALLED:

    boost:          1.66.0-py36_1         conda-forge
    boost-cpp:      1.66.0-1              conda-forge
    bzip2:          1.0.6-1               conda-forge
    cairo:          1.14.10-0             conda-forge
    click:          6.7-py_1              conda-forge
    click-plugins:  1.0.3-py36_0          conda-forge
    cligj:          0.4.0-py36_0          conda-forge
    curl:           7.60.0-0              conda-forge
    expat:          2.2.5-0               conda-forge
    fiona:          1.7.11-py36_3         conda-forge
    fontconfig:     2.12.6-0              conda-forge
    freetype:       2.8.1-0               conda-forge
    freexl:         1.0.5-0               conda-forge
    gdal:           2.2.4-py36_0          conda-forge
    geos:           3.6.2-1               conda-forge
    geotiff:        1.4.2-1               conda-forge
    gettext:        0.19.8.1-0            conda-forge
    giflib:         5.1.4-0               conda-forge
    glib:           2.55.0-0              conda-forge
    hdf4:           4.2.13-0              conda-forge
    hdf5:           1.10.1-2              conda-forge
    icu:            58.2-0                conda-forge
    jpeg:           9b-2                  conda-forge
    json-c:         0.12.1-0              conda-forge
    kealib:         1.4.7-4               conda-forge
    krb5:           1.14.6-0              conda-forge
    libdap4:        3.18.3-2              conda-forge
    libffi:         3.2.1-3               conda-forge
    libgdal:        2.2.4-2               conda-forge
    libgfortran:    3.0.0-1                          
    libgfortran-ng: 7.2.0-hdf63c60_3                 
    libiconv:       1.15-0                conda-forge
    libkml:         1.3.0-6               conda-forge
    libnetcdf:      4.6.1-2               conda-forge
    libopenblas:    0.2.20-h9ac9557_4                
    libpng:         1.6.34-0              conda-forge
    libpq:          9.6.3-0               conda-forge
    libspatialite:  4.3.0a-19             conda-forge
    libssh2:        1.8.0-2               conda-forge
    libtiff:        4.0.9-0               conda-forge
    libxml2:        2.9.8-0               conda-forge
    munch:          2.3.2-py_0            conda-forge
    numpy:          1.14.3-py36h28100ab_1            
    numpy-base:     1.14.3-py36h0ea5e3f_1            
    openjpeg:       2.3.0-2               conda-forge
    pcre:           8.41-1                conda-forge
    pixman:         0.34.0-2              conda-forge
    poppler:        0.61.1-3              conda-forge
    poppler-data:   0.4.9-0               conda-forge
    proj4:          4.9.3-5               conda-forge
    shapely:        1.6.4-py36_0          conda-forge
    six:            1.11.0-py36_1         conda-forge
    util-linux:     2.21-0                           
    xerces-c:       3.2.0-0               conda-forge

Proceed ([y]/n)? y


Downloading and Extracting Packages
cligj-0.4.0          |   12 KB | : 100% 1.0/1 [00:00<00:00,  1.14it/s] 
poppler-data-0.4.9   |  3.5 MB | : 100% 1.0/1 [00:02<00:00,  2.38s/it]               
click-plugins-1.0.3  |    7 KB | : 100% 1.0/1 [00:00<00:00,  1.81it/s] 
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(cfpopplertest)$ python -c "import fiona"
(cfpopplertest)$

If I don't specify gdal, it ends up coming from defaults, so same problem:

$ conda create -c conda-forge -n cfpopplertest2 python=3.6
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/cfpopplertest2

  added / updated specs: 
    - python=3.6


The following NEW packages will be INSTALLED:

    ca-certificates: 2018.4.16-0       conda-forge
    certifi:         2018.4.16-py36_0  conda-forge
    libgcc-ng:       7.2.0-hdf63c60_3             
    ncurses:         5.9-10            conda-forge
    openssl:         1.0.2o-0          conda-forge
    pip:             9.0.3-py36_0      conda-forge
    python:          3.6.5-1           conda-forge
    readline:        7.0-0             conda-forge
    setuptools:      39.2.0-py36_0     conda-forge
    sqlite:          3.20.1-2          conda-forge
    tk:              8.6.7-0           conda-forge
    wheel:           0.31.0-py36_0     conda-forge
    xz:              5.2.3-0           conda-forge
    zlib:            1.2.11-h470a237_2 conda-forge

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate cfpopplertest2
#
# To deactivate an active environment, use
#
#     $ conda deactivate

$ conda activate cfpopplertest2
(cfpopplertest2)$ conda install -c conda-forge poppler fiona
Solving environment: done

## Package Plan ##

  environment location: /cio/mc3/envs/cfpopplertest2

  added / updated specs: 
    - fiona
    - poppler


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    xerces-c-3.2.1             |                0         3.9 MB  conda-forge

The following NEW packages will be INSTALLED:

    boost:          1.66.0-py36_1         conda-forge
    boost-cpp:      1.66.0-1              conda-forge
    bzip2:          1.0.6-1               conda-forge
    cairo:          1.14.10-0             conda-forge
    click:          6.7-py_1              conda-forge
    click-plugins:  1.0.3-py36_0          conda-forge
    cligj:          0.4.0-py36_0          conda-forge
    curl:           7.60.0-0              conda-forge
    expat:          2.2.5-0               conda-forge
    fiona:          1.7.11-py36_3         conda-forge
    fontconfig:     2.12.6-0              conda-forge
    freetype:       2.8.1-0               conda-forge
    freexl:         1.0.5-0               conda-forge
    gdal:           2.2.2-py36hc209d97_1             
    geos:           3.6.2-1               conda-forge
    gettext:        0.19.8.1-0            conda-forge
    giflib:         5.1.4-0               conda-forge
    glib:           2.55.0-0              conda-forge
    hdf4:           4.2.13-0              conda-forge
    hdf5:           1.10.1-2              conda-forge
    icu:            58.2-0                conda-forge
    jpeg:           9b-2                  conda-forge
    json-c:         0.12.1-0              conda-forge
    kealib:         1.4.7-4               conda-forge
    krb5:           1.14.6-0              conda-forge
    libdap4:        3.19.2-1              conda-forge
    libffi:         3.2.1-3               conda-forge
    libgdal:        2.2.2-h804cdde_1                 
    libgfortran:    3.0.0-1                          
    libgfortran-ng: 7.2.0-hdf63c60_3                 
    libiconv:       1.15-0                conda-forge
    libkml:         1.3.0-6               conda-forge
    libnetcdf:      4.4.1.1-10            conda-forge
    libopenblas:    0.2.20-h9ac9557_4                
    libpng:         1.6.34-0              conda-forge
    libpq:          9.6.6-h4e02ad2_0                 
    libspatialite:  4.3.0a-19             conda-forge
    libssh2:        1.8.0-2               conda-forge
    libstdcxx-ng:   7.2.0-hdf63c60_3                 
    libtiff:        4.0.9-0               conda-forge
    libxml2:        2.9.8-0               conda-forge
    munch:          2.3.2-py_0            conda-forge
    numpy:          1.14.3-py36h28100ab_1            
    numpy-base:     1.14.3-py36h0ea5e3f_1            
    openjpeg:       2.3.0-2               conda-forge
    pcre:           8.41-1                conda-forge
    pixman:         0.34.0-2              conda-forge
    poppler:        0.64.0-0              conda-forge
    poppler-data:   0.4.9-0               conda-forge
    proj4:          4.9.3-5               conda-forge
    shapely:        1.6.4-py36_0          conda-forge
    six:            1.11.0-py36_1         conda-forge
    util-linux:     2.21-0                           
    xerces-c:       3.2.1-0               conda-forge

Proceed ([y]/n)? y


Downloading and Extracting Packages
xerces-c-3.2.1       |  3.9 MB | : 100% 1.0/1 [00:26<00:00, 26.17s/it]              
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(cfpopplertest2)$ python -c "import fiona"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/cio/mc3/envs/cfpopplertest2/lib/python3.6/site-packages/fiona/__init__.py", line 69, in <module>
    from fiona.collection import Collection, BytesCollection, vsi_path
  File "/cio/mc3/envs/cfpopplertest2/lib/python3.6/site-packages/fiona/collection.py", line 9, in <module>
    from fiona.ogrext import Iterator, ItemsIterator, KeysIterator
ImportError: libpoppler.so.71: cannot open shared object file: No such file or directory

conda info:


     active environment : popplertest
    active env location : /cio/mc3/envs/popplertest
            shell level : 1
       user config file : /home/ceball/.condarc
 populated config files :
          conda version : 4.5.4
    conda-build version : 3.10.1
         python version : 3.6.4.final.0
       base environment : /cio/mc3  (writable)
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/free/linux-64
                          https://repo.anaconda.com/pkgs/free/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
                          https://repo.anaconda.com/pkgs/pro/linux-64
                          https://repo.anaconda.com/pkgs/pro/noarch
          package cache : /cio/mc3/pkgs
                          /home/ceball/.conda/pkgs
       envs directories : /cio/mc3/envs
                          /home/ceball/.conda/envs
               platform : linux-64
             user-agent : conda/4.5.4 requests/2.18.4 CPython/3.6.4 Linux/3.16.0-4-amd64 debian/8 glibc/2.19
                UID:GID : 1000:1000
             netrc file : None
           offline mode : False
@jjhelmus
Copy link
Contributor

This is the same issue as ContinuumIO/anaconda-issues#9449. @msarahan is working on a fix.

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

No branches or pull requests

3 participants