@@ -3,6 +3,7 @@ from datetime import datetime
3
3
import numpy as np
4
4
5
5
from pandas ._libs .tslibs .offsets import BaseOffset
6
+ from pandas ._typing import npt
6
7
7
8
class DateParseError (ValueError ): ...
8
9
@@ -21,32 +22,32 @@ def parse_time_string(
21
22
def _does_string_look_like_datetime (py_string : str ) -> bool : ...
22
23
def quarter_to_myear (year : int , quarter : int , freq : str ) -> tuple [int , int ]: ...
23
24
def try_parse_dates (
24
- values : np .ndarray , # object[:]
25
+ values : npt . NDArray [ np .object_ ] , # object[:]
25
26
parser = ...,
26
27
dayfirst : bool = ...,
27
28
default : datetime | None = ...,
28
- ) -> np .ndarray : ... # np.ndarray[object]
29
+ ) -> npt . NDArray [ np .object_ ] : ...
29
30
def try_parse_date_and_time (
30
- dates : np .ndarray , # object[:]
31
- times : np .ndarray , # object[:]
31
+ dates : npt . NDArray [ np .object_ ] , # object[:]
32
+ times : npt . NDArray [ np .object_ ] , # object[:]
32
33
date_parser = ...,
33
34
time_parser = ...,
34
35
dayfirst : bool = ...,
35
36
default : datetime | None = ...,
36
- ) -> np .ndarray : ... # np.ndarray[object]
37
+ ) -> npt . NDArray [ np .object_ ] : ...
37
38
def try_parse_year_month_day (
38
- years : np .ndarray , # object[:]
39
- months : np .ndarray , # object[:]
40
- days : np .ndarray , # object[:]
41
- ) -> np .ndarray : ... # np.ndarray[object]
39
+ years : npt . NDArray [ np .object_ ] , # object[:]
40
+ months : npt . NDArray [ np .object_ ] , # object[:]
41
+ days : npt . NDArray [ np .object_ ] , # object[:]
42
+ ) -> npt . NDArray [ np .object_ ] : ...
42
43
def try_parse_datetime_components (
43
- years : np .ndarray , # object[:]
44
- months : np .ndarray , # object[:]
45
- days : np .ndarray , # object[:]
46
- hours : np .ndarray , # object[:]
47
- minutes : np .ndarray , # object[:]
48
- seconds : np .ndarray , # object[:]
49
- ) -> np .ndarray : ... # np.ndarray[object]
44
+ years : npt . NDArray [ np .object_ ] , # object[:]
45
+ months : npt . NDArray [ np .object_ ] , # object[:]
46
+ days : npt . NDArray [ np .object_ ] , # object[:]
47
+ hours : npt . NDArray [ np .object_ ] , # object[:]
48
+ minutes : npt . NDArray [ np .object_ ] , # object[:]
49
+ seconds : npt . NDArray [ np .object_ ] , # object[:]
50
+ ) -> npt . NDArray [ np .object_ ] : ...
50
51
def format_is_iso (f : str ) -> bool : ...
51
52
def guess_datetime_format (
52
53
dt_str ,
@@ -57,5 +58,5 @@ def guess_datetime_format(
57
58
def concat_date_cols (
58
59
date_cols : tuple ,
59
60
keep_trivial_numbers : bool = ...,
60
- ) -> np .ndarray : ... # np.ndarray[object]
61
+ ) -> npt . NDArray [ np .object_ ] : ...
61
62
def get_rule_month (source : str ) -> str : ...
0 commit comments