apache/beam · error · Exception
Dataflow runner currently supports Python versions
Error message
Dataflow runner currently supports Python versions %s, got %s.%s. To ignore this requirement and start a job using an unsupported version of Python interpreter, pass --experiment use_unsupported_python_version pipeline option.
What it means
Raised when a pipeline is submitted to Dataflow with a Python interpreter version not in _PYTHON_VERSIONS_SUPPORTED_BY_DATAFLOW. The check runs during client initialization (via __init__), and an escape hatch is offered: the use_unsupported_python_version experiment. This prevents launching jobs whose worker harness image may not exist for that Python version.
Solutions
- Run the pipeline with a supported Python interpreter, e.g. create a venv with python3.11.
- Pin the CI/venv Python to a version in _PYTHON_VERSIONS_SUPPORTED_BY_DATAFLOW for the installed Beam release.
- If you accept the risk, add --experiment=use_unsupported_python_version to pipeline options.
- Upgrade or downgrade the apache-beam package to a release that supports your Python version.
Example fix
// before python3.14 -m my_pipeline --runner DataflowRunner // after python3.11 -m my_pipeline --runner DataflowRunner # or, deliberately bypass: # --experiment=use_unsupported_python_version
Defensive patterns
Strategy: validation
Validate before calling
import sys
SUPPORTED = {(3, 9), (3, 10), (3, 11), (3, 12)}
if (sys.version_info[0], sys.version_info[1]) not in SUPPORTED and \
'use_unsupported_python_version' not in (debug_options.experiments or []):
sys.exit('Unsupported Python for Dataflow: use a supported interpreter') Try / catch
try:
client = DataflowApplicationClient(pipeline_options)
except Exception as e:
if 'supports Python versions' in str(e):
sys.exit('Re-run with a supported pythonX.Y interpreter')
raise Prevention
- Pin the CI/venv Python version to one supported by your apache-beam release.
- Check Beam's supported Python matrix before upgrading local Python.
- Prefer upgrading apache-beam over using the bypass experiment.
When it happens
Trigger: Running Pipeline.run() with DataflowRunner using e.g. a too-new Python (3.14) or an EOL version the Dataflow service no longer supports, without the bypass experiment flag.
Common situations: Local venv upgraded to a new Python release before Beam/Dataflow added support; CI images bumping Python; following Beam docs that lag behind a new Python release.
Understand the failure class
Background: "unsupported platform" / "not supported on this platform" errors: what they mean and how to fix them — this error's family across 47 libraries.
Related errors
- Can not query metrics. Job id is unknown.
- Coder for the GroupByKey operation
- CombineFn.setup and CombineFn.teardown are not supported…
- Could not find element
- Could not translate the internal step name %r.
AI-assisted analysis of apache/beam@12126d8942 (2026-09-13).
Data as JSON: /api/errors/3aa15abcc79897c8.
Report an issue: GitHub.
Appendix: source
Thrown at sdks/python/apache_beam/runners/dataflow/internal/apiclient.py:1266
def get_response_encoding():
"""Encoding to use to decode HTTP response from Google APIs."""
return 'utf8'
def _verify_interpreter_version_is_supported(pipeline_options):
if ('%s.%s' % (sys.version_info[0], sys.version_info[1])
in _PYTHON_VERSIONS_SUPPORTED_BY_DATAFLOW):
return
if 'dev' in beam_version.__version__:
return
debug_options = pipeline_options.view_as(DebugOptions)
if (debug_options.experiments and
'use_unsupported_python_version' in debug_options.experiments):
return
raise Exception(
'Dataflow runner currently supports Python versions %s, got %s.%s.\n'
'To ignore this requirement and start a job '
'using an unsupported version of Python interpreter, pass '
'--experiment use_unsupported_python_version pipeline option.' % (
_PYTHON_VERSIONS_SUPPORTED_BY_DATAFLOW,
sys.version_info[0],
sys.version_info[1]))
View on GitHub (pinned to 12126d8942)