datatracker/ietf/secr
Jennifer Richards 8b52d27b02
refactor: refactor timestamp handling so tests in meeting app pass (#4371)
* refactor: replace datetime.now with timezone.now

* refactor: migrate model fields to use timezone.now as default

* refactor: replace datetime.today with timezone.now

datetime.datetime.today() is equivalent to datetime.datetime.now(); both
return a naive datetime with the current local time.

* refactor: rephrase datetime.now(tz) as timezone.now().astimezone(tz)

This is effectively the same, but is less likely to encourage accidental
use of naive datetimes.

* refactor: revert datetime.today() change to old migrations

* refactor: change a missed datetime.now to timezone.now

* chore: renumber timezone_now migration

* chore: add migration to change timestamps to UTC

* refactor: move tz instantiation/caching from TimeSlot to Meeting

* fix: assume utc if meeting.time_zone is blank

* chore: make datetime.combine() calls tz aware in the meeting app

* ci: correctly use meeting.tz in TimeSlotFactory

* chore: compute TimeSlot utc / local times assuming tz-aware times

* chore: use tzaware math for agenda editor timeslot layout

* chore: fill in Meeting.time_zone where it is blank

Nearly all interim meetings on or before 2016-07-01 have blank
time_zone values. This migration fills these in with PST8PDT.

* chore: disallow blank Meeting.time_zone value

* refactor: no need to handle blank time_zone case in TZ migration

* refactor: remove now-unnecessary checks that meeting has time_zone

* chore: fix timezone handling in agenda.ics and Meeting.updated()

* chore: fix tz handling in interim_request_details, exercise in tests

* chore: fix timezone handling for test_interim_send_announcement

* chore: fix timezone handling in agenda_json()

* chore: fix timezone handling in old agenda

* chore: fix timezone handling for EditTimeslotsTests

* refactor: refactor a few fixes for more consistent timezone handling

* chore: add timezone info to timestamps in fixtures

* chore: remove naive datetime warnings found in meetings.tests_views

* chore: fix a few more test failures in meetings.tests_views

All tests in meetings.tests_views now passing

* chore: remove unused import

* chore: fix timezone handling in test_schedule_generator.py

* chore: fix timezone handling affecting meeting.tests_js

* chore: fix timeslot test bug when local date != UTC date

* test: fix a few failing tests, all meetings tests now pass

(for me, anyway)

* chore: renumber migrations

* chore: update timestamp conversion migration

The django-celery-beat package introduces tables with timestamp
columns. These columns are stored in CELERY_TIMEZONE. Because we run with
this set to UTC, the migration ignores these columns.

* chore: fix pytz-related change in migration

* chore: remove duplicate migrations

* chore: remove CELERY_BEAT_TZ_AWARE setting now that USE_TZ is True

* test: avoid failure in test with bogus timezone
2022-08-26 16:53:19 -03:00
..
announcement Many more HTML fixes. 2022-02-03 07:49:34 +00:00
areas preparing to merge forward 2020-07-09 20:29:45 +00:00
console Removed all __future__ imports. 2020-03-05 23:53:42 +00:00
groups Use Roles instead of dedicated model for liaison statement group contacts. Fixes #3100. Commit ready for merge. 2021-02-12 16:39:20 +00:00
lib The context_instance parameter to render_to_response() and render_to_string() is now deprecated. Fixed this, and generally changed the idiom render_to_response('template.html', {}, RequestContext(request)) to the newer and simpler render(request, 'template.html', {}). About 200 instances. 2017-01-09 21:26:30 +00:00
meetings refactor: replace datetime.now and datetime.today with timezone.now (#4211) 2022-08-25 13:45:16 -03:00
middleware Changed some # type: ignore statements to work with the latest mypy 2019-11-05 22:41:18 +00:00
proceedings refactor: refactor timestamp handling so tests in meeting app pass (#4371) 2022-08-26 16:53:19 -03:00
roles Use temporary directories instead of "real" filesystem for tests. Fixes #3414. Commit ready for merge. 2021-11-05 19:45:57 +00:00
rolodex Fixed a place where data provider for a POST in contained None, which cannot be serialized into POST data. Found by Django 2.2 checks. 2020-06-27 17:23:47 +00:00
sreq fix: allow 90m session requests. Prompt for cannot meet at time reasoning. (#4345) 2022-08-19 09:11:44 -05:00
static fix: add more HTML validation & fixes (#3891) 2022-05-03 13:55:48 -05:00
telechat refactor: replace datetime.now and datetime.today with timezone.now (#4211) 2022-08-25 13:45:16 -03:00
templates fix: allow 90m session requests. Prompt for cannot meet at time reasoning. (#4345) 2022-08-19 09:11:44 -05:00
utils Allow program leads to request meetings. Fixes #3141. Commit ready for merge. 2020-11-23 20:36:47 +00:00
__init__.py Merged in branch/amsl/1.50@6388 from rcross@amsl.com, with secretariat tool 2013-10-21 20:29:15 +00:00
context_processors.py Removed dead code. 2015-08-01 14:58:08 +00:00
urls.py Remove drafts secretariat tool because this functionality is now provided by the core Datatracker. Moved ID reports to proceedings tool. Fixes #1655. Commit ready for merge. 2020-03-21 19:52:12 +00:00