browsertrix/backend/btrixcloud
Tessa Walsh aaf18e70a0
Add created date to Organization and fix datetimes across backend (#1921)
Fixes #1916

- Add `created` field to Organization and OrgOut, set on org creation
- Add migration to backfill `created` dates from first workflow
`created`
- Replace `datetime.now()` and `datetime.utcnow()` across app with
consistent timezone-aware `utils.dt_now` helper function, which now uses
`datetime.now(timezone.utc)`. This is in part to ensure consistency in
how we handle datetimes, and also to get ahead of timezone naive
datetime creation methods like `datetime.utcnow()` being deprecated in
Python 3.12. For more, see:
https://blog.miguelgrinberg.com/post/it-s-time-for-a-change-datetime-utcnow-is-now-deprecated
2024-07-15 19:46:32 -07:00
..
migrations Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
operator
__init__.py
auth.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
background_jobs.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
basecrawls.py
colls.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
crawlconfigs.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
crawlmanager.py
crawls.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
db.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
emailsender.py
invites.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
k8sapi.py
main_op.py
main.py
models.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
orgs.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
pages.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
pagination.py
profiles.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
storages.py
subs.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
uploads.py
users.py
utils.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00
version.py
webhooks.py Add created date to Organization and fix datetimes across backend (#1921) 2024-07-15 19:46:32 -07:00