Commit graph

160 commits

Author SHA1 Message Date
Jennifer Richards 32054111df
fix: fix failing tests and eliminate naive datetime warnings (#4402)
* test: fix timestamp construction in several doc tests

* refactor: rename date2datetime to datetime_from_date and clarify code

* chore: helper to get tzinfo for PRODUCTION_TIMEZONE

* fix: fix timezone handling in make_last_call()

* test: fix datetime generation in doc.tests_charter

* refactor: remove PRODUCTION_TIMEZONE setting

Replaces the PRODUCTION_TIMEZONE setting with a constant,
DEADLINE_TZINFO, in ietf.utils.timezone.

* test: be more careful about timezone in tests_charter.py

* test: be more careful about timezone in doc/tests.py

* fix: fix timezone handling affecting doc.tests_draft

* fix: fix timezone handling affecting tests_irsg_ballot.py

* fix: fix timezone handling affecting tests_review.py

* fix: fix timezone handling affecting last ietf.doc tests

* fix: fix timezone handling affecting last ietf.group tests

* fix: fix timezone handling affecting ietf.iesg tests

* fix: handle timezones in get_8989_eligibility_querysets

* fix: handle timezones affecting ietfauth tests

* fix: return tz-aware datetime from utc_from_string

* fix: specify timezone for constants in ipr_rfc_number()

* fix: specify tz for ipr deadlines

* fix: handle timezones affecting liaisons tests

* fix: treat leap day in get_8989_eligibility_querysets()

Manual cherry-pick of 248d6474

* test: treat leap day properly in nomcom tests

* fix: fix timezone handling affecting nomcom tests

* test: fix timezone handling in review tests

* fix: fix timezone handling affecting secr.meetings tests

* fix: handle both pytz and zoneinfo timezones in ietf.utils.timezone

* fix: fix timezone handling affecting secr.proceedings tests

* refactor: use make_aware() helper in secr.meetings tests

* test: fix timezone handling in secr.telechat tests

* fix: fix timezone handling affecting stats tests

* fix: eliminate tz-naive helpers affecting sync email parsing

* fix: include timezone data when serializing DeletedEvent data

* fix: fix timezone handling affecting sync tests

* style: remove unused import
2022-09-01 13:07:28 -03: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 0f703a695e
fix: correctly render wg shepherd writeups and test it. (#4316) 2022-08-11 16:21:52 -05:00
Lars Eggert 3d49384213
fix: Make the "submit to IESG" workflow less surprising to @LPardue :-) (#4254)
* fix: Make the "submit to IESG" workflow less surprising to @LPardue :-)

Fixes #4209

* Merge part of #4256
2022-07-24 11:28:27 -05:00
Lars Eggert 1ba87890ba
feat: Render the document shepherd writeup templates at two new URLs (#4225)
* feat: Render the document shepherd writeup templates at two new URL.

Those being `/doc/shepherdwriteuptemplate/group` and
`/doc/shepherdwriteuptemplate/individual`.

* Address review comments from @jennifer-richards

* Fixes

* Remove debug statement

* Make bleach sanitizer not strip the `start` attribute of `ol` tags

Also rearrange the code a bit

* Don't sanitize the `python_markdown` output, it destroys wanted formatting

* Restore bleach

* Don't bleach tag `id`s.
2022-07-22 13:43:02 -05:00
Jennifer Richards fc9864114b Allow pre-ADs to be assigned as responsible for document. Fixes #3229. Commit ready for merge.
- Legacy-Id: 19383
2021-09-22 18:42:00 +00:00
Jennifer Richards b08110b838 Allow external resources to be set/suggested during submission process. Fixes #3068. Commit ready for merge.
- Legacy-Id: 18960
2021-04-19 20:21:19 +00:00
Jennifer Richards e11583a87f Allow assignment of Person as "action holder" for a Doc, plus rudimentary automation of assignment. Fixes #3146. Commit ready for merge.
- Legacy-Id: 18829
2021-02-12 20:31:00 +00: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
Robert Sparks 7e384a8aea Send email to new mailtrigger controlled destinations when iana expert review state changes. Fixes #3121. Commit ready for merge.
- Legacy-Id: 18714
2020-11-18 21:32:48 +00:00
Henrik Levkowetz 0fa1500f52 Changed the format of email addresses added to the document notifications filed when the document shepherd is set. Fixes issue #3079.
- Legacy-Id: 18494
2020-09-14 13:31:39 +00:00
Henrik Levkowetz 57938b039d Converted many cases of plain-text 403 messages to use a properly styled page instead, with a login link when appropriate. Also changed some API endpoint 400 responses to a more correct 403.
- Legacy-Id: 18339
2020-08-06 10:59:52 +00:00
Robert Sparks 066ee27505 preparing to merge forward
- Legacy-Id: 18143
2020-07-09 20:29:45 +00:00
Robert Sparks 7e57be2bd3 merged forward ^/personal/rjs/explore-extref
- Legacy-Id: 17840
2020-05-19 18:47:47 +00:00
Robert Sparks 7587d564d4 Added GroupExtResources to the group about page, and added the ability to edit them.
- Legacy-Id: 17685
2020-04-24 21:47:24 +00:00
Robert Sparks 2de9eb93b5 Added validation to the migrations. Added external resources to the draft display page. Built an editor for DocExternalResources.
- Legacy-Id: 17683
2020-04-24 16:14:43 +00:00
Henrik Levkowetz 726fcbf27d Removed all __future__ imports.
- Legacy-Id: 17391
2020-03-05 23:53:42 +00:00
Henrik Levkowetz a7baacf519 Added missing .as_strings() to some gather_address_lists() calls, in order to assign strings rather than lists to Message CharField instances. Fixed a Message content_type setting.
- Legacy-Id: 17337
2020-02-26 16:59:18 +00:00
Henrik Levkowetz 32e9692f54 Fixed a py2/py3 issue in sync.rfceditor.post_approved_draft(), and enhanced tests to execute the failing code (with Mock functions) instead of skipping the code.
- Legacy-Id: 17265
2020-01-28 22:37:50 +00:00
Robert Sparks 0c0cc5dcf5 Allow document Additional URLs to become empty. Fixes #2864. Commit ready for merge.
- Legacy-Id: 17227
2020-01-13 19:03:58 +00:00
Ryan Cross 9882d7fda8 Fix issue where draft resurrect feature does not move most recent draft file from the archive directory back to the current draft directory. Fixes #2646. Commit ready for merge
- Legacy-Id: 17027
2019-11-16 05:15:03 +00:00
Henrik Levkowetz 1edc863969 Merged in [16763] from rjsparks@nostrum.com:
Allow responsible AD to be None for documents in iesg states idexists and dead. Fixes #2803 and #993.
 - Legacy-Id: 16838
Note: SVN reference [16763] has been migrated to Git commit 9f54af355d4e2b17404caa1755be74d22b5edad1
2019-10-07 19:54:56 +00:00
Robert Sparks e45a32e49f Add IANA expert review tracking. Commit ready for merge.
- Legacy-Id: 16656
2019-08-15 20:36:07 +00:00
Henrik Levkowetz a5e31c3f40 Py2/3 compatibility: Added __future__ import.
- Legacy-Id: 16452
2019-07-15 15:52:18 +00:00
Henrik Levkowetz ff6997df2b Fixed a case of indeterminate ordering.
- Legacy-Id: 16343
2019-06-30 20:58:26 +00:00
Henrik Levkowetz 3ec7e864be Converted leading tabs to spaces in ietf/**/*.py
- Legacy-Id: 16310
2019-06-27 14:51:02 +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 56543d565c Changed sending of PubReq messages to explicitly use on-behalf-of, without Reply-To. Reply-To is picked up as requestor by RT. Fixes issue #2691 anew.
- Legacy-Id: 16034
2019-03-14 21:31:40 +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 435a0da12d Added on_behalf_of() calls for from addresses needing it throughout the code.
- Legacy-Id: 15992
2019-03-04 20:14:19 +00:00
Henrik Levkowetz b57ad67041 Updated code and templates to use the new docman and groupman group features.
- Legacy-Id: 15922
2019-01-30 15:59:00 +00:00
Henrik Levkowetz 57a4c9f41f Added 9 new group features, and changed list-like char fields to json fields, to get better support for using the values as lists. Modified code to use the group features instead of explicit lists of group types in many places in the code.
- Legacy-Id: 15908
2019-01-22 18:11:46 +00:00
Robert Sparks f6886f6105 Corrected a conditional expression and improved the test that exercised it. Commit ready for merge.
- Legacy-Id: 15822
2018-12-14 21:50:21 +00:00
Robert Sparks 6118975620 Added an explicit ID-Exists state for the IESG state machine. Reworked code so that the IESG state machine always has a state. Added the ability to release a document from a working group, research group, or the independent stream. Releasing a document removes all stream state, and sets the document to have no stream.
- Legacy-Id: 15809
2018-12-11 22:38:05 +00:00
Henrik Levkowetz 81e78c70a0 Added guards against asking for properties on None in a couple of places.
- Legacy-Id: 15173
2018-05-26 08:34:27 +00:00
Henrik Levkowetz 6c3ec5b18e Added Email origin to Email record creation throughout the codebase.
- Legacy-Id: 15149
2018-05-17 16:56:26 +00:00
Henrik Levkowetz 26bf387356 Replaced direct assignment to m2m fields with .clear() and .set()
- Legacy-Id: 14666
2018-02-21 23:58:25 +00:00
Henrik Levkowetz 53eb7c8ae8 Added migrations for document url model changes. Updated the name fixtures. Added ability for individual draft authors to edit document urls.
- Legacy-Id: 14172
2017-09-27 16:37:13 +00:00
Henrik Levkowetz 92d425fd9b Added 'Additional URLs' for documents, the same way we have them for groups.
This could be used to point to a document source repository, to extracted
  yang module files, document wikis, and other relevant resources.
 - Legacy-Id: 14166
2017-09-27 10:52:32 +00:00
Robert Sparks 09a7d720a1 Improved what initial states are offered when the IRTF chair or RG personnel manage adoption of a document. Fixes #2319. Commit ready for merge.
- Legacy-Id: 14055
2017-08-14 19:35:48 +00:00
Robert Sparks 7a11217f6f Refined the state changed email message per discussion on tools-development. Fixes #2116. Commit ready for merge.
- Legacy-Id: 13888
2017-07-15 09:36:29 +00:00
Henrik Levkowetz a18cf20868 Removed code which has been marked as unreachable since February/March 2017 without triggering any usage indications.
- Legacy-Id: 13667
2017-06-17 17:54:40 +00:00
Henrik Levkowetz fb93a8c293 Added dates to unreachable() calls, to make it easier to decide when to remove marked code.
- Legacy-Id: 13538
2017-06-06 07:27:07 +00:00
Lars Eggert 8a70e9773d Fix various "RemovedInDjango20Warning" warnings. Commit ready for merge.
- Legacy-Id: 13112
2017-03-25 19:16:45 +00:00
Henrik Levkowetz 4daf66d11c Added DocEvent rev= parameter througout the code.
- Legacy-Id: 12978
2017-03-06 15:08:21 +00:00
Henrik Levkowetz 387068f67d Updated unreachable markings.
- Legacy-Id: 12967
2017-03-04 05:38:23 +00:00
Henrik Levkowetz 225c1d9afe Changed the state choices in the document adoption form to exclude the few that should not be available, rather than explicitly list all others. Makes adding WG/RG states simpler.
- Legacy-Id: 12949
2017-03-02 20:07:50 +00:00
Henrik Levkowetz 27351c4349 Fixed url lookups for doc.views_doc.document_main() to only use dotted-path, and removed the doc_view explicit url name. Fixes a 500 error in /submit/status/NNNN/.
- Legacy-Id: 12897
2017-02-22 11:40:55 +00:00
Henrik Levkowetz 613f0c8233 Pyflakes fixes.
- Legacy-Id: 12714
2017-01-23 18:35:58 +00:00