apache / apache/beam

Add deterministic coders for common Python types

Open
#20,927 0 comments 1 reaction 0 assignees View on GitHub
core improvement P3 python types
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
1d 20h
Merged PRs (30d)
196

Description

FastPrimitivesCodeImpl has "fallback" deterministic encoding of certain types in encode_special_deterministic. This encoding is not as efficient as a type-specific coder (https://github.com/apache/beam/pull/14455).

This bug is to implement type-specific coders for the types supported in encode_special_deterministic. This method will still handle encoding for cases in which type information is not available, and the new coders will be used where type hints are available.

Types to implement coders for: enum.Enum, dataclasses.dataclass, collections.namedtuple / typing.NamedTuple (verify there's no conflict/duplication with RowCoder)

Imported from Jira [BEAM-12136](https://issues.apache.org/jira/browse/BEAM-12136). Original Jira may contain additional context.
Reported by: udim.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.