Re: Rasterio installation on Amazon/AWS/EC2/notebook instance

Sean Gillies


On Wed, Jan 13, 2021 at 7:33 AM <robmarkcole@...> wrote:
I am attempting to install rasterio on an AWS notebook instance (essentially managed EC2 with Jupyter installed).
This should be straightforward but I have already sunk several hours without success. 

The instance has a bunch of conda environments available so I wish to install into one named python3.
The following results:

sh-4.2$ conda install -c conda-forge rasterio --name python3
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: - 
The environment is inconsistent, please check the package plan carefully
The following packages are causing the inconsistency:
  - defaults/noarch::jupyterlab==1.2.6=pyhf63ae98_0
  - defaults/linux-64::python-language-server==0.31.7=py36_0
  - defaults/linux-64::nb_conda==2.2.1=py36_0
  - defaults/noarch::numpydoc==0.9.2=py_0
  - defaults/noarch::anaconda-project==0.8.4=py_0
  - defaults/noarch::boto3==1.9.162=py_0
  - defaults/linux-64::s3transfer==0.2.1=py36_0
  - defaults/linux-64::nbconvert==5.6.1=py36_0
  - defaults/linux-64::bokeh==1.4.0=py36_0
  - defaults/noarch::jupyterlab_server==1.0.6=py_0
  - defaults/noarch::botocore==1.12.189=py_0
  - defaults/linux-64::jupyter==1.0.0=py36_7
  - defaults/linux-64::scikit-image==0.16.2=py36h0573a6f_0
  - defaults/linux-64::imageio==2.6.1=py36_0
  - defaults/linux-64::nb_conda_kernels==2.2.4=py36_0
  - defaults/linux-64::spyder==4.0.1=py36_0
  - defaults/linux-64::requests==2.22.0=py36_1
  - defaults/noarch::dask==2.11.0=py_0
  - defaults/noarch::ipywidgets==7.5.1=py_0
  - defaults/linux-64::widgetsnbextension==3.5.1=py36_0
  - defaults/noarch::s3fs==0.4.2=py_0
  - defaults/linux-64::notebook==6.0.3=py36_0
  - defaults/linux-64::anaconda-client==1.7.2=py36_0

At this point conda hangs. I also tried running:

$ conda update all

And repeating the process, but with the same result.
Any guidance greatly appreciated

I don't know anything about AWS notebook instances and am not a regular conda user, so my help might be a little sketchy. In my experience, one cannot incrementally upgrade or install new packages into a conda environment without breaking it. Instead, create a completely new environment, and expect that to be resolved properly.

Sean Gillies

Join to automatically receive all group messages.