We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 03842b6 commit c35d434Copy full SHA for c35d434
python/datafusion/context.py
@@ -82,6 +82,10 @@ class TableProviderExportable(Protocol):
82
def __datafusion_table_provider__(self) -> object: ... # noqa: D105
83
84
85
+# Type alias for objects accepted by read_table
86
+TableLike = Table | TableProviderExportable
87
+
88
89
class CatalogProviderExportable(Protocol):
90
"""Type hint for object that has __datafusion_catalog_provider__ PyCapsule.
91
@@ -1164,7 +1168,7 @@ def read_avro(
1164
1168
)
1165
1169
1166
1170
def read_table(
1167
- self, table: Table | TableProviderExportable
1171
+ self, table: TableLike
1172
) -> DataFrame:
1173
"""Creates a :py:class:`~datafusion.dataframe.DataFrame` from a table.
1174
0 commit comments