Skip to content

Let users set a custom conda path for MFA (Windows)#149

Merged
BeckettFrey merged 1 commit into
developfrom
feature/windows-conda-path
Jun 30, 2026
Merged

Let users set a custom conda path for MFA (Windows)#149
BeckettFrey merged 1 commit into
developfrom
feature/windows-conda-path

Conversation

@BeckettFrey

Copy link
Copy Markdown
Member

Summary

MFA shells out to conda, which previously had to be on PATH or sit in one of a handful of hardcoded Windows install locations (~/miniconda3/Scripts/conda.exe, etc.). Users with a non-standard Anaconda/Miniconda install — common on Windows — had no way to point VoxKit at their conda.exe, and alignment/training would fail with a conda not found error.

This adds a user-configurable conda path.

Changes

  • Settings UI: new optional "Conda Path" field on the MFA align and train settings dialogs. Leave blank to keep the existing auto-detection.
  • services/mfa.py: _find_conda() now accepts an explicit path and also honors a VOXKIT_CONDA_PATH environment variable. Resolution order:
    1. configured path (settings dialog), if it exists
    2. VOXKIT_CONDA_PATH, if it exists
    3. conda on PATH
    4. common Windows install locations
  • The configured path is threaded through run_mfa_align, run_mfa_adapt, ensure_dictionary_downloaded, and _ensure_mfa_server_running.
  • Blank/whitespace values normalize to None, so the default behavior is unchanged for existing users.
  • Updated the conda not found error message to mention the new setting and env var.

Testing

  • New tests/services/test_mfa.py covers the _find_conda resolution precedence (explicit path, ~ expansion, env var, nonexistent-path fallback, PATH fallback).
  • invoke lint-check, invoke format-check, invoke mypy-check all pass.
  • tests/services + tests/engines pass (42 tests).

MFA shells out to conda, which previously had to be on PATH or in one of a
few hardcoded Windows install locations. Users with a non-standard
Anaconda/Miniconda install (common on Windows) had no way to point VoxKit at
their conda.exe.

- Add a "Conda Path" field to the MFA align and train settings dialogs.
- _find_conda() now accepts an explicit path and also honors a
  VOXKIT_CONDA_PATH env var, both taking precedence over auto-detection.
- Thread the configured path through the MFA service entry points
  (run_mfa_align, run_mfa_adapt, ensure_dictionary_downloaded,
  _ensure_mfa_server_running).
- Blank/whitespace settings normalize to None, preserving auto-detection.
- Add unit tests for the resolution precedence.

@BeckettFrey BeckettFrey left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

LGTM

@BeckettFrey BeckettFrey merged commit fb5553e into develop Jun 30, 2026
4 of 8 checks passed
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.

1 participant