python – Install black[d] from conda

I want to run black as a code formatter in PyCharm. The black website gives specific instructions on how to do so, which is very helpful: black.readthedocs.io/en/stable/integrations/editors.html . However, it uses pip to install black[d] while I would like to use conda instead to take advantage of the dependency solver and to have a leaner process.

If I try to simply add black, black[d], or "black[d]" to the env.yaml file for conda, it installs the simple black package without the additional dependencies added by the optional [d]. Why is this happening? Is this syntax not accepted by conda or is something missing from the conda-forge repos?

Read more here: Source link