You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have some subclasses of pyarrow.lib.DataType, but we haven't been designing with the intent of writing isinstance(arr.type, pyarrow.TimestampType). We should think about the public API for such type-checking or other type of schema validation.
Phillip Cloud / @cpcloud:
The thing here is that it's hard to enforce only this usage. I removed this from the public API because it's too easy to have an unpleasant experience with these types. They are really only for wrapping their C++ counterparts and about the only thing useful you can do with them within Python is type checking. I think these should remain outside of the top level public API and be made public in one module deep (maybe pyarrow.types?).
Wes McKinney / @wesm:
I agree. Having a types module might be a good approach, possibly with some functions like pyarrow.types.is_integer, pyarrow.types.is_timestamp, etc.
We have some subclasses of
pyarrow.lib.DataType
, but we haven't been designing with the intent of writingisinstance(arr.type, pyarrow.TimestampType)
. We should think about the public API for such type-checking or other type of schema validation.Reporter: Wes McKinney / @wesm
Assignee: Wes McKinney / @wesm
PRs and other links:
Note: This issue was originally created as ARROW-1250. Please see the migration documentation for further details.
The text was updated successfully, but these errors were encountered: