On Sun, Dec 5, 2021 at 5:41 PM <2qdxy4rzwzuui...@potatochowder.com> wrote: > Also FWIW, I still think that if you're doing (b) or (c), then you're > *not* doing default values anymore, you're moving pieces of the logic or > the design into the wrong place. One example of (b) goes something like > this: > > def write_to_log(event, time=>current_time()): > actually_write_to_log(event, time)
Very very common use-case for that: https://pyauth.github.io/pyotp/#time-based-otps The vast majority of calls are going to leave the time parameter at the default. (The one I linked to has separate "at" and "now" functions, but combining them makes very good sense.) ChrisA _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/5STJ3PC7RIERO75LGRCDDBMX4ZGD7EBU/ Code of Conduct: http://python.org/psf/codeofconduct/