Skip to content
This repository was archived by the owner on Jul 25, 2023. It is now read-only.

FIX Link root .condarc in rapids env - #137

Merged
mike-wendt merged 1 commit into
branch-0.16from
fix-condarc-gpuci-tools
Oct 8, 2020
Merged

mike-wendt merged 1 commit into
branch-0.16from
fix-condarc-gpuci-tools

Conversation

@mike-wendt

Copy link
Copy Markdown
Contributor

This fixes an issue with gpuci-tools where gpuci_conda_retry and gpuci_retry do not see the same channel information and cause install errors. There appears to be an environment change when calling conda from these wrapper function resulting in missing channel definitions set in the root /opt/conda/.condarc. Creating a symlink in /opt/conda/envs/rapids/.condarc to the root /opt/conda/.condarc solves this issue.

Discovered while trying to complete NVIDIA/cudf#6329

@mike-wendt mike-wendt added bug Something isn't working 3 - Ready for Review labels Oct 8, 2020
@mike-wendt mike-wendt self-assigned this Oct 8, 2020
@mike-wendt

Copy link
Copy Markdown
Contributor Author

Current broken state

Example with conda info run as the user

(rapids) root@8105837774c5:/# conda info

     active environment : rapids
    active env location : /opt/conda/envs/rapids
            shell level : 1
       user config file : /root/.condarc
 populated config files : /opt/conda/.condarc
          conda version : 4.8.5
    conda-build version : not installed
         python version : 3.7.4.final.0
       virtual packages : __glibc=2.27
       base environment : /opt/conda  (writable)
           channel URLs : https://conda.anaconda.org/gpuci/linux-64
                          https://conda.anaconda.org/gpuci/noarch
                          https://conda.anaconda.org/rapidsai/linux-64
                          https://conda.anaconda.org/rapidsai/noarch
                          https://conda.anaconda.org/rapidsai-nightly/linux-64
                          https://conda.anaconda.org/rapidsai-nightly/noarch
                          https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://conda.anaconda.org/nvidia/linux-64
                          https://conda.anaconda.org/nvidia/noarch
                          https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /opt/conda/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/conda/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.8.5 requests/2.22.0 CPython/3.7.4 Linux/4.4.0-177-generic ubuntu/18.04.5 glibc/2.27
                UID:GID : 0:0
             netrc file : None
           offline mode : False

Example with conda info being output by gpuci_conda_retry

This is the same for gpuci_retry

(rapids) root@8105837774c5:/# gpuci_conda_retry install ucx-py=0.16

     active environment : base
    active env location : /opt/conda/envs/rapids
            shell level : 1
       user config file : /root/.condarc
 populated config files : 
          conda version : 4.7.12
    conda-build version : 3.18.11
         python version : 3.8.6.final.0
       virtual packages : 
       base environment : /opt/conda/envs/rapids  (writable)
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /opt/conda/envs/rapids/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/conda/envs/rapids/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.7.12 requests/2.24.0 CPython/3.8.6 Linux/4.4.0-177-generic ubuntu/18.04.5 glibc/2.27
                UID:GID : 0:0
             netrc file : None
           offline mode : False

Collecting package metadata (current_repodata.json): ...working... done
...

Patched state in PR

Example with gpuci_conda_retry and a symlink to the root .condarc

(rapids) root@8105837774c5:/# gpuci_conda_retry install ucx-py=0.16

     active environment : base
    active env location : /opt/conda/envs/rapids
            shell level : 1
       user config file : /root/.condarc
 populated config files : /opt/conda/envs/rapids/.condarc
          conda version : 4.7.12
    conda-build version : 3.18.11
         python version : 3.8.6.final.0
       virtual packages : 
       base environment : /opt/conda/envs/rapids  (writable)
           channel URLs : https://conda.anaconda.org/gpuci/linux-64
                          https://conda.anaconda.org/gpuci/noarch
                          https://conda.anaconda.org/rapidsai/linux-64
                          https://conda.anaconda.org/rapidsai/noarch
                          https://conda.anaconda.org/rapidsai-nightly/linux-64
                          https://conda.anaconda.org/rapidsai-nightly/noarch
                          https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://conda.anaconda.org/nvidia/linux-64
                          https://conda.anaconda.org/nvidia/noarch
                          https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /opt/conda/envs/rapids/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/conda/envs/rapids/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.7.12 requests/2.24.0 CPython/3.8.6 Linux/4.4.0-177-generic ubuntu/18.04.5 glibc/2.27
                UID:GID : 0:0
             netrc file : None
           offline mode : False

Collecting package metadata (current_repodata.json): ...working... done
...

This fixes an issue with `gpuci-tools` where `gpuci_conda_retry` and `gpuci_retry` do not see the same channel information and cause install errors. There appears to be an environment change when calling `conda` from these wrapper function resulting in missing channel definitions set in the root `/opt/conda/.condarc`. Creating a symlink in `/opt/conda/envs/rapids/.condarc` to the root `/opt/conda/.condarc` solves this issue.

Discovered while trying to complete NVIDIA/cudf#6329
@mike-wendt
mike-wendt force-pushed the fix-condarc-gpuci-tools branch from 0f2b839 to 761cb82 Compare October 8, 2020 08:01
@raydouglass

Copy link
Copy Markdown
Contributor

rerun tests

@mike-wendt
mike-wendt merged commit aa456a8 into branch-0.16 Oct 8, 2020
@mike-wendt
mike-wendt deleted the fix-condarc-gpuci-tools branch October 8, 2020 20:22
mike-wendt added a commit that referenced this pull request Oct 8, 2020
Despite testing in #137 that passed, when trying to build containers after the PR merge no `rapidsai` containers would build due to symlink errors. This approach copies the file instead which will result in a more consistent state if the `.condarc` file is modified for the `rapids` env, it will leave the `base` env intact.
mike-wendt added a commit that referenced this pull request Oct 9, 2020
FIX Patch PR #137 by copying `.condarc` instead of symlink
mike-wendt added a commit that referenced this pull request Oct 15, 2020
Reverts #137/#138 this was done to fix an issue in `gpuci_conda_retry`. The actual issue was caused by a version mismatch between base/rapids environments which is being fixed by changes in this PR
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

3 - Ready for Review bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants