Skip to contents

condathis 0.2.0

condathis 0.2.0 adds pipelines and runs the environment and command functions through backends. It makes the exported functions consistent (one argument order, one rule for missing environments, one set of condition classes). It no longer changes the files of other Conda tools in your home directory, except the lines of its own environments in ~/.conda/environments.txt (see Bug fixes). Some changes break code written for 0.1.4: they come first, each with what to write instead.

Breaking changes

  • create_env() and install_packages() take package specs in ... and every other argument by name, as in create_env("python=3.13", env_name = "py-env"). packages = still works. It is deprecated: called from the console, a script or the tests of your own package, it warns once per session and function (class condathis_deprecated_packages_arg). Calls made inside other packages do not warn, except in tests that use testthat’s third edition, which sets lifecycle_verbosity = "warning". env_file = of create_env() is deprecated in the same way (class condathis_deprecated_env_file_arg): pass the file in ... with the new env_definition(), as in create_env(env_definition("environment.yml"), env_name = "tools").

  • Old positional calls no longer work: name every argument after the package specs, as in install_packages("pkg", env_name = "my-env"). When the last of two or more unnamed arguments names an existing environment, the call aborts and says so (class condathis_<function>_positional_env_name). Any other name is read as one more package spec, so the call fails unless a package has that name (install_packages() first creates a missing "condathis-env", empty). A spec that ends in .yml, .yaml, .json or .lock aborts with a hint to pass the file with env_definition(). A misspelled argument such as chanels = names the closest argument. Argument names are no longer abbreviated: abbreviations that 0.1.4 matched, such as pack =, over = or, in install_packages(), env =, now abort with a hint that names the full argument.

  • The default channels of create_env() and install_packages() is now "conda-forge" (it was c("conda-forge", "bioconda")). For bioconda packages, name the channel in the spec ("bioconda::samtools") or pass channels = c("conda-forge", "bioconda"). When channels is not given and a spec without a channel is on none of the channels, the error says that bioconda is no longer a default channel and names the "bioconda::" spec to use. With the default channels, an environment built from bioconda with 0.1.4 does not count as having a spec without a channel, such as "samtools": create_env("samtools", env_name = ...) aborts with class condathis_create_env_exists, and the error names the channel of the installed package. channels = NULL, character(0), NA and "" abort with class condathis_invalid_channels (in 0.1.4, NULL meant the default).

  • The default channel_priority of create_env() and install_packages() is now "strict" (it was "disabled"). Pass channel_priority = "disabled" for the old solver behavior.

  • create_env(overwrite = FALSE) never replaces an existing environment. It keeps it, with status 0, when it already has the requested packages or when nothing is requested. With an environment file, it keeps it only for a lock file whose packages it has exactly (see New features). Otherwise, it aborts with class condathis_create_env_exists: use install_packages() to add packages, or overwrite = TRUE to rebuild. In 0.1.4, it deleted and rebuilt the environment, which lost the packages added later.

  • create_env() aborts when package specs and an environment file are both given, and when channels, additional_channels or channel_priority is given with a lock file passed with env_definition(), such as an @EXPLICIT or conda-lock file (class condathis_create_env_conflicting_args). In 0.1.4, it ignored them. The deprecated env_file = still ignores them, as in 0.1.4. It also aborts, with platform and overwrite = FALSE, on an existing environment built for another platform (class condathis_create_env_platform_mismatch): pass overwrite = TRUE to rebuild it for that platform.

  • Missing environments are no longer created on the fly: create them with create_env() first. install_packages() into a missing environment, list_packages() of a missing "condathis-env", and run_bin() in a missing environment (it ran a same-name program from PATH) now abort. The error has class condathis_<function>_env_not_found (also condathis_env_not_found). run() and run_bin() give status 127 with error = "continue". Only the default "condathis-env" is created, empty, by install_packages(), run(), run_bin() and run_pipeline(), and only when it is the environment you asked for.

  • Environment names must be valid directory names on every OS. Names that are empty, . or .., start with - or end with . are invalid. So are names that contain a path separator, :, #, whitespace, a control character or <>"|?*, and Windows device names such as nul. They abort in every function (class condathis_invalid_env_name). env_path() still runs commands in an existing environment with such a name (its path is in list_envs()). To change one, create it again under a valid name and delete the old directory.

  • run_bin() is superseded by run(). It stays for code written for 0.1.4, and now runs a command exactly as run() does: it activates the environment, with the activate.d scripts of its packages. Pass the new activate = FALSE (see New features) to skip them, as 0.1.4 did. The command then also gets CONDA_PREFIX and the other variables of a fixed activation, which 0.1.4 left empty. A bare command name is looked up as run() does it, on the PATH of the command, so a directory that an activate.d script puts first wins (see Bug fixes). A name with a directory part is no longer joined to the bin directory of the environment: it is a path, as in run(). On Linux and macOS, a command killed by signal n has status 128 + n, as in run() and a shell (137 for SIGKILL), instead of -n.

  • The commands of run(), run_bin() and run_pipeline() no longer see the Python settings of the R session, with and without activate, so the python of an environment finds only its own modules: PYTHONPATH, PYTHONHOME, PYTHONUSERBASE, PYTHONSTARTUP, UV_PYTHON, UV_SYSTEM_PYTHON and UV_PROJECT_ENVIRONMENT are removed, PYTHONNOUSERSITE is 1 (your ~/.local packages are not on sys.path), and an activated virtual environment, also one that reticulate uses, is undone (see ?`condathis-options`). So that run("python", "-m", "pip", "install", ...) installs into the environment, PIP_USER and PIP_REQUIRE_VIRTUALENV are false (also over user and require-virtualenv in a pip configuration file), and PIP_TARGET, PIP_PREFIX and PIP_ROOT are removed (a target, prefix or root in a pip configuration file still applies); pass --target or --prefix to pip to install elsewhere. Your package index, credential, certificate and proxy settings still apply. To give a command a PYTHONPATH, set it in the command, as in run("env", "PYTHONPATH=/my/modules", "python", "script.py") on Linux and macOS, or add the directory to sys.path in the script.

  • run() starts the command itself instead of through micromamba run, so arguments reach it exactly as given. On Windows, cmd.exe re-parsed them (>, <, | and & became redirections, pipes and command separators, and ^ and % were dropped). Shell builtins such as dir and echo also worked: run a shell explicitly for them (see ?run). What activate.d scripts print is no longer part of the output. verbose = "cmd" shows your command, not micromamba’s. On Linux and macOS, a failing activate.d script aborts with class condathis_run_resolve_failed instead of a status error.

  • run() and run_bin() reject a cmd that is not a single, non-empty string, such as c("echo", "x") (class condathis_invalid_cmd). Pass the arguments of the command in .... NA in ... aborts with class condathis_<function>_invalid_args (0.1.4 passed the string "NA").

  • create_env(), install_packages(), remove_env(), clean_cache(), run() and run_bin() return a condathis_result object, which prints as a short summary. status, stdout, stderr and timeout work as before, and cmd, env_name and pid are new (pid is NA unless run() or run_bin() gets stdin = "|"). A stream that was not captured is now NA instead of NULL or "": test it with is.na(). as.list(res) gives a plain list.

  • get_install_dir() and list_envs() return a data frame (a tibble) instead of a character vector: use get_install_dir("micromamba")$path and list_envs()$env_name.

  • method is a new argument right after env_name in env_exists(), remove_env(), list_packages() and get_env_dir(), and the first argument of list_envs() and get_install_dir(). Pass verbose by name: list_envs("silent") and env_exists("x", "silent") abort with class condathis_invalid_method.

  • remove_env() now defaults to verbose = "output" and reports the removal: pass verbose = "silent" to keep it quiet. list_packages() now defaults to verbose = "silent" (pass verbose = "output" for the messages of 0.1.4) and always returns its tibble visibly.

  • env_exists() and get_env_dir() abort when env_name is not a single, valid name, such as NULL, NA, a number or several names (class condathis_invalid_env_name). In 0.1.4, env_exists() returned FALSE, and get_env_dir() returned one path per name. env_exists() now defaults to env_name = "condathis-env".

  • install_micromamba(): timeout_limit is renamed timeout, in the same position (timeout_limit still works, with a warning of class condathis_deprecated_arg). An explicit micromamba_version now replaces an installed binary of another version, and versions older than 2.8.1 abort with class condathis_install_micromamba_unsupported_version.

  • parse_output() keeps the text as the command wrote it: pass the new trim = TRUE for the 0.1.4 trimming of whitespace and blank lines. Lines end only at \n, \r\n or \r, and empty output gives character(0) instead of "", also with trim = TRUE: test for it with length(x) == 0L. stream = "both" aborts when neither stream was captured (it returned ""), and stream = "plain" aborts on NA (it returned "NA").

New features

  • Backends: the environment functions and the run family take method and dispatch to a backend. "micromamba" is built in, and gets every new environment unless you pass method or set the option condathis.backend_priority. "auto", the new default of method, uses the backend that owns an existing environment.

  • method = "rattler" uses the backend of the rattlerthis package, which is not on CRAN. The backends article on the package website shows how to install it. condathis loads it when it is installed, and aborts with class condathis_backend_not_installed otherwise. This backend never downloads micromamba. A backend that does not run the link scripts of packages, such as rattler, makes the call warn with class condathis_link_scripts_skipped.

  • Other packages can add a backend with the experimental register_backend() (see ?register_backend) and remove it with unregister_backend(). list_registered_backend_names() lists the backends, and backend_root_dir() gives the data directory of one.

  • New run_pipeline() and run_step() run a pipeline (cmd1 | cmd2) through operating system pipes, each command in its own environment if needed: run_pipeline(run_step("seq", "1", "3"), run_step("cat")). A command that ends because the next one stopped reading, as seq in seq 1 1000000 | head -n 1, does not count as a failure, also on Windows. Its status is 141 (128 plus the number of SIGPIPE), as in a shell. parse_output() reads the result. Here, supervise and cleanup_tree default to TRUE.

  • New env_path() refers to an environment created outside condathis by its directory, for run(), run_bin(), run_pipeline() and run_step(): run("python", "--version", env_name = env_path("/opt/envs/py")). condathis never changes such an environment.

  • New env_definition() gives create_env() an environment file, in ...: create_env(env_definition("environment.yml"), env_name = "tools"). The backend reads the file and detects its format from the contents, or takes it from format, as in env_definition("ci.lock", format = "conda-lock-v1"). The micromamba backend reads environment YAML files, lists of package specs, @EXPLICIT files, conda-lock files (version 1, with the option categories) and mambajs lock files. The name of the file does not matter, except that an environment YAML file must end in .yml or .yaml, and not in -lock.yml or -lock.yaml. A file that the backend cannot read, such as pixi.lock with micromamba, aborts before anything runs (class condathis_create_env_unsupported_definition). Other backends can read other formats (see ?register_backend). With method = "auto", a new environment goes to the first available backend that can read the file.

  • A lock file (@EXPLICIT, conda-lock or mambajs) is installed as it is, without a solve, and only for a platform it lists: platform, else the native platform, else the emulated one. When it lists none of them, create_env() aborts before anything runs (class condathis_create_env_platform_not_locked). A lock file of noarch packages installs on any platform. create_env(overwrite = FALSE) keeps an existing environment that has exactly the packages of the lock: the same names, versions and build strings. validate_env(env_definition(<lock>), env_name = ...) makes the same check. With error = "continue", its FALSE has the new attribute unexpected.

  • install_packages(env_definition("environment.yml"), env_name = ...) installs the packages of an environment file that is solved, such as an environment YAML file or a list of specs (with micromamba, micromamba install -f). A lock file aborts with class condathis_install_packages_unsupported_definition: create the environment again with create_env(..., overwrite = TRUE).

  • New validate_env() checks that an environment exists and has the requested package specs, using the same check as create_env(overwrite = FALSE). It returns TRUE invisibly, or aborts with class condathis_validate_env_unsatisfied (condathis_validate_env_env_not_found for a missing environment). With error = "continue", it returns FALSE instead.

  • New arguments of run() and run_bin(), also in run_pipeline():

    • timeout kills the command after that many seconds (status -9, class condathis_timeout_error).
    • input writes a character or raw vector to standard input with stdin = "|".
    • binary = TRUE returns stdout and stderr as raw vectors.
    • supervise and, on Linux, linux_pdeathsig end the command when R ends, even by a crash. cleanup_tree ends the processes that the command started when it finishes. All three default to FALSE in run() and run_bin().
    • activate = FALSE runs the command without any code of the backend and without the activate.d scripts and env_vars.d files of the packages. condathis then sets a fixed activation: CONDA_PREFIX, CONDA_DEFAULT_ENV, CONDA_SHLVL, MAMBA_SHLVL, the prompt modifiers, and the binary directories of the environment in front of PATH. The default, activate = TRUE, activates the environment with the backend.
    • run_bin() also gains method.
  • The errors of a failed or timed-out command of run(), run_bin() and run_pipeline() carry the fields status, stdout, stderr and timeout.

  • The micromamba backend records the activation of an environment (its activate.d scripts included) the first time a command runs in it in an R session. It reuses that activation, without running the scripts again, until the environment or the environment variables of the session change.

  • install_micromamba() checks each download against the SHA256 checksum published with the micromamba release. It tries the next mirror when the checksum does not match (warning class condathis_install_micromamba_checksum_mismatch). When no checksum can be read or no hash computed, it installs the binary and warns with class condathis_install_micromamba_checksum_unavailable (also when a function that needs micromamba installs it), unless verbose = "silent". The hash is computed with tools::sha256sum() on R 4.5.0 or later, else with the digest package or a sha256sum or shasum program, and on Windows also with certutil.

  • Windows on ARM64: a native ARM64 R gets the win-arm64 micromamba. create_env() falls back to win-64 packages, through x64 emulation, when a request cannot be installed for win-arm64.

  • create_env(), install_packages() and remove_env() lock the environment: another R session that changes it waits, and says so after two seconds (message class condathis_env_lock_waiting). clean_cache() and package installs of other sessions wait for each other.

  • New help pages ?`condathis-conditions` (condition classes and error fields) and ?`condathis-options` (options and environment variables).

Other changes

  • method = "native", the 0.1.4 default, still works as a deprecated alias for "micromamba". It warns once per session (class condathis_deprecated_method_native), and not for calls made inside other packages.

  • Every error has the class condathis_error and every warning condathis_warning, with classes for the function and the problem (see ?`condathis-conditions`). Messages changed too: match classes and error fields, not message text. The 0.1.4 classes are kept as extra classes until 1.0:

    • condathis_create_invalid_overwrite_arg is now condathis_create_env_invalid_overwrite.
    • condathis_create_missing_env_file is now condathis_create_env_missing_env_file.
    • condathis_error_env_remove is now condathis_remove_env_env_not_found.
    • condathis_list_packages_missing_env is now condathis_list_packages_env_not_found.
    • condathis_cmd_status_error is now condathis_micromamba_status_error, with the fields status and stderr.
    • condathis_install_error_missing_bzip2 (deprecated) is now condathis_install_micromamba_download_failed.
    • condathis_run_null_cmd is now condathis_run_invalid_cmd.
    • condathis_run_stdin_error is now condathis_run_invalid_stdin and condathis_run_bin_invalid_stdin.
    • condathis_run_status_error of run_bin() is now condathis_run_bin_status_error.
    • rlib_error_dots_named, for a named value in ... of run() and run_bin(), is now condathis_run_invalid_args and condathis_run_bin_invalid_args.
    • condathis_umamba_* is now condathis_micromamba_*.
  • Arguments are checked before anything runs. Invalid values of verbose, error, method, channel_priority, platform (with a suggestion, such as "linux-aarch64" for "linux-arm64") and env_file, and package specs such as NA or "", abort with classed errors that name your call. This happens before micromamba is installed or started. run() and run_bin() check stdin, stdout and stderr before the command starts.

  • Queries never install micromamba or create an environment: list_envs(), env_exists(), get_env_dir(), get_install_dir(), list_packages() and validate_env() (get_env_dir() and get_install_dir() create only the data directory). Without a usable micromamba, they read the data directory.

  • env_exists(), run(), run_bin() and run_pipeline() start no micromamba process to check that an environment exists: they read its directory. So env_exists(verbose = "cmd") no longer prints a micromamba command. With the recorded activation (see New features), a call of run() in an existing environment takes about as long as starting the command itself: about 20 ms on Linux, where run() of 0.1.4 took about 270 ms.

  • When a function needs micromamba and finds no usable binary, it says that it downloads one, naming the version and the path (message class condathis_micromamba_downloading), unless verbose = "silent".

  • The check that an existing environment has the requested packages (create_env(overwrite = FALSE), validate_env()) compares the name without case, the version, the build string, the channel and the platform. It also compares the version, build, build_number and channel bracket constraints. 0.1.4 compared only the name and the version. Channels compare without credentials or platform subdirectory. Specs for virtual packages, such as "__cuda=12", "__unix" or "__glibc>=2.17", are not compared: they describe the host, and the solver checks them when it creates the environment. So repeating create_env() with such a spec keeps the environment instead of aborting. create_env() and install_packages() still pass them to the backend.

  • A spec that condathis cannot compare as micromamba reads it never counts as satisfied. Examples are a bracket constraint other than these ([md5=...]), a regular expression as build string and some uses of *. The error names the spec (see ?create_env).

  • install_packages() warns (class condathis_install_packages_missing_previous_channels) when the environment has packages from a channel that the call leaves out. This happens, for example, with bioconda packages installed with the 0.1.4 default channels. Add that channel to channels or additional_channels.

  • list_packages() always has the columns name, version, build_number (integer), build_string, channel and platform. A failed listing aborts with class condathis_list_packages_failed.

  • The password and the token of a URL, such as a channel URL, show as *****, as micromamba shows them. This holds in the command line that verbose = "cmd" and "full" print, in the cmd of results, in messages, warnings and errors, and in list_packages(). The command still gets them, and stdout and stderr of results keep them.

  • with_sandbox_dir() returns the value of code. It also redirects XDG_CONFIG_HOME, XDG_STATE_HOME and R_USER_CONFIG_DIR, and stops the processes that condathis started in it. .local_envir is now only the environment that code runs in.

  • condathis keeps files of its own in its data directory (condathis-micromamba.yaml and the directories cache, home, locks and channels) and in a .condathis directory in each environment that it creates.

  • Messages use cli’s success and information bullets instead of !, and spell “successfully” correctly. create_env() says that an existing environment “already has the requested packages” instead of “already exists”.

  • micromamba 2.10.0-0 is installed by default (it was 2.8.1-0). Versions from 2.8.1 on still work, and condathis reads the listing format of micromamba 2.9 and later.

  • install_micromamba() installs micromamba on Linux on RISC-V (linux-riscv64), where micromamba has builds from version 2.9.0 on.

  • condathis now imports filelock (>= 1.0.3) and ps (>= 1.9.3). It needs cli (>= 3.4.0), fs (>= 1.6.7), processx (>= 3.9.0), rlang (>= 1.1.0), stringr (>= 1.5.0) and withr (>= 3.0.2). On Windows and macOS with R 4.3, and on Apple silicon Macs with R 4.4, some of them install from source (see the README). It suggests digest, which checks the micromamba download on R older than 4.5.0 when it is installed.

