datalad / datalad-installer

Installation script for Datalad and related components
MIT License
6 stars 3 forks source link

Running tests locally, conda seeks confirmation #171

Closed yarikoptic closed 10 months ago

yarikoptic commented 1 year ago
❯ python -m pytest -s -v test/
============================================================================================================================================ test session starts =============================================================================================================================================
platform linux -- Python 3.11.4, pytest-7.3.2, pluggy-1.0.0 -- /home/yoh/proj/datalad/datalad-installer/venvs/dev3/bin/python
cachedir: .pytest_cache
rootdir: /home/yoh/proj/datalad/datalad-installer
configfile: tox.ini
plugins: mock-3.11.1, cov-4.1.0
collected 104 items                                                                                                                                                                                                                                                                                          

test/test_install.py::test_install_miniconda PREFIX=/home/yoh/.tmp/pytest-of-yoh/pytest-2/test_install_miniconda0/conda
Unpacking payload ...

Installing base environment...

Downloading and Extracting Packages

Downloading and Extracting Packages

Preparing transaction: done
Executing transaction: done
installation finished.
Retrieving notices: ...working... done
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/yoh/.tmp/pytest-of-yoh/pytest-2/test_install_miniconda0/conda

  added / updated specs:
    - conda

The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    ca-certificates-2023.05.30 |       h06a4308_0         120 KB
    certifi-2023.5.7           |  py310h06a4308_0         152 KB
    conda-23.5.0               |  py310h06a4308_0         1.0 MB
    conda-package-handling-2.1.0|  py310h06a4308_0         269 KB
    conda-package-streaming-0.8.0|  py310h06a4308_0          28 KB
    cryptography-39.0.1        |  py310h9ce1e76_2         1.4 MB
    libffi-3.4.4               |       h6a678d5_0         142 KB
    openssl-3.0.9              |       h7f8727e_0         5.2 MB
    python-3.10.11             |       h955ad1f_3        26.8 MB
    requests-2.29.0            |  py310h06a4308_0          97 KB
    sqlite-3.41.2              |       h5eee18b_0         1.2 MB
    urllib3-1.26.16            |  py310h06a4308_0         201 KB
    xz-5.4.2                   |       h5eee18b_0         642 KB
    ------------------------------------------------------------
                                           Total:        37.2 MB

The following packages will be UPDATED:

  ca-certificates                     2023.01.10-h06a4308_0 --> 2023.05.30-h06a4308_0 
  certifi                         2022.12.7-py310h06a4308_0 --> 2023.5.7-py310h06a4308_0 
  conda                              23.3.1-py310h06a4308_0 --> 23.5.0-py310h06a4308_0 
  conda-package-han~                  2.0.2-py310h06a4308_0 --> 2.1.0-py310h06a4308_0 
  conda-package-str~                  0.7.0-py310h06a4308_0 --> 0.8.0-py310h06a4308_0 
  cryptography                       39.0.1-py310h9ce1e76_0 --> 39.0.1-py310h9ce1e76_2 
  libffi                                   3.4.2-h6a678d5_6 --> 3.4.4-h6a678d5_0 
  openssl                                 1.1.1t-h7f8727e_0 --> 3.0.9-h7f8727e_0 
  python                                 3.10.10-h7a1cb2a_2 --> 3.10.11-h955ad1f_3 
  requests                           2.28.1-py310h06a4308_1 --> 2.29.0-py310h06a4308_0 
  sqlite                                  3.41.1-h5eee18b_0 --> 3.41.2-h5eee18b_0 
  urllib3                           1.26.15-py310h06a4308_0 --> 1.26.16-py310h06a4308_0 
  xz                                      5.2.10-h5eee18b_1 --> 5.4.2-h5eee18b_0 

Proceed ([y]/n)? 
jwodder commented 1 year ago

@yarikoptic Cannot reproduce. Are you running the tests inside another Conda environment?

yarikoptic commented 1 year ago

I don't think so but it is a virtual env:

❯ which conda
conda not found
❯ which python
/home/yoh/proj/datalad/datalad-installer/venvs/dev3/bin/python
jwodder commented 1 year ago

@yarikoptic What about type conda? Do you have any environment variables starting with CONDA_ set?

yarikoptic commented 1 year ago
❯ export | grep CONDA
❯ type conda
conda not found

but also looking at the ps auxw -H output I see that conda is invoked without -y so it is intended to ask confirmation, isn't it?

yoh      1692990  3.3  0.0  52832 44592 pts/8    S+   16:51   0:01         python -m pytest -s -v test/
yoh      1693394 21.3  0.1 470776 127992 pts/8   S+   16:51   0:02           /home/yoh/.tmp/pytest-of-yoh/pytest-4/test_install_miniconda0/conda/bin/python /home/yoh/.tmp/pytest-of-yoh/pytest-4/test_install_miniconda0/conda/bin/conda update -n base -c defaults conda
yoh      1693397  0.0  0.0  15908 10564 pts/8    S+   16:51   0:00             /home/yoh/.tmp/pytest-of-yoh/pytest-4/test_install_miniconda0/conda/bin/python -c from multiprocessing.resource_tracker import main;main(5)
yarikoptic commented 11 months ago

might be related -- we are observing conda seeking confirmation when we try to boost python version in https://github.com/datalad/datalad/pull/7449/checks?check_run_id=17668445984: https://app.travis-ci.com/github/datalad/datalad/jobs/611523740