Array empty type - #2593
Open
norberttech wants to merge 5 commits into
Open
Conversation
- add EmptyArrayType with type_empty_array() DSL, detected for [] at
every depth
- keep list/map/structure detection byte-identical for all other inputs
- treat array{} like array<mixed> in type comparability
- project array{} onto json wherever an ETL Definition is built, column
and nested
- ParquetEncoder converts json/uuid leaves at any depth via schema-driven ValueConverters, not just top-level columns - arrow-ext reader returns canonical uuid strings for nested struct/list/map leaves - arrow-ext writer keeps extension metadata on map key/value fields, fixing a process abort on map<string, uuid|json> writes - writer schema mismatches now raise exceptions instead of panicking
- TypeProjection maps ArrayType to json, matching the array{} rule
- UnionTypeNormalizer collapsed to TypeProjection::union() delegation
- to_floe() no longer widens every inferred column to nullable; the footer schema is the first batch's union, so non-nullable declarations survive a round-trip - to_json()/to_json_lines() emit list/map/structure/array entries as nested JSON instead of escaped strings, normalizing nested datetime/interval/uuid/json/enum leaves
…ejects its own input - scalar values mixed with arrays no longer count as homogeneous lists/maps; they detect as array<mixed> - valueType() widens to array<mixed> instead of dropping types by order ([] still keeps a list/map element type)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change Log
Added
flow-php/types-array{}empty array type withtype_empty_array()DSL functionflow-php/etl-array<mixed>andarray{}project ontojsonat any schema depthFixed
flow-php/etl-adapter-parquet- nestedjsonanduuidvalues round-trip through parquet encode and decodeflow-php/arrow-ext- nesteduuidvalues read as canonical strings, map writes throw exceptions instead of aborting the processflow-php/etl- Floe inferred schema preserves first batch nullability instead of making every column nullableflow-php/types- array type detection never returns a type that rejects its own inputChanged
flow-php/etl-adapter-json-to_json()/to_json_lines()write list/map/structure/array entries as nested JSON instead of escaped stringsRemoved
Deprecated
Security