🐛 datetime.utcnow() Deprecation
name: 🐛 Bug Report
about: Create a report to help us improve FireForm.
title: "[BUG]: datetime.utcnow() deprecated and produces naive datetimes"
labels: bug
assignees: ''
⚡️ Describe the Bug
Template.created_at and FormSubmission.created_at use:
default_factory=datetime.utcnow
Python 3.12 deprecates datetime.utcnow().
It returns naive datetime objects (no tzinfo), causing:
- Potential TypeError when compared to aware datetimes
- Implicit UTC assumptions
- Forward-compatibility risk
📉 Expected Behavior
Use timezone-aware UTC datetimes:
datetime.now(timezone.utc)
🕵️ Possible Fix
Replace utcnow() with a helper returning timezone-aware UTC datetime.
🐛 datetime.utcnow() Deprecation
name: 🐛 Bug Report
about: Create a report to help us improve FireForm.
title: "[BUG]: datetime.utcnow() deprecated and produces naive datetimes"
labels: bug
assignees: ''
⚡️ Describe the Bug
Template.created_atandFormSubmission.created_atuse:Python 3.12 deprecates datetime.utcnow().
It returns naive datetime objects (no tzinfo), causing:
📉 Expected Behavior
Use timezone-aware UTC datetimes:
🕵️ Possible Fix
Replace utcnow() with a helper returning timezone-aware UTC datetime.