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 8af1e2e commit 1b1784fCopy full SHA for 1b1784f
pendulum/parser.py
@@ -5,8 +5,11 @@
5
6
import pendulum
7
8
+from .date import Date
9
from .parsing import _Interval
10
from .parsing import parse as base_parse
11
+from .time import Duration
12
+from .time import Time
13
from .tz import UTC
14
15
@@ -16,7 +19,9 @@
16
19
CDuration = None
17
20
18
21
-def parse(text, **options): # type: (str, **typing.Any) -> str
22
+def parse(
23
+ text, **options
24
+): # type: (str, **typing.Any) -> typing.Union[Date, Time, Duration]
25
# Use the mock now value if it exists
26
options["now"] = options.get("now", pendulum.get_test_now())
27
0 commit comments