Supported Architectures
Metaflow currently supports these architectures:linux-64
Linux x86_64Most common for cloud compute (AWS Batch, ECS)
osx-64
macOS IntelOlder Mac laptops/desktops
osx-arm64
macOS Apple SiliconM1/M2/M3 Macs
win-64
Windows x86_64Windows desktops (limited support)
How Cross-Platform Resolution Works
Local Resolution
When you run your flow or deploy it, Metaflow resolves environments on your local machine, not on remote nodes.
Architecture Detection
Metaflow detects the target architecture:
- For
--with batch:linux-64 - For local runs: Your current architecture
- For deployments: Target platform architecture
Platform-Specific Resolution
Conda/pip resolvers fetch packages for the target architecture, not your local one.
Pure Conda Packages
Pure Conda packages work seamlessly across platforms:cross_platform_conda.py
Metaflow automatically resolves for
linux-64 when using --with batch, even if you’re on a Mac.PyPI Wheel Packages
PyPI packages available as wheels also work cross-platform:How Wheel Selection Works
When resolving for a different architecture,pip uses platform-specific tags:
Metaflow automatically generates the correct platform tags based on:
- Python version
- Target architecture
- GLIBC version (for Linux)
GLIBC Considerations (Linux Only)
When resolving for Linux, Metaflow considers the GLIBC version:- AWS Batch Default
- Ubuntu 20.04
- Custom Override
Most AWS Batch environments use Amazon Linux 2:Wheels are selected to be compatible with GLIBC 2.26+.
Restrictions: Non-Wheel Packages
What Are Non-Wheel Packages?
Source Distributions
Packages that need compilation:
.tar.gzfiles.zipsource archives- Packages with C/C++/Rust extensions
VCS Packages
Packages from version control:
- Git repositories
- SVN repositories
- Mercurial repositories
Local Packages
Local file system packages:
- Local directories
- File:// URLs
- Development packages
Why They Fail
These require building on the target platform, but resolution happens on your local machine with different architecture.
Example of Failure
requirements_invalid.txt
Workarounds
- Use Wheels
- Build on Target Platform
- Resolve on Same Platform
Check if a wheel version exists:If not available, consider:
- Requesting wheel builds from maintainers
- Using a similar package that has wheels
- Switching to pure Conda mode
Mixed Mode Restrictions
In mixed Conda+PyPI mode, all PyPI packages must be wheels:env_mixed_invalid.yml
Platform-Specific Packages
Some packages are only available on certain platforms:Checking Wheel Availability
Before adding a package, check if wheels exist for your target platforms:manylinux2014_x86_64- Linuxmacosx_10_9_x86_64- macOS Intelmacosx_11_0_arm64- macOS Apple Siliconwin_amd64- Windows
Best Practices
Test Locally First
Run locally with
--environment=conda to catch resolution issues before deploying.Use Named Environments
Resolve once, then share the environment using aliases (see Environment Sharing).
Architecture Override
Manually specify target architecture:This is rarely needed as Metaflow automatically detects the correct architecture based on your execution context (
--with batch, argo-workflows, etc.).