Amer-Mukhtar opened a new pull request, #6833: URL: https://github.com/apache/texera/pull/6833
Description What changes were proposed in this PR? - Add `amber/src/test/python/core/models/schema/test_attribute_type_utils.py`, a new pytest spec for the Python worker's `attribute_type_utils`, which previously had no dedicated unit tests. - Cover `detect_attribute_type_from_arrow_field`: every supported Arrow type, timestamps across all four units, the `texera_type: LARGE_BINARY` metadata marker taking precedence over the Arrow type, metadata that doesn't mark large binary falling back to the type mapping, and unmapped Arrow types raising `KeyError`. - Cover `create_arrow_field_with_metadata`: every `AttributeType`, metadata attached only for `LARGE_BINARY`, attribute names preserved verbatim (empty, unicode, emoji, long), and non-`AttributeType` input raising `KeyError`. - Cover round trips, including that stripping the metadata off a `LARGE_BINARY` field degrades it to `STRING`. Any related issues, documentation, discussions? Closes: #6635 How was this PR tested? - Run: `cd amber && pytest src/test/python/core/models/schema/test_attribute_type_utils.py -v`, expect all 67 tests passing. - Coverage of the module is 100% (12/12 statements) via `--cov=core.models.schema.attribute_type_utils`. - Verified the tests catch regressions by temporarily breaking the module: ignoring metadata during detection fails 6 tests, attaching metadata to every field fails 15. - Test-only change; no production code is modified. Was this PR authored or co-authored using generative AI tooling? Co-authored with Claude -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
