whole-tale / repo2docker_wholetale

Repo2docker plugin for Whole Tale
Other
0 stars 1 forks source link

Conda Pack fails for py2.7 env #50

Closed Xarthisius closed 1 year ago

Xarthisius commented 1 year ago

Description

Following setup fails with r2d_wt:

$ cat environment.yml 
name: CompEnv-Ex2
channels:
  - defaults
dependencies:
  - python=2.7.*
  - pip
  - pip:
    - matplotlib==1.5.3

but works just fine with vanilla jupyter-repo2docker-2022.10.0

Xarthisius commented 1 year ago

Boils down to inheritance. On WT this environment.yml with jlab image will go through:

JupyterWTStackBuildPack > WholeTaleRBuildPack > RBuildPack > PythonBuildPack > CondaBuildPack

whereas, on vanilla r2d it goes straight CondaBuildPack. Python runtime detection happens in both CondaBuildPack and PythonBuildPack, but the latter overrides the former. As result in WT we get:

Building conda environment for python=3.8   # This leads to failure later

cause PythonBuildPack expects runtime to be set via runtime.txt and ignores environment.yml. If CondaBuildPack is used (in vanilla r2d) you get:

Building conda environment for python=2.7