convert int to datetime python code example
Example 1: convert integer unix to timestamp python
import datetime
print(
datetime.datetime.fromtimestamp(
int("1284105682")
).strftime('%Y-%m-%d %H:%M:%S')
)
Example 2: convert datetime to date python
datetime.datetime.now().date()