apache/beam · error · NotImplementedError
Execution of [ ] not implemented in runner .
Error message
Execution of [%s] not implemented in runner %s.
What it means
The DirectRunner's TransformEvaluatorRegistry walks the transform's MRO looking for a registered evaluator class. If none is found, get_evaluator raises NotImplementedError, meaning the DirectRunner has no local implementation for this PTransform type.
Solutions
- Replace the transform with a composable one built from supported primitives (ParDo, GroupByKey, etc.).
- Register a _TransformEvaluator for your transform class with the registry (subclass and extend _evaluators).
- Run the pipeline on a runner that supports the transform.
- Upgrade apache-beam — a newer DirectRunner may have added the evaluator.
Example fix
# before output = pcoll | MyCustomPrimitive() # after output = pcoll | beam.ParDo(MyDoFn()) # composed of supported primitives
Defensive patterns
Strategy: fallback
Validate before calling
from apache_beam.runners.direct.transform_evaluator import _TransformEvaluatorRegistry # assert your transform class (or an ancestor) has an evaluator before submitting
Type guard
def is_direct_runner_supported(t) -> bool:
from apache_beam.runners.direct import transform_evaluator as te
return any(cls in te._TransformEvaluatorRegistry._evaluators for cls in type(t).__mro__) Try / catch
try:
result = pipeline.run()
except NotImplementedError as e:
if 'not implemented in runner' in str(e):
rewrite_transform_with_supported_primitives() Prevention
- Compose transforms only from documented DirectRunner-supported primitives.
- Test pipelines with DirectRunner locally before shipping to any runner.
- Avoid unregistered custom PTransform primitives.
When it happens
Trigger: Applying a PTransform subclass (custom transform, external transform, or cloud-only primitive like a native Pub/Sub/BigQuery sink variant) to a pipeline executed with DirectRunner, where the transform class and all its bases are absent from _evaluators.
Common situations: Custom PTransform not registered with the DirectRunner; using cross-language/external transforms; transforms meant only for distributed runners; stale Beam version where a new primitive has no local evaluator.
Related errors
- DirectRunner: id_label is not supported for PubSub reads
- Expected a PTransform object, got
- Expecting a PCollection argument.
- PCollection not part of a pipeline.
- Root provider for [ ] not implemented in runner
AI-assisted analysis of apache/beam@12126d8942 (2026-09-13).
Data as JSON: /api/errors/aea1768fb0610585.
Report an issue: GitHub.
Appendix: source
Thrown at sdks/python/apache_beam/runners/direct/transform_evaluator.py:129
core.PTransform: DefaultRootBundleProvider,
_TestStream: _TestStreamRootBundleProvider,
}
def get_evaluator(
self, applied_ptransform, input_committed_bundle, side_inputs):
"""Returns a TransformEvaluator suitable for processing given inputs."""
assert applied_ptransform
assert bool(applied_ptransform.side_inputs) == bool(side_inputs)
# Walk up the class hierarchy to find an evaluable type. This is necessary
# for supporting sub-classes of core transforms.
for cls in applied_ptransform.transform.__class__.mro():
evaluator = self._evaluators.get(cls)
if evaluator:
break
if not evaluator:
raise NotImplementedError(
'Execution of [%s] not implemented in runner %s.' %
(type(applied_ptransform.transform), self))
return evaluator(
self._evaluation_context,
applied_ptransform,
input_committed_bundle,
side_inputs)
def get_root_bundle_provider(self, applied_ptransform):
provider_cls = None
for cls in applied_ptransform.transform.__class__.mro():
provider_cls = self._root_bundle_providers.get(cls)
if provider_cls:
break
if not provider_cls:
raise NotImplementedError(
'Root provider for [%s] not implemented in runner %s' %
(type(applied_ptransform.transform), self))View on GitHub (pinned to 12126d8942)