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

conda create --copy still creating symlinks #13624

Open
2 tasks done
alessandriniluca opened this issue Feb 26, 2024 · 3 comments
Open
2 tasks done

conda create --copy still creating symlinks #13624

alessandriniluca opened this issue Feb 26, 2024 · 3 comments
Labels
source::community catch-all for issues filed by community members stale [bot] marked as stale due to inactivity type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere

Comments

@alessandriniluca
Copy link

Checklist

  • I added a descriptive title
  • I searched open reports and couldn't find a duplicate

What happened?

Hi to everyone,
I may be doing something wrong or I may be misunderstanding the guide, but by following the helper returned by conda create --help, --copy options should Install all packages using copies instead of hard- or soft-linking. If I try to create a test environment with the following command:

$ conda create --copy -n sot python=3.9 cudatoolkit-dev=11.7 -c conda-forge

I still have symlinks:
ls -la in the conda environment folder ($HOME/.conda/envs/sot) returns some lines as the following:

lrwxrwxrwx  1 landomix landomix    53 Feb 26 15:57 nvvm -> /home/landomix/.conda/envs/sot/pkgs/cuda-toolkit/nvvm

Conda Info

active environment : None
            shell level : 0
       user config file : /home/landomix/.condarc
 populated config files : /home/landomix/.condarc
          conda version : 23.10.0
    conda-build version : not installed
         python version : 3.11.5.final.0
       virtual packages : __archspec=1=skylake
                          __cuda=12.3=0
                          __glibc=2.39=0
                          __linux=6.7.6=0
                          __unix=0=0
       base environment : /opt/miniconda3  (read only)
      conda av data dir : /opt/miniconda3/etc/conda
  conda av metadata url : None
           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/miniconda3/pkgs
                          /home/landomix/.conda/pkgs
       envs directories : /home/landomix/.conda/envs
                          /opt/miniconda3/envs
               platform : linux-64
             user-agent : conda/23.10.0 requests/2.31.0 CPython/3.11.5 Linux/6.7.6-arch1-1 arch/rolling glibc/2.39 solver/libmamba conda-libmamba-solver/23.11.1 libmambapy/1.5.3
                UID:GID : 1000:1000
             netrc file : None
           offline mode : False

Conda Config

==> /home/landomix/.condarc <==
allow_softlinks: False
always_softlink: False
always_copy: True

Conda list

