Created
November 8, 2020 18:59
-
-
Save AlexLamson/c069ace225837e55662d498744fc8b26 to your computer and use it in GitHub Desktop.
My preferred way of getting a human-readable timestamp in python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from datetime import datetime | |
datetime.now().astimezone().strftime('%Y-%m-%d %H:%M:%S %Z') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment