Skip to content

feat: Python version constraints, GpuType migration, idle_timeout fixes#41

Merged
deanq merged 7 commits intomainfrom
deanq/ae-2391-python-versions-for-workers
Mar 10, 2026
Merged

feat: Python version constraints, GpuType migration, idle_timeout fixes#41
deanq merged 7 commits intomainfrom
deanq/ae-2391-python-versions-for-workers

Conversation

@deanq
Copy link
Member

@deanq deanq commented Mar 8, 2026

Summary

  • Document Python version constraints for deployed workers (GPU pinned to 3.12, CPU supports 3.10-3.12)
  • Migrate GpuGroup to explicit GpuType values in example worker files (e.g. GpuGroup.ADA_24 -> GpuType.NVIDIA_GEFORCE_RTX_4090)
  • Fix idle_timeout values and units (parameter is seconds, not minutes)
  • Correct GpuType enum names in docs to match actual SDK values

Changes

1. Python version documentation

  • Added "Python version in deployed workers" section to README
  • Set requires-python to >=3.10,<3.13 and runpod-flash to >=1.7.0

2. GpuGroup -> GpuType migration in worker files

  • Replaced GpuGroup.ADA_24 with GpuType.NVIDIA_GEFORCE_RTX_4090 in hello_world example
  • Note: GpuGroup.ANY and GpuGroup are intentionally kept in docs for troubleshooting and flexible GPU selection contexts (they remain valid SDK APIs)

3. GpuType naming corrections in docs

  • Fixed GpuType.NVIDIA_A100_80GB -> GpuType.NVIDIA_A100_80GB_PCIe (correct enum name)
  • Fixed GpuType.NVIDIA_H100_80GB -> GpuType.NVIDIA_H100_80GB_HBM3 (correct enum name)
  • Changed "GPU unavailable" quick fix to recommend GpuGroup.ANY or GpuType.ANY

4. idle_timeout and dependency fixes

  • Corrected idle_timeout units in README tables from minutes to seconds
  • Fixed config dict idleTimeout values in autoscaling workers to match decorator values
  • Changed README example idle_timeout=1 to idle_timeout=300 for consistency
  • Removed unnecessary dependency pins, added missing accelerate dependency

Test plan

  • flash run starts successfully with updated examples
  • All worker files import without errors
  • Verify idle_timeout config dict values match decorator values
  • Confirm all GpuType references use valid enum names from SDK

deanq added 4 commits March 8, 2026 09:47
GPU workers are pinned to Python 3.12 (torch/CUDA only installed for
3.12 in base image). CPU workers support 3.10-3.12. Build pipeline
handles wheel selection automatically.

Also bumps requires-python to <3.14 and runpod-flash to >=1.7.0.
Replace GpuGroup.ANY with explicit GpuType values (e.g.
GpuType.NVIDIA_GEFORCE_RTX_4090) across all examples, docs, and
contributing guide. Specific GPU types give users faster provisioning
and predictable behavior.
- idle_timeout is seconds, not minutes — update values accordingly
- Remove unnecessary workers/idle_timeout defaults from simple examples
- Unpin pandas/numpy versions for cross-Python-version compatibility
- Add missing accelerate dependency to SD example
- Add explicit workers to LB endpoints that need them
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the Flash examples/docs to reflect current runtime constraints (Python versions), standardize GPU selection guidance (favoring explicit GpuType values), and correct autoscaling idle_timeout configuration to use seconds.

Changes:

  • Document deployed-worker Python version constraints and tighten requires-python while bumping runpod-flash minimum version.
  • Replace many GpuGroup.ANY usages with explicit GpuType values in docs and examples.
  • Convert idle_timeout examples/docs to seconds, remove unnecessary defaults in simple examples, and relax dependency pins for broader Python compatibility.

Reviewed changes

Copilot reviewed 22 out of 22 changed files in this pull request and generated 13 comments.

Show a summary per file
File Description
pyproject.toml Constrains supported Python versions and bumps runpod-flash minimum version.
docs/cli/workflows.md Updates workflow snippets for GpuType usage and corrects idle_timeout examples.
docs/cli/troubleshooting.md Updates troubleshooting guidance to reference GpuType/GpuGroup and revised GPU availability guidance.
README.md Adds deployed-worker Python version notes and updates idle_timeout unit wording.
CONTRIBUTING.md Migrates contributing examples from GpuGroup.ANY to explicit GpuType usage.
CLAUDE.md Updates internal guide examples and symbol table to reflect GpuType usage.
05_data_workflows/01_network_volumes/gpu_worker.py Switches to GpuType, fixes idle_timeout units, and adds missing deps for the SD example.
05_data_workflows/01_network_volumes/cpu_worker.py Adds explicit idle_timeout for CPU worker.
04_scaling_performance/01_autoscaling/gpu_worker.py Migrates to GpuType and converts scale-to-zero timeout to seconds.
04_scaling_performance/01_autoscaling/cpu_worker.py Converts CPU scale-to-zero timeout to seconds.
04_scaling_performance/01_autoscaling/README.md Updates autoscaling reference/examples to match GpuType and new timeout semantics.
03_advanced_workers/05_load_balancer/gpu_lb.py Migrates GPU LB example to explicit GpuType and expands config for readability.
03_advanced_workers/05_load_balancer/cpu_lb.py Adds explicit workers to CPU LB endpoint configuration.
03_advanced_workers/05_load_balancer/README.md Updates load balancer docs to use GpuType in examples.
02_ml_inference/01_text_to_speech/gpu_worker.py Converts idle_timeout to seconds for GPU worker example.
01_getting_started/04_dependencies/cpu_worker.py Unpins pandas/numpy to improve cross-Python compatibility.
01_getting_started/04_dependencies/README.md Updates dependency guidance from strict pinning to constraints-based recommendations.
01_getting_started/03_mixed_workers/gpu_worker.py Removes unnecessary idle_timeout default from a simple GPU endpoint.
01_getting_started/03_mixed_workers/README.md Converts idle_timeout examples from minutes to seconds.
01_getting_started/02_cpu_worker/cpu_worker.py Removes unnecessary workers/idle_timeout defaults from the simplest CPU example.
01_getting_started/01_hello_world/gpu_worker.py Changes default GPU selection away from GpuGroup.ANY.
01_getting_started/01_hello_world/README.md Updates examples to use GpuType and refreshes guidance for choosing GPU types.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@deanq deanq changed the title docs: Python version constraints, GpuType migration, idle_timeout fixes feat: Python version constraints, GpuType migration, idle_timeout fixes Mar 9, 2026
@deanq deanq requested a review from Copilot March 9, 2026 07:49
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 22 out of 22 changed files in this pull request and generated 8 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

… examples

- Fix GpuType.NVIDIA_A100_80GB to NVIDIA_A100_80GB_PCIe across docs
- Fix GpuType.NVIDIA_H100_80GB to NVIDIA_H100_80GB_HBM3 in README
- Migrate hello_world gpu_worker from GpuGroup.ADA_24 to GpuType.NVIDIA_GEFORCE_RTX_4090
- Fix idle_timeout config dict mismatches in autoscaling workers
- Correct idle_timeout units from minutes to seconds in README tables
- Use GpuGroup.ANY for GPU unavailable troubleshooting quick fix
@deanq deanq merged commit f3e6727 into main Mar 10, 2026
6 checks passed
@deanq deanq deleted the deanq/ae-2391-python-versions-for-workers branch March 10, 2026 00:24
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.

4 participants