Bug fixes

  • condathis no longer changes the files of other Conda tools in your home directory, except the lines of its own environments in ~/.conda/environments.txt (see below):

    • create_env() no longer deletes ~/.mamba (%APPDATA%\.mamba on Windows) when it has no pkgs subdirectory.
    • micromamba and the commands of its environments use only the condathis package cache, and clean_cache() deletes only the caches of condathis. It deleted the shared ~/.mamba/pkgs cache and the whole ~/.cache/conda directory. It no longer installs micromamba when there is no package cache to clean.
    • micromamba keeps its repodata cache in the condathis data directory, not in ~/.cache/conda, and run() leaves no mamba/proc directory in your cache directory.
    • Listing and removing environments no longer rewrite ~/.conda/environments.txt: remove_env() deletes only the line of the environment it removed. create_env() adds the environment to the file only when micromamba needs your home directory, such as for saved channel credentials, or pip settings or credentials for the pip packages of an environment file (see ?get_install_dir).
    • On Windows, packages no longer add Start Menu shortcuts. Shortcuts that 0.1.4 added stay after remove_env().
  • condathis no longer changes the environment variables of the R session while a command runs. In 0.1.4, R code that ran meanwhile, such as a condition handler, saw the R_HOME, TMPDIR, CONDA_* and MAMBA_* values of the child process, and for run_bin() its PATH.

  • The processes that condathis starts no longer get the activation of the R session. When R runs in an activated Conda or pixi environment, or in several nested ones, the binary directories of those environments are removed from PATH, and their variables (such as CONDA_PREFIX_1, CONDA_EXE and PIXI_PROJECT_ROOT) are removed or restored (see ?`condathis-options`). A program of R’s own environment so no longer runs in place of one that the environment lacks, with and without activate. On Windows, a command that is itself a program of R’s own Conda environment, such as R’s own Rscript, still gets that environment’s directories, at the end of its PATH, to load its DLLs. The commands of run(), run_bin() and run_pipeline() always run in exactly one activated environment: CONDA_SHLVL and MAMBA_SHLVL are 1 and the prompt modifiers are empty, with every backend and in both activate modes. The activation of an environment no longer records the activation of a micromamba that a wrapper, such as a pixi global binary, started (CONDA_SHLVL=2, CONDA_PREFIX_1). A micromamba path that is a pixi global binary (in the condathis.micromamba_path option, CONDATHIS_MICROMAMBA_PATH or on PATH) runs the micromamba it starts, so the activation of an environment has micromamba’s condabin directory on PATH and its own MAMBA_EXE. When R was started through a pixi global binary, the variables that the binary set, such as the compiler variables CC, CFLAGS and CONDA_BUILD_SYSROOT of R’s environment, are removed too. An activated Python virtual environment, also one that reticulate set in the R session, is undone: its bin (Scripts) directory leaves PATH, and VIRTUAL_ENV is removed. When reticulate has started Python in the R session, the lib directories it put in front of LD_LIBRARY_PATH (Linux) are removed, and so are the directories of a Conda python that it put in front of PATH, so a command no longer loads that python’s libraries or runs its programs. reticulate’s other changes stay (see ?`condathis-options`).

  • The processes that condathis starts no longer get what R’s own startup set. Every R_* and _R_* variable is removed, also one you set, such as R_LIBS_USER, so an R of the environment never loads packages built for your R. R_HOME is now unset, not "". R’s default EDITOR, PAGER, MAKE, SED, TAR and LN_S are removed, as are R’s directories in front of LD_LIBRARY_PATH (Linux) and DYLD_FALLBACK_LIBRARY_PATH (macOS), and on Windows R’s CURL_CA_BUNDLE and the Rtools directories in front of PATH. A value you set yourself stays (see ?`condathis-options`).

  • On Windows, run(), run_bin() and run_pipeline() look a bare command name up as cmd.exe does: in the working directory, then on the PATH of the command, with the extensions of PATHEXT. processx searched the folder of R’s own executable and the PATH of the R session instead, so a name that the environment lacked could run a program of R or of the environment R runs in. A name found nowhere now fails with status 127, as on Linux and macOS.

  • with_sandbox_dir() restores the working directory and every environment variable, those that code set included, and deletes the sandbox before it returns, also after an error (on Windows, also when it holds a junction). At top level, as in examples, 0.1.4 kept HOME and the data directories redirected for the rest of the session. It also kept the sandbox on disk.

  • micromamba now works when its default root prefix ($XDG_DATA_HOME/mamba, else ~/.local/share/mamba) exists but is not a Conda environment. In 0.1.4, no command worked then.

  • condathis works when the path of its data directory has a /t/<name>/ part, which micromamba 2.9.0 and later hide as an anaconda.org token. With such a micromamba, 0.1.4 failed there with “Failed to realize”.

  • Errors of micromamba commands show micromamba’s message and the exit status. 0.1.4 ran micromamba with --quiet, which hid the message below verbose = "full".

  • A failed or interrupted create_env() no longer deletes the environment it replaces: the environment is moved aside first and moved back. A failed create of a new environment no longer leaves an empty environment behind.

  • On Windows, interrupting create_env() or install_packages() also stops the programs that micromamba started, such as pip.

  • On Windows, a run() that is interrupted or runs out of time no longer leaves micromamba’s batch files (mamba_act*.bat, mamba_bat_*.bat) in %TEMP%: micromamba writes its temporary files to a directory that condathis deletes when the call returns.

  • remove_env() and create_env() no longer delete directories outside the environments directory (env_name = "" deleted every environment, and ".." the whole data directory). They delete only a directory that is exactly <root>/envs/<env_name>: on Windows and macOS, a name that differed in case could delete another environment. remove_env() no longer deletes the leftover directory of a name that micromamba does not list.

  • When the envs directory of the data directory is a symbolic link (on Windows, a junction), for example to a larger disk, its environments are found. 0.1.4 did not list them, and create_env() deleted such an environment before it created it again.

  • The check that an existing environment has the requested packages no longer hangs on a * after an operator ("zlib>=1.2.*"). It no longer counts "zlib=1.3.*.*", "zlib~=1" or "zlib>=1.2," as satisfied by versions that micromamba does not match. It no longer treats version numbers above 2147483647 as equal to any other.

  • install_packages() installs packages for the platform of the environment, not for the platform of micromamba. An environment created through Rosetta 2, for example, gets osx-64 packages.

  • On Apple Silicon, the Rosetta 2 fallback of create_env() checks the whole request, with its dependencies and its environment file, and its messages follow verbose. The first install into an environment with only noarch packages, such as a new "condathis-env", gets the same fallback.

  • With micromamba, a conda-lock file whose name did not end in -lock.yml or -lock.yaml, or a conda-lock file without packages for the platform, gave an empty environment and reported success. condathis now reads the format from the contents of the file, and checks its platforms before anything runs. A lock file that lists packages but gives an empty environment aborts with class condathis_create_env_failed.

  • list_envs():

    • lists an environment named "condathis" (it was hidden, and create_env() or remove_env() with that name deleted it).
    • no longer fails on a stale entry of ~/.conda/environments.txt.
    • matches the data directory as a path prefix instead of a regular expression.
    • lists an environment reached through a symbolic link once.
    • no longer prints micromamba’s JSON with verbose = "output".
  • list_packages() lists only the pip packages of the environment, not those of your user site directory or PYTHONPATH, whatever your pip settings and working directory: a pip directory in the working directory of R no longer runs in place of the environment’s pip.

  • create_env() and install_packages() install the pip: section of an environment file into the environment, whatever your Python and pip settings. pip skipped packages found in PYTHONPATH or your user site directory, installed into your user site directory with PIP_USER or user = true in a pip configuration file, and failed with PIP_REQUIRE_VIRTUALENV; uv installed into the virtual environment of VIRTUAL_ENV or the python of UV_PYTHON. Your package index, credential, certificate and proxy settings still apply (see ?`condathis-options`).

  • create_env() and install_packages() install the pip: section of an environment file in a directory you cannot write to, such as one installed with a package. micromamba writes a temporary file next to the environment file, so pip failed. condathis now passes a copy of the file, unless the section names paths relative to the file (-r requirements.txt, -e ., ./pkg): then it aborts with class condathis_micromamba_env_file_dir_not_writable.

  • run() and run_bin() write numbers in ... in full: run("head", "-n", 100000) passes "100000", not "1e+05".

  • On Windows, run(), run_bin() and run_pipeline() find the programs of an environment in Library/bin, Scripts and the other directories that activation adds to PATH, with the extensions of PATHEXT. 0.1.4’s run_bin() looked only in bin. On Linux and macOS, run_bin() no longer resolves the symbolic links of a program, which changed argv[0] of multicall programs such as busybox.

  • install_micromamba():

    • no longer creates "condathis-env".
    • replaces an installed binary only with a download that runs, reports its version and matches the checksum, also with force = TRUE. A bad download, such as an HTML error page or a truncated archive, no longer breaks a working installation or reports success. The next mirror is tried instead.
    • extracts the archive with R’s internal tar, so every mirror works without a system tar and bzip2.
    • applies timeout also with the curl package.
    • takes Inf as no limit (it made every download fail without curl).
    • lowers a limit above 2147483 seconds (about 24.8 days) to that value.
    • no longer tries the micro.mamba.pm mirror, which serves only the latest release.
    • on Windows, no longer reports a new binary that antivirus software still holds as missing.
  • micromamba discovery skips a broken candidate, such as a stale CONDATHIS_MICROMAMBA_PATH, a directory or a truncated binary, instead of failing.

  • A local channel in a directory whose path has a space works with create_env() and install_packages() (micromamba failed with “Failed to parse URL”).

  • run() and run_bin() no longer return an object named px_res from your workspace when the command cannot start under error = "continue". parse_output() no longer returns a variable named raw_text from your workspace. With stream = "both", it no longer joins the last line of stdout with the first line of stderr.

  • condathis works on R 4.3: %||% is now imported from rlang.

