openclimatefix / ocf-infrastructure

Infrastructure code for OCF's cloud environments
3 stars 6 forks source link

added timezone aware datetime function #530

Closed aryanbhosale closed 5 months ago

aryanbhosale commented 5 months ago

Pull Request

Description

the datetime.utcnow() method is considered deprecated in modern Python versions, and it's recommended to use the more explicit datetime.now(tz=datetime.timezone.utc) instead. The utcnow() method is still functional, but it's considered less clear and less timezone-aware than the alternative. I have thus replaced the deprecated method with the newer one

Fixes #

528

Checklist: