24.9.0
✨ Special announcement ✨
This is an announcement about an important and positive future change in conda's functionality:
Following feedback from conda users about the pre-configuration of the conda code base to favor channels from Anaconda Inc, we've started the process to deprecate hardcoding Anaconda's channels as the default set of channels in the conda source code, which is a remnant of conda's incubation at the company.
In the future, we will rely on providers of conda distributions, such as miniforge or Anaconda (including miniconda), to pre-configure their preferred channels, e.g. by running the necessary conda config --set channels command.
We're also going to continue to work on improving channel management in the forseeable future and would love to get your feedback.
Enhancements
- Add
conda.core.index.Indexas a faster drop-in replacement of the realized dictionary index. Note: The loggers are no longer implicitly initialized when fetching the index. Instead, you must explicitly callconda.gateways.logging.initialize_logging. (#13880, #14267) - Alias
conda env removecommand toconda remove --all. (#13977) - Add a new health check to
conda doctorthat detects if theREQUESTS_CA_BUNDLEenv var points to a non-existent file. (#12905 via #14037) - Add
--sha256flag toconda list --explicitso it lists URLs with a SHA256 hash instead of MD5 and makeconda install|createcompatible with these inputs. (#2903, #7882 via #14048) - Report
condaversion used to generate a@EXPLICITtext file. (#14048) - Update health checks outputs for consistency. (#14049 via #14079)
- Fix Windows to Unix path conversion to handle UNC mounts and root paths. (#14157)
- Add a new
denylist_channelsconfig option andCONDA_DENYLIST_CHANNELSenvironment variable to explicitly deny using specific channels globally, which is complementing the already existingallowlist_channelsconfig option. (#14176 via #14196) - Add
conda commandssubcommand. (#14215) - Add
conda.testing.fixtures.session_capsys. Use this to capture stdout and stderr within module, package, and session scoped fixtures. (#14243) - Add
conda.testing.fixtures.session_conda_cli. Use this to invoke conda commands within module, package, and session scoped fixtures. (#14243) - Add
conda.testing.fixtures.session_tmp_env. Use this to create a conda environment within module, package, and session scoped fixtures. (#14243)
Bug fixes
- Prevent directories that contain conda environments from being specified as an environment prefix when creating new envs; this provides guardrails against the accidental deletion of environments via commands such as
conda rename. (#13955) - Enable
conda doctorto check whether the environment exists or not before trying to generate a health report. (#14042 via #14112) - Fix
conda.common.configuration.ObjectParameter's ability to appropriately handle defaults. (#14148 via #14149) conda remove [env] --allcommand no longer deletes empty parent directories for environments that are removed. (#14173)- Raise an error when attempting to remove non-existent environment. (#14174 via #14199)
- Add pre-/post-command hooks to activation subcommands (
activate,deactivate,reactivate,hooks, andcommands). (#14211 via #14212) - Replace extensions from end of filename only, not
str.replace(), in two places. (#14241) - Fix PowerShell activation/deactivation to properly unset environment variables using
$Env:VARIABLE = $nullinstead of$Env:VARIABLE = "". (#14237 via #14246)
Deprecations
- Mark
conda.core.index.get_indexas pending deprecation. Useconda.core.index.Indexinstead. (#13880) - Mark
conda.core.index.get_reduced_indexas pending deprecation. Useconda.core.index.ReducedIndexinstead. (#13880) - Mark
conda.core.index.fetch_indexas pending deprecation. Useconda.core.index.Indexinstead. (#13880) - Mark
conda.core.index._supplement_index_with_prefixas pending deprecation. Useconda.core.index.Index.reloadinstead. (#13880) - Mark
conda.core.index._supplement_index_with_cacheas pending deprecation. Useconda.core.index.Index.reloadinstead. (#13880) - Mark
conda.core.index._supplement_index_with_featuresas pending deprecation. Useconda.core.index.Index.reloadinstead. (#13880) - Mark
conda.core.index._supplement_index_with_systemas pending deprecation. Useconda.core.index.Index.reloadinstead. (#13880) - Mark
conda.core.index._make_virtual_packageas pending deprecation. Useconda.models.records.PackageRecord.virtual_packageinstead. (#13880) - Mark
conda.core.subdir_data.make_feature_recordas pending deprecation. Useconda.models.records.PackageRecord.featureinstead. (#13880) - Mark
conda.plugins.manager.CondaPluginManager.get_virtual_packagesas pending deprecation. Useconda.plugins.manager.CondaPluginManager.get_virtual_package_recordsinstead. (#13880) - Mark
conda.misc.explicit(index_args)as pending deprecation. (#14267) - Mark
conda.cli.main_rename.validate_destinationas pending deprecation. Useconda.cli.install.validate_new_prefixinstead. (#13955) - Mark
conda.cli.main_env_remove.executeas pending deprecation. Useconda.cli.main_remove.executeinstead. (#13977) - Mark
conda.activate.path_identityas pending deprecation. Useconda.common.path.path_identityinstead. (#14068) - Mark
conda.utils.path_identityas pending deprecation. Useconda.common.path.path_identityinstead. (#14068) - Mark
conda.models.leased_path_entryas pending deprecation. (#14077) - Postpone removal of
conda.base.context.Context.conda_exetoconda 25.3. (#14077) - Postpone removal of
conda.cli.python_apitoconda 25.9. (#14077) - Remove
conda._vendor.appdirs. Useplatformdirsinstead. (#14077) - Remove
conda._vendor.cpuinfo. (#14077) - Remove
conda._vendor.distro. Usedistroinstead. (#14077) - Remove
conda.auxlib.collection.call_each. (#14077) - Remove
conda.auxlib.collection.firstitem. (#14077) - Remove
conda.auxlib.compat.NoneType. (#14077) - Remove
conda.auxlib.compat.primitive_types. (#14077) - Remove
conda.auxlib.compat.utf8_writer. (#14077) - Remove
conda.auxlib.exceptions.AssignmentError. (#14077) - Remove
conda.auxlib.exceptions.AuthenticationError. (#14077) - Remove
conda.auxlib.exceptions.InitializationError. (#14077) - Remove
conda.auxlib.exceptions.NotFoundError. (#14077) - Remove
conda.auxlib.exceptions.SenderError. (#14077) - Remove
conda.auxlib.type_coercion.boolify_truthy_string_ok. (#14077) - Remove
conda.auxlib.type_coercion.listify. (#14077) - Remove
conda.base.context.Context.root_dir. Useconda.base.context.Context.root_prefixinstead. (#14077) - Remove
conda.base.exceptions. (#14077) - Remove
conda.cli.main.generate_parser. Useconda.cli.conda_argparse.generate_parserinstead. (#14077) - Remove
conda.cli.main.init_loggers(context)(#14077) - Remove
conda.cli.main_rename.validate_src(name). (#14077) - Remove
conda.cli.main_rename.validate_src(prefix). (#14077) - Remove
conda.common.configuration.load_file_configs. (#14077) - Remove
conda.common.decorators.env_override. (#14077) - Remove
conda.common.decorators. (#14077) - Remove
conda.common.disk.temporary_content_in_file. Usetempfileinstead. (#14077) - Remove
conda.core.package_cache_data.download. Useconda.gateways.connection.download.downloadinstead. (#14077) - Remove
conda.core.package_cache_data.rm_fetched. (#14077) - Remove
conda.core.package_cache. Useconda.core.package_cache_datainstead. (#14077) - Remove
conda.core.prefix_data.PrefixData._has_python. (#14077) - Remove
conda.core.subdir_data.get_cache_control_max_age. Useconda.gateways.repodata.get_cache_control_max_ageinstead. (#14077) - Remove
conda.exports.fetch_index. Useconda.core.index.fetch_indexinstead. (#14077) - Remove
conda.exports.IndexRecord. Useconda.models.records.PackageRecordinstead. (#14077) - Remove
conda.gateways.anaconda_client.EnvAppDirs. Useplatformdirsinstead. (#14077) - Remove
conda.gateways.connection.adapters.ftp.FTPAdapter.stor. (#14077) - Remove
conda.gateways.connection.adapters.ftp.parse_multipart_files(#14077) - Remove
conda.gateways.logging.set_verbosity. Useconda.gateways.logging.set_log_levelinstead. (#14077) - Remove
conda.gateways.logging.VERBOSITY_LEVELS. (#14077) - Remove
conda.models.dist.IndexRecord. Useconda.models.records.PackageRecordinstead. (#14077) - Remove
conda.models.enums.LeasedPathType. (#14077) - Remove
conda.models.leased_path_entry.LeasedPathEntry. (#14077) - Remove
conda.plugins.subcommands.doctor.get_prefix. Useconda.base.context.context.target_prefixinstead. (#14077) - Remove
conda.plugins.subcommands.doctor.health_checks.display_health_checks. (#14077) - Remove
conda.plugins.subcommands.doctor.health_checks.display_report_heading. (#14077) - Remove
conda.testing.helpers.set_active_prefix. Usemocker.patch('conda.base.context.Context.active_prefix')instead. (#14077) - Remove
tests.env.utils.run_command. Useconda_clifixture instead. (#14077) - Mark
tests.env.utils.make_temp_envs_diras pending deprecation. Usetmp_envs_dirfixture instead. (#14093) - Mark
conda.gateways.disk.delete.rm_rf(max_retries)as pending deprecated. (#14094) - Mark
conda.gateways.disk.delete.rm_rf(trash)as pending deprecated. (#14094) - Mark
conda.gateways.disk.delete.try_rmdir_all_emptyas pending deprecated. Useconda.gateways.disk.delete.rm_rfinstead. (#14094) - Mark
conda.gateways.disk.delete.move_to_trashas pending deprecated. Useconda.gateways.disk.delete.rm_rfinstead. (#14094) - Mark
conda.gateways.disk.delete.move_path_to_trashas pending deprecated. Useconda.gateways.disk.delete.rm_rfinstead. (#14094) - Mark
conda.exports.move_to_trashas pending deprecation. Useconda.gateways.disk.delete.rm_rfinstead. (#14118) - Mark
conda.activate.ensure_binaryas pending deprecation. Useconda.common.compat.ensure_binaryinstead. (#14144) - Mark
conda.activate.ensure_fs_path_encodingas pending deprecation. (#14144) - Mark
conda.common.compat.six_with_metaclassas pending deprecation. Use class'metaclass=keyword argument instead. (#14144) - Mark
conda.common.compat.openas pending deprecation. Useconda.common.compat.open_utf8instead. (#14144, #14169) - Mark
conda.common.compat.ensure_unicodeas pending deprecation. (#14144) - Mark
conda.common.compat.ensure_fs_path_encodingas pending deprecation. (#14144) - Mark
conda.common.compat.FILESYSTEM_ENCODINGas pending deprecation. (#14144, #14169) - Mark
conda.activate.native_path_to_unixas pending deprecation. Useconda.common.path.win_path_to_unixinstead. (#14157) - Mark
conda.activate.unix_path_to_nativeas pending deprecation. Useconda.common.path.unix_path_to_wininstead. (#14157) - Mark
conda.activate._Cygpathas pending deprecation. Useconda.common.path._cygpathinstead. (#14157) - Mark
conda.activate._Cygpath.RE_UNIXas pending deprecation. Useconda.common.path._cygpath.RE_WIN_DRIVEinstead. (#14157) - Mark
conda.activate._Cygpath.translate_unixas pending deprecation. Useconda.common.path._cygpath._to_unix_driveinstead. (#14157) - Mark
conda.activate._Cygpath.RE_DRIVEas pending deprecation. Useconda.common.path._cygpath.RE_UNIX_DRIVEinstead. (#14157) - Mark
conda.activate._Cygpath.translation_driveas pending deprecation. Useconda.common.path._cygpath._to_win_driveinstead. (#14157) - Mark
conda.activate._Cygpath.RE_MOUNTas pending deprecation. Useconda.common.path._cygpath.RE_UNIX_MOUNTinstead. (#14157) - Mark
conda.activate._Cygpath.translation_mountas pending deprecation. Useconda.common.path._cygpath._to_win_mountinstead. (#14157) - Mark
conda.activate._Cygpath.RE_ROOTas pending deprecation. Useconda.common.path._cygpath.RE_UNIX_ROOTinstead. (#14157) - Mark
conda.activate._Cygpath.translation_rootas pending deprecation. Useconda.common.path._cygpath._to_win_rootinstead. (#14157) - Mark
conda.utils.unix_path_to_winas pending deprecation. Useconda.common.path.unix_path_to_wininstead. (#14157) - Deprecate
conda.env.specs.binstarmodule. (#14158 via #14160) - Deprecate
conda env [create|update] REMOTE_DEFINITION. Useconda env [create|update] --file=URLinstead. (#14158 via #14160) - Mark
conda.testing.integration.BIN_DIRECTORYas pending deprecation. Useconda.common.path.BIN_DIRECTORYinstead. (#14188) - Mark
conda.common.path.get_bin_directory_short_path()as pending deprecation. Useconda.common.path.BIN_DIRECTORYinstead. (#14188) - Mark
conda.common.path.is_private_env_nameas pending deprecation. (#14189) - Mark
conda.common.path.is_private_env_pathas pending deprecation. (#14189) - Mark
conda shell.SHELL commandsas pending deprecation. Useconda commandsinstead. (#14215) - The
defaultsmultichannel will stop being the (implicit) default value forchannels. Users relying on this behavior are encouraged to runconda config --add channels defaults. This is pending deprecation, and will be fully deprecated in 25.3. (#14178 via #14227) conda config --add/--append channels ...will warn whendefaultsis implicitly added. Inconda 25.3, this behavior will be removed and users should runconda config --add/--append channels defaultsexplicitly if needed. Conda distribution installers like miniforge or miniconda will pre-configure conda channels during installation. (#12356 via #14227)- Without an explicit
channelsconfiguration (viacondarcfiles, environment variables, or CLI flags), conda will warn about usingdefaultsimplicitly. In 25.3, an empty list will be used. (#14227) - Mark the
restore_free_channelconfiguration option as pending deprecation. Addhttps://repo.anaconda.com/pkgs/freeto your channel list afterdefaultsinstead. (#14231 via #14269) - Mark
conda.testing.CondaCLIFixtureas pending deprecation. Useconda.testing.fixtures.CondaCLIFixtureinstead. (#14243) - Mark
conda.testing.conda_clias pending deprecation. Useconda.testing.fixtures.conda_cliinstead. (#14243) - Mark
conda.testing.PathFactoryFixtureas pending deprecation. Useconda.testing.fixtures.PathFactoryFixtureinstead. (#14243) - Mark
conda.testing.path_factoryas pending deprecation. Useconda.testing.fixtures.path_factoryinstead. (#14243) - Mark
conda.testing.TmpEnvFixtureas pending deprecation. Useconda.testing.fixtures.TmpEnvFixtureinstead. (#14243) - Mark
conda.testing.tmp_envas pending deprecation. Useconda.testing.fixtures.tmp_envinstead. (#14243) - Mark
conda.testing.TmpChannelFixtureas pending deprecation. Useconda.testing.fixtures.TmpChannelFixtureinstead. (#14243) - Mark
conda.testing.tmp_channelas pending deprecation. Useconda.testing.fixtures.tmp_channelinstead. (#14243) - Mark
conda.testing.context_aware_monkeypatchas pending deprecation. Useconda.testing.fixtures.context_aware_monkeypatchinstead. (#14243) - Mark
conda.testing.tmp_pkgs_diras pending deprecation. Useconda.testing.fixtures.tmp_pkgs_dirinstead. (#14243) - Mark
conda.testing.tmp_envs_diras pending deprecation. Useconda.testing.fixtures.tmp_envs_dirinstead. (#14243)
Docs
Other
- Update
xonshsupport to accomodate deprecated import path. (#14047)
Contributors
- @anki-code made their first contribution in #14047
- @beeankha
- @conda-bot
- @dholth
- @jaimergp
- @jezdez
- @kenodegard
- @zklaus
- @ForgottenProgramme
- @scw
- @SylvainCorlay made their first contribution in #14226
- @travishathaway
- @dependabot[bot]
- @pre-commit-ci[bot]
Full Changelog: 24.7.1...24.9.0