Skip to content

[Python] the type of ParquetLogicalType not correctly returned for Geometry/Geography #50849

Description

@jorisvandenbossche

Describe the bug, including details regarding any error messages, version, and platform.

When accessing the .type of the logical type of a Parquet schema for the new Geometry/Geography types, this still returns UNKNOWN instead of the correct type:

>>> meta = pq.read_metadata("./cpp/submodules/parquet-testing/data/geospatial/crs-default.parquet")
>>> meta.schema.column(1)
<ParquetColumnSchema>
  name: geometry
  path: geometry
  max_definition_level: 1
  max_repetition_level: 0
  physical_type: BYTE_ARRAY
  logical_type: Geometry(crs=)
  converted_type (legacy): NONE
>>> meta.schema.column(1).logical_type
<pyarrow._parquet.ParquetLogicalType object at 0x7fc53c3f2cd0>
  Geometry(crs=)
>>> meta.schema.column(1).logical_type.type
'UNKNOWN'

Component(s)

Python

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions