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

postCreateCommand fails during devcontainer setup #403

Open
Ramin2c opened this issue Jan 10, 2025 · 0 comments
Open

postCreateCommand fails during devcontainer setup #403

Ramin2c opened this issue Jan 10, 2025 · 0 comments

Comments

@Ramin2c
Copy link

Ramin2c commented Jan 10, 2025

Hi
I can see the following error during the devcontainer startup:

================================================================
Collecting package metadata (repodata.json): failed

>>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<

Traceback (most recent call last):
  File "/opt/conda/lib/python3.10/site-packages/conda/exception_handler.py", line 18, in __call__
    return func(*args, **kwargs)
  File "/opt/conda/lib/python3.10/site-packages/conda/cli/main.py", line 61, in main_subshell
    exit_code = do_call(args, parser)
  File "/opt/conda/lib/python3.10/site-packages/conda/cli/conda_argparse.py", line 205, in do_call
    result = getattr(module, func_name)(args, parser)
  File "/opt/conda/lib/python3.10/site-packages/conda/notices/core.py", line 132, in wrapper
    return func(*args, **kwargs)
  File "/opt/conda/lib/python3.10/site-packages/conda/cli/main_update.py", line 103, in execute
    install(args, parser, "update")
  File "/opt/conda/lib/python3.10/site-packages/conda/cli/install.py", line 409, in install
    unlink_link_transaction = solver.solve_for_transaction(
  File "/opt/conda/lib/python3.10/site-packages/conda/core/solve.py", line 153, in solve_for_transaction
    unlink_precs, link_precs = self.solve_for_diff(
  File "/opt/conda/lib/python3.10/site-packages/conda/core/solve.py", line 222, in solve_for_diff
    final_precs = self.solve_final_state(
  File "/opt/conda/lib/python3.10/site-packages/conda_libmamba_solver/solver.py", line 207, in solve_final_sta

te
index = IndexHelper(
File "/opt/conda/lib/python3.10/site-packages/conda_libmamba_solver/index.py", line 136, in init
self._index = self._load_channels()
File "/opt/conda/lib/python3.10/site-packages/conda_libmamba_solver/index.py", line 332, in _load_channels
jsons = {url: str(path) for (url, path) in executor.map(self._fetch_channel, urls)}
File "/opt/conda/lib/python3.10/site-packages/conda_libmamba_solver/index.py", line 332, in
jsons = {url: str(path) for (url, path) in executor.map(self._fetch_channel, urls)}
File "/opt/conda/lib/python3.10/concurrent/futures/_base.py", line 621, in result_iterator
yield _result_or_cancel(fs.pop())
File "/opt/conda/lib/python3.10/concurrent/futures/_base.py", line 319, in _result_or_cancel
return fut.result(timeout)
File "/opt/conda/lib/python3.10/concurrent/futures/_base.py", line 451, in result
return self.__get_result()
File "/opt/conda/lib/python3.10/concurrent/futures/_base.py", line 403, in __get_result
raise self._exception
File "/opt/conda/lib/python3.10/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
File "/opt/conda/lib/python3.10/site-packages/conda_libmamba_solver/index.py", line 254, in _fetch_channel
json_path, _ = subdir_data.repo_fetch.fetch_latest_path()
File "/opt/conda/lib/python3.10/site-packages/conda/gateways/repodata/init.py", line 749, in fetch_lates
t_path
_, state = self.fetch_latest()
File "/opt/conda/lib/python3.10/site-packages/conda/gateways/repodata/init.py", line 789, in fetch_lates
t
cache.load_state()
File "/opt/conda/lib/python3.10/site-packages/conda/gateways/repodata/init.py", line 585, in load_state
self.load(state_only=True)
File "/opt/conda/lib/python3.10/site-packages/conda/gateways/repodata/init.py", line 532, in load
with self.lock("r+") as state_file:
File "/opt/conda/lib/python3.10/contextlib.py", line 135, in enter
return next(self.gen)
File "/opt/conda/lib/python3.10/site-packages/conda/gateways/repodata/init.py", line 651, in lock
with self.cache_path_state.open(mode) as state_file, lock(state_file):
File "/opt/conda/lib/python3.10/pathlib.py", line 1119, in open
return self._accessor.open(self, mode, buffering, encoding, errors,
PermissionError: [Errno 13] Permission denied: '/opt/conda/pkgs/cache/497deca9.info.json'

$ /opt/conda/condabin/conda update conda -y

environment variables:
CIO_TEST=
CONDA_EXE=/opt/conda/bin/conda
CONDA_PYTHON_EXE=/opt/conda/bin/python
CONDA_ROOT=/opt/conda
CONDA_SHLVL=0
CURL_CA_BUNDLE=
LD_PRELOAD=
PATH=/opt/conda/condabin:/usr/local/python/current/bin:/usr/local/py-utils/
bin:/usr/local/share/nvm/current/bin:/opt/conda/bin:/usr/local/sbin:/u
sr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
PYTHON_PATH=/usr/local/python/current
REQUESTS_CA_BUNDLE=
SSL_CERT_FILE=

 active environment : None
        shell level : 0
   user config file : /home/vscode/.condarc

populated config files :
conda version : 24.11.3
conda-build version : not installed
python version : 3.10.9.final.0
solver : libmamba (default)
virtual packages : __archspec=1=skylake
__conda=24.11.3=0
__glibc=2.31=0
__linux=5.15.146.1=0
__unix=0=0
base environment : /opt/conda (writable)
conda av data dir : /opt/conda/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/conda/pkgs
/home/vscode/.conda/pkgs
envs directories : /opt/conda/envs
/home/vscode/.conda/envs
platform : linux-64
user-agent : conda/24.11.3 requests/2.32.3 CPython/3.10.9 Linux/5.15.146.1-microsoft-standard-WSL2 de
bian/11.9 glibc/2.31 solver/libmamba conda-libmamba-solver/24.1.0 libmambapy/1.5.8
UID:GID : 1000:1000
netrc file : None
offline mode : False

An unexpected error has occurred. Conda has prepared the above report.
If you suspect this error is being caused by a malfunctioning plugin,
consider using the --no-plugins option to turn off plugins.

Example: conda --no-plugins install

Alternatively, you can set the CONDA_NO_PLUGINS environment variable on
the command line to run the command without plugins enabled.

Example: CONDA_NO_PLUGINS=true conda install

Upload did not complete.

What's next?
Try Docker Debug for seamless, persistent debugging tools in any container or image → docker debug 1039a765d0656
2ff0f4a03b4b125a1d54961de1279f09cb3c1298126d010e007
Learn more at https://docs.docker.com/go/debug-cli/
[866101 ms] postCreateCommand failed with exit code 1. Skipping any further user-provided commands.
Done. Press any key to close the terminal.

I have a Windows 11 PC and am sure that my environment is OK since I am widely using devcontainer and WSL everyday for both personal and professional purposes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant