Skip to content

Fix Conda build failure due to missing conda-build in GitHub Actions environment#342

Merged
harryswift01 merged 1 commit into
mainfrom
341-bug-github-actions-conda-build-fails
May 15, 2026
Merged

Fix Conda build failure due to missing conda-build in GitHub Actions environment#342
harryswift01 merged 1 commit into
mainfrom
341-bug-github-actions-conda-build-fails

Conversation

@harryswift01
Copy link
Copy Markdown
Member

@harryswift01 harryswift01 commented May 14, 2026

Summary

This PR addresses a GitHub Actions CI issue where Conda tooling (e.g. conda-build) is installed but not reliably available during workflow execution due to inconsistent environment activation across steps.


Changes

Standardised Conda environment activation in CI:

  • Ensured Conda environments are consistently activated across all workflow steps
  • Configured setup-miniconda to reliably activate the intended environment (e.g. base or target env)
  • Enabled automatic environment activation to prevent step-to-step state loss
  • Added basic sanity checks (e.g. conda list, conda build --help) to verify Conda tooling availability during CI runs
  • Improved reproducibility of Conda-based builds in GitHub Actions

Impact

  • Improves reliability of Conda-based CI workflows across repositories
  • Eliminates intermittent failures caused by environment activation inconsistencies
  • Aligns CI behaviour more closely with local development environments
  • Makes Conda setup issues easier to detect and debug early in pipeline execution
  • Provides a standard pattern that can be reused across multiple repositories in the organisation

@harryswift01 harryswift01 requested a review from jimboid May 14, 2026 14:56
@harryswift01 harryswift01 self-assigned this May 14, 2026
@harryswift01 harryswift01 added the bug Something isn't working label May 14, 2026
@harryswift01 harryswift01 added this to the 2.2.4 milestone May 14, 2026
Copy link
Copy Markdown
Member

@jimboid jimboid left a comment

Choose a reason for hiding this comment

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

Looks like this fixes the issue. Not sure why it would be intermittent though but the fix here makes sense.

@harryswift01 harryswift01 merged commit dc1eb0d into main May 15, 2026
23 checks passed
@harryswift01 harryswift01 deleted the 341-bug-github-actions-conda-build-fails branch May 15, 2026 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: GitHub Actions: conda build fails with “invalid choice: 'build'” after installing conda-build

2 participants