# packages in environment at /opt/miniconda3:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main    defaults
_openmp_mutex             5.1                       1_gnu    defaults
archspec                  0.2.1              pyhd3eb1b0_0    defaults
boltons                   23.0.0          py311h06a4308_0    defaults
brotli-python             1.0.9           py311h6a678d5_7    defaults
bzip2                     1.0.8                h7b6447c_0    defaults
c-ares                    1.19.1               h5eee18b_0    defaults
ca-certificates           2023.08.22           h06a4308_0    defaults
certifi                   2023.7.22       py311h06a4308_0    defaults
cffi                      1.15.1          py311h5eee18b_3    defaults
charset-normalizer        2.0.4              pyhd3eb1b0_0    defaults
conda                     23.10.0         py311h06a4308_0    defaults
conda-content-trust       0.2.0           py311h06a4308_0    defaults
conda-libmamba-solver     23.11.1         py311h06a4308_0    defaults
conda-package-handling    2.2.0           py311h06a4308_0    defaults
conda-package-streaming   0.9.0           py311h06a4308_0    defaults
cryptography              41.0.3          py311hdda0065_0    defaults
fmt                       9.1.0                hdb19cb5_0    defaults
icu                       73.1                 h6a678d5_0    defaults
idna                      3.4             py311h06a4308_0    defaults
jsonpatch                 1.32               pyhd3eb1b0_0    defaults
jsonpointer               2.1                pyhd3eb1b0_0    defaults
krb5                      1.20.1               h143b758_1    defaults
ld_impl_linux-64          2.38                 h1181459_1    defaults
libarchive                3.6.2                h6ac8c49_2    defaults
libcurl                   8.4.0                h251f7ec_0    defaults
libedit                   3.1.20221030         h5eee18b_0    defaults
libev                     4.33                 h7f8727e_1    defaults
libffi                    3.4.4                h6a678d5_0    defaults
libgcc-ng                 11.2.0               h1234567_1    defaults
libgomp                   11.2.0               h1234567_1    defaults
libmamba                  1.5.3                haf1ee3a_0    defaults
libmambapy                1.5.3           py311h2dafd23_0    defaults
libnghttp2                1.57.0               h2d74bed_0    defaults
libsolv                   0.7.24               he621ea3_0    defaults
libssh2                   1.10.0               hdbd6064_2    defaults
libstdcxx-ng              11.2.0               h1234567_1    defaults
libuuid                   1.41.5               h5eee18b_0    defaults
libxml2                   2.10.4               hf1b16e4_1    defaults
lz4-c                     1.9.4                h6a678d5_0    defaults
ncurses                   6.4                  h6a678d5_0    defaults
openssl                   3.0.12               h7f8727e_0    defaults
packaging                 23.1            py311h06a4308_0    defaults
pcre2                     10.42                hebb0a14_0    defaults
pip                       23.3            py311h06a4308_0    defaults
pluggy                    1.0.0           py311h06a4308_1    defaults
pybind11-abi              4                    hd3eb1b0_1    defaults
pycosat                   0.6.6           py311h5eee18b_0    defaults
pycparser                 2.21               pyhd3eb1b0_0    defaults
pyopenssl                 23.2.0          py311h06a4308_0    defaults
pysocks                   1.7.1           py311h06a4308_0    defaults
python                    3.11.5               h955ad1f_0    defaults
readline                  8.2                  h5eee18b_0    defaults
reproc                    14.2.4               h295c915_1    defaults
reproc-cpp                14.2.4               h295c915_1    defaults
requests                  2.31.0          py311h06a4308_0    defaults
ruamel.yaml               0.17.21         py311h5eee18b_0    defaults
setuptools                68.0.0          py311h06a4308_0    defaults
sqlite                    3.41.2               h5eee18b_0    defaults
tk                        8.6.12               h1ccaba5_0    defaults
tqdm                      4.65.0          py311h92b7b1e_0    defaults
truststore                0.8.0           py311h06a4308_0    defaults
tzdata                    2023c                h04d1e81_0    defaults
urllib3                   1.26.18         py311h06a4308_0    defaults
wheel                     0.41.2          py311h06a4308_0    defaults
xz                        5.4.2                h5eee18b_0    defaults
yaml-cpp                  0.8.0                h6a678d5_0    defaults
zlib                      1.2.13               h5eee18b_0    defaults
zstandard                 0.19.0          py311h5eee18b_0    defaults
zstd                      1.5.5                hc292b87_0    defaults

Additional Context

O.s.: arch linux
Installed from: https://aur.archlinux.org/packages/miniconda3

@alessandriniluca alessandriniluca added the type::bug describes erroneous operation, use severity::* to classify the type label Feb 26, 2024
@travishathaway travishathaway added the source::community catch-all for issues filed by community members label Feb 26, 2024
@travishathaway
Copy link
Contributor

Hi @alessandriniluca,

If I'm reading that correctly, the symlink you're seeing is simply referencing something within that environment, which is normal.

The --copy option only prevents hard linking from the <conda_installation_location>/pkgs directory and does nothing to prevent soft linking (i.e. symlinks) from within the the environment itself.

Let me know if that makes sense.

@travishathaway travishathaway added type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere pending::feedback indicates we are waiting on feedback from the user and removed type::bug describes erroneous operation, use severity::* to classify the type labels Feb 27, 2024
@alessandriniluca
Copy link
Author

Thanks a lot, apparently I got tricked by the <...> hard- or soft-linking., now is more clear.

Knowing that, I'll leave here a command (just for reference) that could help who needs to generate an environment without any soft link at all. Yesterday I solved it by generating an environment on my laptop, and copied where needed with cp by adding -rL options, that (in few words) substitutes softlinks with pointed files (clearly this will waste some space).

@conda-bot conda-bot added pending::support indicates user is waiting on support from triage engineers and removed pending::feedback indicates we are waiting on feedback from the user labels Feb 27, 2024
@travishathaway travishathaway removed the pending::support indicates user is waiting on support from triage engineers label Feb 27, 2024
Copy link

Hi there, thank you for your contribution!

This issue has been automatically marked as stale because it has not had recent activity. It will be closed automatically if no further activity occurs.

If you would like this issue to remain open please:

  1. Verify that you can still reproduce the issue at hand
  2. Comment that the issue is still reproducible and include:
    - What OS and version you reproduced the issue on
    - What steps you followed to reproduce the issue

NOTE: If this issue was closed prematurely, please leave a comment.

Thanks!

@github-actions github-actions bot added the stale [bot] marked as stale due to inactivity label Jun 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
source::community catch-all for issues filed by community members stale [bot] marked as stale due to inactivity type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere
Projects
Status: 🆕 New
Development

No branches or pull requests

3 participants