Commit graph

23 commits

Author SHA1 Message Date
Jennifer Richards 7f5c3a3699
refactor: Remove length limit on Message header fields (#5455) 2023-03-31 09:37:46 +09:00
Jennifer Richards ebebdbed3e
refactor: replace datetime.now and datetime.today with timezone.now (#4211)
* 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: renumber migrations
2022-08-25 13:45:16 -03:00
Robert Sparks 3697180cc1 Reverted merge of timezone-aware migration efforts.
- Legacy-Id: 18792
2021-01-12 16:54:20 +00:00
Henrik Levkowetz 774e752a54 Snapshot of timezone-aware datatracker code. Tests pass, and the test-crawler shows only expected differences. Trunk changes merged in up to r18768.
- Legacy-Id: 18770
2020-12-16 23:53:37 +00:00
Henrik Levkowetz 088033d843 Added matching indexes to a number of models with ordering by multiple keys.
- Legacy-Id: 18664
2020-11-09 19:41:12 +00:00
Henrik Levkowetz 9aeda11a29 Removed some Py2 compatibility decorators.
- Legacy-Id: 17673
2020-04-21 13:54:31 +00:00
Henrik Levkowetz 726fcbf27d Removed all __future__ imports.
- Legacy-Id: 17391
2020-03-05 23:53:42 +00:00
Henrik Levkowetz 2b1014d66c Added a 'sent' field to Message, to be able to track sent status for captured outgoing messages (which don't have a SendQueue instance).
- Legacy-Id: 17340
2020-02-26 17:09:06 +00:00
Henrik Levkowetz ea8c84d2f6 Python2/3 compatibility: used @python_2_unicode_compatible to provide __unicode__() versions of __str__() methods.
- Legacy-Id: 16455
2019-07-15 18:01:26 +00:00
Henrik Levkowetz 484dcece5f Changed all model __unicode__() methods to __str__()
- Legacy-Id: 16330
2019-06-28 21:07:08 +00:00
Henrik Levkowetz d7f5c84182 Initial 2to3 patch with added copyright statement updates.
- Legacy-Id: 16309
2019-06-27 14:40:54 +00:00
Henrik Levkowetz 682ddee8e4 Reverted earlier application of on_behalf_of() at mail sending call points, and instead did all on_behalf_of processing in condition_message(). Added insertion of Reply-To header fields in this case. Changed all use of the mail-sending 'extra' parameters to use value lists. Updated a bunch of tests accordingly.
- Legacy-Id: 16020
2019-03-11 17:01:33 +00:00
Henrik Levkowetz a4768bb514 Removed unused imports. Added some explicit orderings to avoid pagination issues.
- Legacy-Id: 14664
2018-02-21 23:54:31 +00:00
Henrik Levkowetz 5638cf3da3 Changed all usage of ForeignKey and OneToOneFiled in model.py files to the compatibility versions from ietf.utils.models.
- Legacy-Id: 14661
2018-02-20 15:36:05 +00:00
Ryan Cross 6772afdd24 Update secretariat admin permissions. Change AnnouncementFrom.address to CharField because full emails, with real name, fail EmailField validation. Includes migration. Commit ready for merge.
- Legacy-Id: 14104
2017-09-06 22:42:15 +00:00
Henrik Levkowetz 868427a645 Merged in [13996] from rcross@amsl.com:
Move Announcement app From addresses out of code and into database table.  Fixes #1681.
 - Legacy-Id: 14006
Note: SVN reference [13996] has been migrated to Git commit d49787a0f6060e7db64f5a0e684bf1d980f85290
2017-07-29 18:12:45 +00:00
Henrik Levkowetz 60ddd61727 Tweaked Message.msgid and added needed migrations for the field. The first migration creates the new column with NULL values for existing rows, the second adds creation of msgid values by default for new rows.
- Legacy-Id: 12961
2017-03-03 21:17:12 +00:00
Henrik Levkowetz 4159586994 Added a msgid field to the Message model.
- Legacy-Id: 12953
2017-03-03 15:41:19 +00:00
Mike Douglass fa3a34389e Merge forward to 6.31.1.dev0
- Legacy-Id: 11899
2016-08-31 03:00:10 +00:00
Henrik Levkowetz 8f224af90c Made ietf/message pyflakes-clean.
- Legacy-Id: 7474
2014-03-15 19:02:23 +00:00
Ole Laursen 6d94351553 Add __unicode__ to SendQueue
- Legacy-Id: 6772
2013-11-28 18:12:45 +00:00
Ole Laursen 480cb04cd6 Save announcements generated by the system as Messages, adding an
extra relation to be able to associate a draft with the message
 - Legacy-Id: 3917
2012-02-08 21:05:28 +00:00
Ole Laursen 2df0811f3b Actually add the message app
- Legacy-Id: 3857
2012-01-24 17:42:19 +00:00