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 installation fails #633

Open
l-oksanen opened this issue Jan 18, 2023 · 5 comments
Open

Conda installation fails #633

l-oksanen opened this issue Jan 18, 2023 · 5 comments

Comments

@l-oksanen
Copy link

Running

conda create -n test
conda activate test
conda config --env --add channels conda-forge
conda install rise

gives

ERROR conda.core.link:_execute(740): An error occurred while installing package 'conda-forge::rise-5.7.1-py311h38be061_2'.
Rolling back transaction: done

LinkError: post-link script failed for package conda-forge::rise-5.7.1-py311h38be061_2
location of failed script: /home/lsoksane/Local/conda/envs/test/bin/.rise-post-link.sh
==> script messages <==
<None>
==> script output <==
stdout: 
stderr: Traceback (most recent call last):
  File "/home/lsoksane/Local/conda/envs/test/bin/jupyter-nbextension", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/jupyter_core/application.py", line 277, in launch_instance
    return super().launch_instance(argv=argv, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/traitlets/config/application.py", line 1041, in launch_instance
    app.start()
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 972, in start
    super().start()
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/jupyter_core/application.py", line 266, in start
    self.subapp.start()
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 882, in start
    self.toggle_nbextension_python(self.extra_args[0])
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 855, in toggle_nbextension_python
    return toggle(module,
           ^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 470, in enable_nbextension_python
    return _set_nbextension_state_python(True, module, user, sys_prefix,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 368, in _set_nbextension_state_python
    m, nbexts = _get_nbextension_metadata(module)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/notebook/nbextensions.py", line 1107, in _get_nbextension_metadata
    m = import_item(module)
        ^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/traitlets/utils/importstring.py", line 38, in import_item
    return __import__(parts[0])
           ^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/rise/__init__.py", line 3, in <module>
    __version__ = pkg_resources.require("rise")[0].version
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/pkg_resources/__init__.py", line 956, in require
    needed = self.resolve(parse_requirements(requirements))
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/pkg_resources/__init__.py", line 815, in resolve
    dist = self._resolve_dist(
           ^^^^^^^^^^^^^^^^^^^
  File "/home/lsoksane/Local/conda/envs/test/lib/python3.11/site-packages/pkg_resources/__init__.py", line 856, in _resolve_dist
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'webcolors>=1.11; extra == "format-nongpl"' distribution was not found and is required by jsonschema

return code: 1

()

I was able to install a working copy by running

conda install webcolors
conda install uri-template
conda install jsonpointer
conda install isoduration
conda install fqdn
conda install rise
@glciampaglia
Copy link

Same issue here. I have tried what the original poster did and got a working copy running as well, but I am not sure why that works. Perhaps one of those packages (webcolors, etc.) was not specified as a dependency?

@schmittwilken
Copy link

same issue here.
The mentioned solutions works for me

@emiliom
Copy link

emiliom commented Apr 20, 2023

Same here. The fix worked for me, too. Thanks!

@nandocova
Copy link

Had the same issue. Your solution worked

I think it's strange the dependencies aren't being installed automatically and this issue has gone unnoticed for so long...

@tl-hbk
Copy link

tl-hbk commented Jul 17, 2023

I believe that this is caused by the dependencies in the conda package for jupyter_events being incorrect.

conda-forge/jupyter_events-feedstock#11

If you install jsonschema-with-format-nongpl at the same time as rise you should get webcolors installed

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

6 participants