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

Add doc about the pip-to-conda mapping that can be provided in setup.cfg #83

Merged
merged 4 commits into from Feb 17, 2022

Conversation

maximlt
Copy link
Contributor

@maximlt maximlt commented Jan 31, 2022

No description provided.

pip_package2=conda_package2
...
```

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Can you add an example here with some concrete package that differs between the ecosystems? Usually it's "something" vs "something-base", or "pysomething" vs "something"...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced the dummy examples by two concrete examples.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How does it work for a pip package with optional extras like pkg[recommended]?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just tried by declaring this in the setup.py of hvplot:

extras_require['dummy'] = ['ibis[sqlite]']

and this in setup.cfg:

[tool:pyctdev.conda]
namespace_map = 
    ibis[sqlite]=ibis-sqlite

and running doit develop_install -c conda-forge -o dummy.

It failed with:

PackagesNotFoundError: The following packages are not available from current channels:

  - ibis

Current channels:

  - https://conda.anaconda.org/conda-forge/osx-64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://repo.anaconda.com/pkgs/main/osx-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.


TaskFailed - taskid:develop_install
Command failed: 'conda install -y  -c conda-forge "bokeh >=1.0.0" "colorcet >=2" "holoviews >=1.11.0" "pandas" "numpy >=1.15" "ibis"' returned 1

So the extra in bracket is stripped by pyctdev :/ Some explanation here I think: https://github.com/pyviz-dev/pyctdev/blob/61d0e3320628e2e5228422321ffb2ccb824ae446/pyctdev/_conda.py#L397-L412

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a note about this.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect, thanks!

@maximlt maximlt merged commit f10fee1 into master Feb 17, 2022
@maximlt maximlt deleted the maximlt-namespace-pip-to-conda branch February 17, 2022 18:34
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

Successfully merging this pull request may close these issues.

None yet

2 participants