This is an automated email from the ASF dual-hosted git repository.
jorisvandenbossche pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/main by this push:
new 9cb78addf7 GH-38683: [Python][Docs] Update docstrings for Time32Type
and Time64Type (#39059)
9cb78addf7 is described below
commit 9cb78addf7fcd662de1579db9dff55bd1a420fe4
Author: Alenka Frim <[email protected]>
AuthorDate: Tue Dec 19 09:45:41 2023 +0100
GH-38683: [Python][Docs] Update docstrings for Time32Type and Time64Type
(#39059)
### Rationale for this change
`Time32Type` and `Time64Type` unit docs are not correctly documented.
### What changes are included in this PR?
Update the docstrings for `Time32Type` and `Time64Type` `unit`.
* Closes: #38683
Authored-by: AlenkaF <[email protected]>
Signed-off-by: Joris Van den Bossche <[email protected]>
---
python/pyarrow/types.pxi | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/python/pyarrow/types.pxi b/python/pyarrow/types.pxi
index a0ddf09d69..912ee39f7d 100644
--- a/python/pyarrow/types.pxi
+++ b/python/pyarrow/types.pxi
@@ -1108,6 +1108,9 @@ cdef class Time32Type(DataType):
"""
Concrete class for time32 data types.
+ Supported time unit resolutions are 's' [second]
+ and 'ms' [millisecond].
+
Examples
--------
Create an instance of time32 type:
@@ -1124,7 +1127,7 @@ cdef class Time32Type(DataType):
@property
def unit(self):
"""
- The time unit ('s', 'ms', 'us' or 'ns').
+ The time unit ('s' or 'ms').
Examples
--------
@@ -1140,6 +1143,9 @@ cdef class Time64Type(DataType):
"""
Concrete class for time64 data types.
+ Supported time unit resolutions are 'us' [microsecond]
+ and 'ns' [nanosecond].
+
Examples
--------
Create an instance of time64 type:
@@ -1156,7 +1162,7 @@ cdef class Time64Type(DataType):
@property
def unit(self):
"""
- The time unit ('s', 'ms', 'us' or 'ns').
+ The time unit ('us' or 'ns').
Examples
--------