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

Skip to content

Commit 4bfe03a

Browse files
committed
correct signature for tzinfo.dst() in examples; thanks to Daniil Shved from docs@
1 parent 316f573 commit 4bfe03a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Doc/library/datetime.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1422,13 +1422,13 @@ methods. Exactly which methods are needed depends on the uses made of aware
14221422

14231423
Most implementations of :meth:`dst` will probably look like one of these two::
14241424

1425-
def dst(self):
1425+
def dst(self, dt):
14261426
# a fixed-offset class: doesn't account for DST
14271427
return timedelta(0)
14281428

14291429
or ::
14301430

1431-
def dst(self):
1431+
def dst(self, dt):
14321432
# Code to set dston and dstoff to the time zone's DST
14331433
# transition times based on the input dt.year, and expressed
14341434
# in standard local time. Then

0 commit comments

Comments
 (0)