Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d092694

Browse files
committed
Add a deprecation warning to this module.
Importing it typically fails anyway (no TZ variable defined), so this is no great loss.
1 parent 44f5f8f commit d092694

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Lib/tzparse.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@
33
# XXX Unfinished.
44
# XXX Only the typical form "XXXhhYYY;ddd/hh,ddd/hh" is currently supported.
55

6+
import warnings
7+
warnings.warn(
8+
"The tzparse module is obsolete and will disappear in the future",
9+
DeprecationWarning)
10+
611
tzpat = ('^([A-Z][A-Z][A-Z])([-+]?[0-9]+)([A-Z][A-Z][A-Z]);'
712
'([0-9]+)/([0-9]+),([0-9]+)/([0-9]+)$')
813

0 commit comments

Comments
 (0)