condathis 0.1.4

CRAN release: 2026-06-19

Release Date: 2026-06-19

Development Changelog: 0.1.4

Added

  • New channel_priority argument in create_env() and install_packages() to control channel priority strategy.

  • Condathis now supports system installed micromamba binaries. For that we added 1 new option and 1 environment variable to control that behavior. condathis.micromamba_path and "CONDATHIS_MICROMAMBA_PATH" respectively. The order of discovery is as follows:

    • User override via getOption("condathis.micromamba_path").
    • User override via CONDATHIS_MICROMAMBA_PATH environment variable.
    • condathis internal managed path (micromamba_bin_path()).
    • R-in-conda: micromamba adjacent to R’s own installation prefix.
    • Active conda environment (CONDA_PREFIX).
    • condathis managed micromamba-env fallback.
    • System PATH (Sys.which("micromamba")).

Changed

  • Internal micromamba version bump to “2.8.1-0”.

  • clean_cache() now also removes any additional cache files created in the path reported by tools::R_user_dir(package = "condathis", which = "cache").

  • Order of channels argument changed to have "conda-forge" as the first option as for using channel_priority = "strict" the order of the channels matters. Note that relying solely on channel order for priority is not recommended. Use explicit syntax like: bioconda::samtools==X.Y.Z for better guarantee of reproducibility.

  • create_env() now properly parses MatchSpec version constraints strings to define if environment needs to be recreated using new internal functions parse_match_spec() and version_spec_contains() to parse Conda MatchSpec and use VersionSpec to compare versions, following CEP29 and CEP33, respectively.

Fixed

  • Fix error in create_env() when packages were specified with "channel::package" environment was always recreated.

condathis 0.1.3

CRAN release: 2025-11-08

Release Date: 2025-11-07

Development Changelog: 0.1.3

Added

  • New clean_cache() function to clean the local package cache.

  • New verbose = "spinner" strategy to show only spinner animation in interactive sessions. Spinner is always silenced in non-interactive sessions.

Changed

  • Internal micromamba version bump to “2.3.3-0”.

  • Argument verbose = TRUE is now converted to verbose = "output" by default in all exported functions.

  • Argument verbose in create_env(), run(), run_bin(), and install_micromamba() are set to verbose = "output" by default. All internal calls to other functions are kept as "silent", unless when calling the user-facing function with verbose = "full".

  • Argument verbose = "silent" now also silences the spinner animation in interactive sessions.

Fixed

  • Ignore CONDA_ENVS_DIRS environment variable.

condathis 0.1.2

CRAN release: 2025-06-02

Release Date: 2025-06-02

Development Changelog: 0.1.2

Added

  • New stdin argument to run() and run_bin() functions, allowing input to be redirected via standard input (stdin) via a text file for commands that require it.

  • Argument verbose included in install_micromamba() and other auxiliary functions, allowing message suppression in all package functions.

Changed

  • Internal micromamba version bump to “2.1.1-0”.

  • with_sandbox_dir() now also defines temporary cache directory paths, using R_USER_CACHE_DIR and XDG_CACHE_HOME environment variables.

Fixed

  • Fix parsing of error messages with curly braces in run() and run_bin(), in the rethrown error, when error = "cancel".

condathis 0.1.1

CRAN release: 2025-01-23

Release Date: 2025-01-24

Development Changelog: 0.1.1

Changed

  • Internal micromamba version bump to “2.0.5-0”.

Fixed

  • Fix error in run_bin() when error = "continue" and cmd is not on PATH nor in the environment. The expected behavior is to not fail (#23).

  • Fix error in create_env() that would fail if debris from failed installation attempts were left in the environment path.

condathis 0.1.0

CRAN release: 2024-12-11

Release Date: 2024-12-10

Development Changelog: 0.1.0

Added

  • Initial submission to CRAN.
  • New Package Logo.

Fixed

  • run() always creates empty base environment if it does not exists yet.

condathis 0.0.8

Breaking changes

  • env_exists() now errors if no argument is supplied.

  • The base directory path used for creating the environments is now controlled by tools::R_user_dir() and accepts R_USER_DATA_DIR, and XDG_DATA_HOME, respectively as environment variables that can control that path. On Unix/Linux it should be "${HOME}/.local/share/R/condathis".

  • The default TMPDIR for all run() and run_bin() calls is cleaned after execution.

  • All error messages are resurfaced in the exported function call instead of being thrown in the internal processx call.

  • New classes were added to the error condition in most functions.

New features

Minor improvements and fixes

condathis 0.0.7

New features

  • install_micromamba() now tries to download an uncompressed version of the ‘micromamba’ binary if untar() fails because of missing bzip2 system library. (#10 and #14)

  • New parse_output() parses lines output streams from run() results into character vectors.

  • New run_bin() runs binary installed in a Conda environment without wrapping in micromamba run.

Minor improvements and fixes

condathis 0.0.6

Breaking changes

  • method = "auto" no longer exists. For backward compatibility will fall back to method = "native".
    • All container back-end methods were removed and method = "native" is the only method supported using just this package.
    • A method for supplying additional backends from other packages is planned to be implemented.

Minor improvements and fixes

  • Remove dependency on dockerthis.

  • Fix error in run() when verbose argument was not supplied.

condathis 0.0.5

Breaking changes

  • verbose, levels TRUE and FALSE are now soft deprecated. For previous functionality "full" and "silent" should be used respectively.

New features

  • run() now has error argument.

Minor improvements and fixes

  • run() output now has class "condathis_run_output" with custom print method.
  • run() now exposes stderr.
  • verbose now accepts any of c("silent", "full", "cmd", "output"). TRUE and FALSE are deprecated but still kept for compatibility.
  • Improved error handling in run() when invalid arguments are provided.

condathis 0.0.4

Breaking changes

  • create_env() new argument default overwrite = FALSE, since the previous behavior would allow for the environment to always be overwritten. For previous behavior use overwrite = TRUE.

  • Across the entire package verbose = FALSE is default.

New features

  • New get_env_dir() retrieves path to environment (v0.0.3.9032).

  • create_env() now has overwrite = FALSE argument (v0.0.3.9030).

  • install_micromamba() now has micromamba_version argument (v0.0.3.9025).

  • Add support for internal micromamba versions above v2.0 (v0.0.3.9024).

  • New remove_env() created (v0.0.3.9012 #7).

Minor improvements and fixes

  • native_cmd() now uses additional Environmental Variables for removing warnings when calling nested micromamba run (v0.0.3.9029 #13).

  • Standardize argument order passed to micromamba, since v2.0, order of some arguments starts to conflict (v0.0.3.9027).

  • On Windows, the “BAT” file used by micromamba run is renamed (v0.0.3.9026 #11).

  • Internal micromamba version is upgraded to “2.0.2-0”, fixes warnings about missing prefixes (v0.0.3.9028).

  • The internal micromamba version is now fixed (currently “v2.0.1-0”) (v0.0.3.9025).

  • Use GitHub releases as the primary URL for installing micromamba (v0.0.3.9025).

  • Move --no-rc and --no-env arguments to native_cmd() (v0.0.3.9024).

  • Fix path handling in Windows (v0.0.3.9023).

  • Add mode = "wb" to internal download.file() for handling binary downloads in Windows (v0.0.3.9023).

  • list_envs() and list_packages() use --no-rc internally (v0.0.3.9022).

  • create_env_*(), packages_search_*(), and install_packages() now uses --no-rc and --override-channels (v0.0.3.9020).

  • Remove “defaults” channel (-c defaults) from all functions (v0.0.3.9020).

  • create_env_*(), packages_search_*(), and install_packages() uses --no-channel-priority internally (v0.0.3.9019).