Skip to content

Commit 3ef1109

Browse files
docs: Add troubleshooting for Python version validation errors (#580)
Co-authored-by: promptless[bot] <179508745+promptless[bot]@users.noreply.github.com>
1 parent d555cd5 commit 3ef1109

File tree

2 files changed

+34
-6
lines changed

2 files changed

+34
-6
lines changed

flash/cli/build.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,12 @@ Comma-separated list of packages to exclude from the build (e.g., `torch,torchvi
4545

4646
## What happens during build
4747

48-
1. **Function discovery**: Finds all `@Endpoint` decorated functions.
49-
2. **Grouping**: Groups functions by their endpoint configuration.
50-
3. **Manifest generation**: Creates `.flash/flash_manifest.json` with endpoint definitions.
51-
4. **Dependency installation**: Installs Python packages for Linux x86_64.
52-
5. **Packaging**: Bundles everything into `.flash/artifact.tar.gz`.
48+
1. **Python version validation**: Verifies your local Python version is supported (3.10, 3.11, or 3.12).
49+
2. **Function discovery**: Finds all `@Endpoint` decorated functions.
50+
3. **Grouping**: Groups functions by their endpoint configuration.
51+
4. **Manifest generation**: Creates `.flash/flash_manifest.json` with endpoint definitions.
52+
5. **Dependency installation**: Installs Python packages for Linux x86_64.
53+
6. **Packaging**: Bundles everything into `.flash/artifact.tar.gz`.
5354

5455
## Build artifacts
5556

@@ -137,7 +138,6 @@ If a package doesn't have Linux x86_64 wheels:
137138

138139
1. Ensure standard pip is installed: `python -m ensurepip --upgrade`
139140
2. Check PyPI for Linux wheel availability.
140-
3. For Python 3.13+, some packages may require newer manylinux versions.
141141

142142
### Need to examine generated files
143143

flash/troubleshooting.mdx

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,34 @@ Duplicate route 'POST /process' in endpoint 'my-api'
177177

178178
**Solution:** Ensure each route is unique within an endpoint. Either change the path or method of one function.
179179

180+
## Build errors
181+
182+
### Unsupported Python version
183+
184+
**Error:**
185+
```
186+
Python 3.13 is not supported for Flash deployment.
187+
Supported versions: 3.10, 3.11, 3.12
188+
```
189+
190+
**Cause:** Flash requires Python 3.10, 3.11, or 3.12.
191+
192+
**Solution:**
193+
194+
Switch to a supported Python version using a virtual environment:
195+
196+
```bash
197+
# Using pyenv
198+
pyenv install 3.12
199+
pyenv local 3.12
200+
201+
# Or using uv
202+
uv venv --python 3.12
203+
source .venv/bin/activate
204+
```
205+
206+
Alternatively, use a Docker container with a supported Python version for your build environment.
207+
180208
## Deployment errors
181209

182210
### Tarball too large

0 commit comments

Comments
 (0)