Commit graph

47 commits

Author SHA1 Message Date
Jennifer Richards fbcfa19add
feat: remove "AD is watching" state (#7960)
* feat: remove "AD is watching" state

* chore: update names.json

* refactor: use idexists state, not dead

* fix: remove guidance to use watching state

* chore: remove references to 'watching' state

* feat: remove create_in_state from edit_info view

* test: update test

* style: Black + move class closer to use

* refactor: remove lint

* fix: restore missing admonition

---------

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
2024-09-24 12:13:12 -05:00
Robert Sparks 5bbea70cb0
fix: repair many revision related issues with the main and htmlized views 2023-09-12 08:55:38 -05:00
Robert Sparks 05b71bb50c
chore: flip sense of all_ids rfc dict 2023-08-18 18:10:10 -05:00
Robert Sparks c0e2bb4521
chore: flip sense of all_ids2 rfc dict 2023-08-18 18:07:29 -05:00
Robert Sparks 3b067a468a
fix: name corrections, flake removal 2023-08-17 16:34:26 -05:00
Robert Sparks 4946430159
chore: checkpoint: halfway through removing docalias 2023-08-15 09:11:53 -05:00
Robert Sparks 769d85a6c4
chore: explore architecture change in RelatedDocument 2023-06-16 14:58:42 -05:00
Lars Eggert f8b48f4c43
fix: use Internet-Draft more consistently across the UI (#5104)
* s/Internet Draft/Internet-Draft/i

* s/draft/Internet-Draft/i or s/draft/I-D/i

* s/ID/I-D/

* Fix tests

* a -> an

* Undo case-change to ASCII

* Address code review comments

* Add migrations

* Add merged migration

* fix: straighten out migrations

* fix: finish straightening out migrations

---------

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
2023-02-11 10:09:28 -06:00
Jennifer Richards 0c458ef048
fix: make a few datetime manipulations timezone-aware (#4755)
* fix: set tz when passing a date to timesince_days filter

* fix: fill in tz for a constructed datetime in idindex/index.py

* test: simplify double-negatives in test assertions

* test: fix I-D expiration test cases to be tz aware

* fix: use tz-aware comparisons for in_draft_expire_freeze method

* test: fix tz used for timesince_days filter test case
2022-11-15 07:55:13 -06:00
Jennifer Richards 56505147e0
fix: handle timezones in a bunch of places 2022-09-23 16:11:49 -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 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 f10ddadc0e Merged in changes from trunk up to r17584.
- Legacy-Id: 17593
2020-04-07 16:02:52 +00:00
Henrik Levkowetz 50bb971fc3 Merged in [17496] from rjsparks@nostrum.com:
Remove the rest of the log.assertions checking that iesg_state existed in places we expected it to.  Removed unnecessary imports.
 - Legacy-Id: 17522
Note: SVN reference [17496] has been migrated to Git commit db5d11ea32
2020-03-23 22:34:03 +00:00
Robert Sparks db5d11ea32 Remove the rest of the log.assertions checking that iesg_state existed in places we expected it to. Commit ready for merge.
- Legacy-Id: 17496
2020-03-21 22:11:33 +00:00
Henrik Levkowetz 726fcbf27d Removed all __future__ imports.
- Legacy-Id: 17391
2020-03-05 23:53:42 +00:00
Henrik Levkowetz e9a37d8ac8 Removed six.text_type(), changed six.moves.urllib to plain urllib, and removed now unused six imports.
- Legacy-Id: 17385
2020-03-05 14:41:41 +00:00
Henrik Levkowetz bdc73e771a Python2/3 compatibility: replaced six.ensure_text() with either six.text_type or django's force_text(), depending on the case, and fixed a variable scope issue.
- Legacy-Id: 16461
2019-07-16 13:20:05 +00:00
Henrik Levkowetz 8c6eb3a30a Python2/3 compatibility: Changed the use of open() and StringIO to io.open() etc.
- Legacy-Id: 16458
2019-07-15 19:14:04 +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 426870b766 Merged in the Document and DocAlias primary key change and m2m work in ^/personal/henrik/6.96.1-docalias.
- Legacy-Id: 16261
2019-06-15 12:00:48 +00:00
Henrik Levkowetz a2cafded25 Changed DocAlias to be many-to-many, in order to be able to handle STD aliases referring to multiple RFCs.
- Legacy-Id: 16249
2019-06-14 20:38:14 +00:00
Henrik Levkowetz 815602351f This is a series of 50 migrations that changes the Document and DocAlias
primary keys from character strings to integers, and makes corresponding code
changes.

This was prompted by database limitations discovered when trying to make
DocAlias use a m2m document field; with 255 long strings as primary keys for
Document and DocAlias this violated the MySQL database limitations.

Changing the primary keys to integers should also improve efficiency.  

Due to the data migrations which create the new integer primary keys and adds
corresponding integer foreign keys matching the previous string foreign keys
in all tables having foreign keys to Document and DocAlias, some of these
migrations take a long time.  The total set of migrations are expected to have
a runtime on the order of 2 hours.
 - Legacy-Id: 16237
2019-06-10 11:32:46 +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 56d622b185 Changed the generation of the 1id-index.txt file to not list individual drafts in states Candidate for WG Adoption and Call for WG Adoption Issued as group drafts.
- Legacy-Id: 15612
2018-10-24 17:40:36 +00:00
Robert Sparks 2159fdd975 Use factories for ietf.idindex.tests. Commit ready for merge.
- Legacy-Id: 15380
2018-07-18 15:35:20 +00:00
Ole Laursen 5b677dc6ba Merge author stats branch into new branch from trunk
- Legacy-Id: 13159
2017-03-28 14:36:40 +00:00
Henrik Levkowetz cf4a4b02a7 Reworked the email address handling in order to be able to support non-ascii names as part of email address fields. Reworked the generation of user names in the test suite to generate names from multiple non-ascii locales. Fixes issue #2080.
- Legacy-Id: 12872
2017-02-18 21:50:18 +00:00
Henrik Levkowetz dca5c9c4d4 Fixed a bug in a queryset argument in all_id_text(); __in was not used, but the value given was a multi-row queryset.
- Legacy-Id: 12780
2017-02-02 12:24:27 +00:00
Ole Laursen 9308948195 Add person, affiliation and country (through django-countries) to
DocumentAuthor, rename author field to email and make it optional (for
modeling old email-less submissions), remove the authors many to many
referencing field from Document as it is not really pointing the right
place.

Update the Secretariat tools to show affiliation and country.

Add migration for getting rid of the fake email addresses that the
migration script created some years ago (just set the author email
field to null).
 - Legacy-Id: 12739
2017-01-26 17:10:08 +00:00
Henrik Levkowetz 173f5419ac Changed the state shown in all_id.txt for drafts which have entered IESG processing, but then been replaced, to show as 'Replaced' instead of 'In IESG Processing'. This is consistent with how they are shown in all_id2.txt.
- Legacy-Id: 12529
2016-12-15 10:44:23 +00:00
Henrik Levkowetz 8e56935cfd Undid commit 12527, which contained much too much.
- Legacy-Id: 12528
2016-12-15 10:38:54 +00:00
Henrik Levkowetz e3c6e0ac6b Changed the state shown in all_id.txt for drafts which have entered IESG processing, but then been replaced, to show as 'Replaced' instead of 'In IESG Processing'. This is consistent with how they are shown in all_id2.txt.
- Legacy-Id: 12527
2016-12-15 10:36:15 +00:00
Henrik Levkowetz 18f65e09a0 Removed bad select_related names.
- Legacy-Id: 12456
2016-12-05 15:23:27 +00:00
Henrik Levkowetz f2c31f242b Changed the 1id_index generation to use a new Person method .plain_ascii(). Added tests for some Person name methods.
- Legacy-Id: 11993
2016-09-15 17:29:08 +00:00
Henrik Levkowetz 807e89cb85 Change 1id_index back to using plain names, undoing an inadvertent change to names with title.
- Legacy-Id: 11986
2016-09-13 18:53:52 +00:00
Henrik Levkowetz 5acff0e95f Added a method Person.ascii_name() for use when generating 1id-*.txt files. Added caching for Person.plain_name(). Fixes a problem with non-ascii names in 1id-*.txt which lead to non-ascii names in xml2rfc reference files.
- Legacy-Id: 11510
2016-07-01 20:08:28 +00:00
Ole Laursen f291a466d7 Change Document.shepherd to point to the email address rather than the
person, add migration to fix the existing shepherds, fix wording and
max entries on change shepherd page to be more self-explanatory
 - Legacy-Id: 8268
2014-08-13 11:40:01 +00:00
Henrik Levkowetz 8c42989d5d Pyflakes cleanup compliant with pyflakes 0.8.1, which seems to find things 0.8.0 didn't fin.
- Legacy-Id: 7558
2014-04-01 16:25:18 +00:00
Henrik Levkowetz ab069c4570 Made ietf/idindex/ pyflakes-clean.
- Legacy-Id: 7466
2014-03-15 17:17:25 +00:00
Ole Laursen be8eb96bec Get rid of a bunch of DB queries in all_id2_txt
- Legacy-Id: 7106
2014-01-12 14:16:37 +00:00
Ole Laursen defb116721 Use prefetch_related to reduce the number of queries on the search page and in idindex generation, adjust a couple of members on Document slightly to not filter on relations (filtering doesn't work with prefetch_related)
- Legacy-Id: 6992
2013-12-18 16:58:34 +00:00
Ole Laursen d2b9adf3cb Move ietf_filters templatetag from idtracker/ to doc/
- Legacy-Id: 6053
2013-08-14 15:11:24 +00:00
Henrik Levkowetz cbfe489ff5 Merged in more shim-layer removals from olau@iola.dk
(-r5465:HEAD from branch/iola/shimfree).  Copying relevant
commit messages here:

 - Deleted dead code in many places.

 - Renamed id-something to draft-something, make the "is
   this eligible for expiration" logic clearer

 - Added a name for IPR search URL

 - Revamped the ballot popup view

 - URL reversed the IPR search link instead of hardcoding it

 - Cleaned up search views and remove dead code, port them to the new DB
   schema, hack related views in iesg/ and wginfo/ to use the new search
   interfaces, avoid camelCase in search GET parameters (with
   backwards-compat fallback), add some simple search unit tests, remove
   caching from views_search.py index pages as they're now pretty fast to
   generate, rewrite ballot popup JS, regularize some CSS classes to use
   hyphen-notation rather than camelCase, move some of the search
   templates to doc/.

   idrfc/ now mostly contains some wrapper code still in use by other
   subdirs, some ported code not yet moved, and dead code.

 - Fixed output bug in test crawler and print referrer upon errors so it's
   easier to figure out where a link came from

 - Added /doc/in-last-call/ to crawler, report original page as referrer in
   a redirect chain rather than intermediate URL

 - Ported idindex to new schema, speed them up, add tests, refactor index
   page in views_search to share code with the text index file, get rid
   of some special-case idindex filters from ietf_filters, move
   "/drafts/" redirects to a file in /doc/

 - Ported /idtracker/status/ and /idtracker/status/last-call/ overview of
   drafts in IESG process to new schema in /doc/iesg/ and
   /doc/iesg/last-call/

 - Added redirects for all of /idtracker/*, removed all view code and other
   dead code from idtracker/

 - Removed the idtracker sitemap indexing drafts - in its current form,
   it adds nothing of value to the HTML-based /doc/all/ view, and it's
   pretty slow

 - Ported idtracker feeds to new schema, move them to doc/, cleaned up
   idtracker/ - only templatetags/ietf_filters and proxy code is left
 - Legacy-Id: 5836
2013-07-17 20:52:39 +00:00
Ole Laursen 851107ce8e Add comment to explain what the idindex module is for
- Legacy-Id: 5637
2013-04-11 10:23:16 +00:00
Ole Laursen 3d1eb07afe Port idindex to new schema, speed them up, add tests, refactor index
page in views_search to share code with the text index file, get rid
of some special-case idindex filters from ietf_filters, move
"/drafts/" redirects to a file in /doc/
 - Legacy-Id: 5634
2013-04-10 11:48:07 +00:00