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

Deprecate conda_build.bdist_conda #4985

Closed
kenodegard opened this issue Aug 25, 2023 · 7 comments · Fixed by #5196
Closed

Deprecate conda_build.bdist_conda #4985

kenodegard opened this issue Aug 25, 2023 · 7 comments · Fixed by #5196
Assignees
Labels
backlog issue has been triaged but has not been earmarked for any upcoming release locked [bot] locked due to inactivity source::anaconda created by members of Anaconda, Inc. type::deprecation requests removal of deprecated feature(s)

Comments

@kenodegard
Copy link
Contributor

kenodegard commented Aug 25, 2023

What happened?

The functionality in conda_build.bdist_conda is specific to Python packages (built with distutils/setuptools) and not needed to build a conda package, e.g. see the sample usage:

from setuptools import setup
import conda_build.bdist_conda
setup(
name="package",
version="1.0.0",
distclass=conda_build.bdist_conda.CondaDistribution,
)

Based on a preliminary GitHub search the feature is also minimally used out in the wild (if at all?).

Docs

Thoughts on deprecating it? @chenghlee @dbast @jaimergp @ryanskeith @beeankha

@kenodegard kenodegard added source::anaconda created by members of Anaconda, Inc. type::deprecation requests removal of deprecated feature(s) labels Aug 25, 2023
@github-project-automation github-project-automation bot moved this to 🆕 New in 🧭 Planning Aug 25, 2023
@jezdez
Copy link
Member

jezdez commented Aug 25, 2023

A few thoughts:

  • the bdist_conda functionality is an attempt at lowering the barrier of adoption of conda, so it becomes easier for maintainers to build conda packages from standard Python packages
  • setuptools is still maintained and not deprecated
  • PEPs 517 (build backends) and 518 (pyproject.toml) provide new official APIs to define and build Python packages
  • the wheel package is supporting a bdist_wheel subcommand
  • But: we should work towards a few things to evolve this and stay up-to-date:
    • deprecate the built-in bdist_conda command
    • and release a setuptools-conda package in the conda incubator that contains the needed code (or just tell people to use old conda-builds?)
    • add the ability to conda-build to optionally read conda recipe metadata from pyproject.toml
    • work on a PEP 517 compatible build backend that enables Python users in the future to easily build conda files in addition to wheel files

@jezdez
Copy link
Member

jezdez commented Aug 25, 2023

I'd be interested to hearing what @dholth has to say about this

@dholth
Copy link
Contributor

dholth commented Aug 25, 2023

I would be shocked if anyone uses this.

@kenodegard kenodegard added the backlog issue has been triaged but has not been earmarked for any upcoming release label Aug 31, 2023
@beeankha
Copy link
Member

@mbargull do you have any thoughts or concerns about deprecating conda_build.bdist_conda?

@mbargull
Copy link
Member

Thanks for asking, Bianca!
I think bdist_conda is of limited use and has probably a very, very small user base.

In general, I think it would be beneficial if conda-build would be a generic package build tool at its core with specialized functionality like bdist_conda being added on the outside rather than the inside of it.
Meaning, I'm supportive of removing it from conda-build and think this functionality should be provided by an additional tool/package.

If we leave it in conda-build, it will likely only add tech-debt/maintenance-burden and at the same time not get the support it actually needs since it's used and tested by too few users.

There is, of course, the questions on where such tool/package would be developed at and who would sponsor such work...
We may want to comb through issues open regarding bdist_conda to figure out who is interested in it (and @jezdez would probably know who from the Python ecosystem to poke to find potential interested parties).

@joserc87
Copy link

I'm arriving to this issue, investigating after my CI pipeline has started failing with

error: invalid command 'bdist_conda'

realizing that it's been deprecated, and reading:

I would be shocked if anyone uses this.

Well, for what is worth, at least one person was using it 🥲. Also my project didn't appear in that search (and probably others as well) because I don't have distclass=conda_build.bdist_conda.CondaDistribution in the setup.py.

Of course I understand the need of deprecating features that are barely used, but be careful with your assumptions: there could be more people using this than what you expect.

joserc87 added a commit to RavenPack/python-api that referenced this issue Jun 27, 2024
@joserc87
Copy link

BTW if there are others like me, for me the solution is just to fix the version to 24.3.0 (conda install --yes conda-build=24.3.0) which seems to be the previous version to this deprecation. If there is a better solution I'd love to hear it.

@github-actions github-actions bot added the locked [bot] locked due to inactivity label Dec 25, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backlog issue has been triaged but has not been earmarked for any upcoming release locked [bot] locked due to inactivity source::anaconda created by members of Anaconda, Inc. type::deprecation requests removal of deprecated feature(s)
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants