Commit graph

210 commits

Author SHA1 Message Date
Robert Sparks 4b4e876305
Merge branch 'main' into feat/postgres 2023-03-09 11:43:38 -06:00
Lars Eggert 98c24d1bb0
fix: Use correct group type in session request email response (#5275)
* fix: Use correct group type in session request email response

Fixes #2120

* Address review comments

* Address review comments
2023-03-07 10:15:47 -06:00
Robert Sparks c04feb5765
Merge remote-tracking branch 'origin/main' into feat/postgres 2023-01-26 10:37:50 -06:00
Jennifer Richards ec7c7b3701
chore: Upgrade to bleach v6 (#5021)
* build: Bump bleach requirement to 6.0.0

* fix: Update bleach configuration for compatibility with v6 changes
2023-01-23 13:29:45 -06:00
Robert Sparks 15569771ff
Merge remote-tracking branch 'upstream/main' into feat/postgres 2022-12-12 09:54:49 -06:00
Robert Sparks 9457e2b1e1
feat: better htmlization views (#4825)
* feat: Use bs5 for htmlized doc (#4082)

Co-authored-by: Martin Thomson <mt@lowentropy.net>

* fix: Various fixes to HTMLized document view (#4501)

* fix: Pref labels were switched

* fix: Fix ToC for htmlized docs

* Replace datatracker button with document name link to datatracker

* ui: Make fonts even larger on larger window widths

* fix: Document format buttons open new tabs

* fix: Various suggestions from Jay

* fix: Don't show "htmlized" self-link under formats

* ui: Font size fix for iOS

* ui: More little tweaks

* feat/htmlize fixes and improvements (#4506)

* fix: Don't open htmlized view in new tab

* fix: Tests were failing

* feat: Add pref settings to cap max font size

* feat: Add ability to hide side panel

* fix: And more `feat/htmlize` fixes (#4511)

* fix: Remove superfluous scrollbars

* fix: Show email links for authors

* fix: Only show "email authors" button for latest reversion

* fix: Remove duplicate code, fix nav scrolling

* feat: Add RFCs to revision lists

* feat: Add pref option to control dependency inlining

* fix: Add analytical tags

* feat: Notify user of rendering inconsistencies

* feat: Split out bootstrap-icons when not inlining dependencies

* fix: Revision list and minor other fixes

* feat: Show stream logo when possible (#4516)

* fix: Remove superfluous scrollbars

* fix: Show email links for authors

* fix: Only show "email authors" button for latest reversion

* fix: Remove duplicate code, fix nav scrolling

* feat: Add RFCs to revision lists

* feat: Add pref option to control dependency inlining

* fix: Add analytical tags

* feat: Notify user of rendering inconsistencies

* feat: Split out bootstrap-icons when not inlining dependencies

* fix: Revision list and minor other fixes

* feat: Show stream logos when possible

* fix: Pick up CSS changes from https://github.com/martinthomson/rfc-txt-html (#4520)

* fix: Remove superfluous scrollbars

* fix: Show email links for authors

* fix: Only show "email authors" button for latest reversion

* fix: Remove duplicate code, fix nav scrolling

* feat: Add RFCs to revision lists

* feat: Add pref option to control dependency inlining

* fix: Add analytical tags

* feat: Notify user of rendering inconsistencies

* feat: Split out bootstrap-icons when not inlining dependencies

* fix: Revision list and minor other fixes

* feat: Show stream logos when possible

* fix: Pick up CSS changes from https://github.com/martinthomson/rfc-txt-html

* chore: add debug script to replicate GitHub Actions test environment

* chore: cleanup from merge of main

* fix: Fix PDFixation crash due to referencing renamed CSS asset (#4665)

* fix: Rename some CSS classes to handle recent xml2rfc changes (#4791)

* Merge main

* fix: Rename some CSS classes to handle recent xml2rfc changes

Fixes #4784.

* chore: repair merge damage

* chore: more merge corrections

* chore: one more merge correction

* fix: npm dependencies

* fix: Change default font size (#4817)

* Fix dependency issues

* Cap fontsize at 12pt by default

Co-authored-by: Nicolas Giard <github@ngpixel.com>

Co-authored-by: Lars Eggert <lars@eggert.org>
Co-authored-by: Martin Thomson <mt@lowentropy.net>
Co-authored-by: Nicolas Giard <github@ngpixel.com>
2022-12-02 15:17:14 -06:00
Robert Sparks 27fccc6ba0
feat: move to postgresql (#4744)
* feat: move to postgresql

* fix: repair fractional replace statement

* fix: use pathlib to manipulate settings_local

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>

* fix: do two string replacements, not one followed by another that throws away the first.

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>

* fix: use pathlib again to manipulate settings_local

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>

* fix: properly use assert (1/2)

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>

* fix: properly use assert (2/2)

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>

Co-authored-by: Jennifer Richards <jennifer@painless-security.com>
2022-11-11 11:01:01 +00:00
Jennifer Richards 6cc2fb94a3
fix: update DraftYangChecker for xym 0.6 changes (#4546)
* fix: update DraftYangChecker for xym 0.6 changes

* chore: update xym requirements to >=0.6
2022-10-06 18:03:18 -05:00
Jennifer Richards 3705bedfcd
feat: Celery support and asynchronous draft submission API (#4037)
* ci: add Dockerfile and action to build celery worker image

* ci: build celery worker on push to jennifer/celery branch

* ci: also build celery worker for main branch

* ci: Add comment to celery Dockerfile

* chore: first stab at a celery/rabbitmq docker-compose

* feat: add celery configuration and test task / endpoint

* chore: run mq/celery containers for dev work

* chore: point to ghcr.io image for celery worker

* refactor: move XML parsing duties into XMLDraft

Move some PlaintextDraft methods into the Draft base class and
implement for the XMLDraft class. Use xml2rfc code from ietf.submit
as a model for the parsing.

This leaves some mismatch between the PlaintextDraft and the Draft
class spec for the get_author_list() method to be resolved.

* feat: add api_upload endpoint and beginnings of async processing

This adds an api_upload() that behaves analogously to the api_submit()
endpoint. Celery tasks to handle asynchronous processing are added but
are not yet functional enough to be useful.

* perf: index Submission table on submission_date

This substantially speeds up submission rate threshold checks.

* feat: remove existing files when accepting a new submission

After checking that a submission is not in progress, remove any files
in staging that have the same name/rev with any extension. This should
guard against stale files confusing the submission process if the
usual cleanup fails or is skipped for some reason.

* refactor: make clear that deduce_group() uses only the draft name

* refactor: extract only draft name/revision in clean() method

Minimizing the amount of validation done when accepting a file. The
data extraction will be moved to asynchronous processing.

* refactor: minimize checks and data extraction in api_upload() view

* ci: fix dockerfiles to match sandbox testing

* ci: tweak celery container docker-compose settings

* refactor: clean up Draft parsing API and usage

  * remove get_draftname() from Draft api; set filename during init
  * further XMLDraft work
    - remember xml_version after parsing
    - extract filename/revision during init
    - comment out long broken get_abstract() method
  * adjust form clean() method to use changed API

* feat: flesh out async submission processing

First basically working pass!

* feat: add state name for submission being validated asynchronously

* feat: cancel submissions that async processing can't handle

* refactor: simplify/consolidate async tasks and improve error handling

* feat: add api_submission_status endpoint

* refactor: return JSON from submission api endpoints

* refactor: reuse cancel_submission method

* refactor: clean up error reporting a bit

* feat: guard against cancellation of a submission while validating

Not bulletproof but should prevent

* feat: indicate that a submission is still being validated

* fix: do not delete submission files after creating them

* chore: remove debug statement

* test: add tests of the api_upload and api_submission_status endpoints

* test: add tests and stubs for async side of submission handling

* fix: gracefully handle (ignore) invalid IDs in async submit task

* test: test process_uploaded_submission method

* fix: fix failures of new tests

* refactor: fix type checker complaints

* test: test submission_status view of submission in "validating" state

* fix: fix up migrations

* fix: use the streamlined SubmissionBaseUploadForm for api_upload

* feat: show submission history event timestamp as mouse-over text

* fix: remove 'manual' as next state for 'validating' submission state

* refactor: share SubmissionBaseUploadForm code with Deprecated version

* fix: validate text submission title, update a couple comments

* chore: disable requirements updating when celery dev container starts

* feat: log traceback on unexpected error during submission processing

* feat: allow secretariat to cancel "validating" submission

* feat: indicate time since submission on the status page

* perf: check submission rate thresholds earlier when possible

No sense parsing details of a draft that is going to be dropped regardless
of those details!

* fix: create Submission before saving to reduce race condition window

* fix: call deduce_group() with filename

* refactor: remove code lint

* refactor: change the api_upload URL to api/submission

* docs: update submission API documentation

* test: add tests of api_submission's text draft consistency checks

* refactor: rename api_upload to api_submission to agree with new URL

* test: test API documentation and submission thresholds

* fix: fix a couple api_submission view renames missed in templates

* chore: use base image + add arm64 support

* ci: try to fix workflow_dispatch for celery worker

* ci: another attempt to fix workflow_dispatch

* ci: build celery image for submit-async branch

* ci: fix typo

* ci: publish celery worker to ghcr.io/painless-security

* ci: install python requirements in celery image

* ci: fix up requirements install on celery image

* chore: remove XML_LIBRARY references that crept back in

* feat: accept 'replaces' field in api_submission

* docs: update api_submission documentation

* fix: remove unused import

* test: test "replaces" validation for submission API

* test: test that "replaces" is set by api_submission

* feat: trap TERM to gracefully stop celery container

* chore: tweak celery/mq settings

* docs: update installation instructions

* ci: adjust paths that trigger celery worker image  build

* ci: fix branches/repo names left over from dev

* ci: run manage.py check when initializing celery container

Driver here is applying the patches. Starting the celery workers
also invokes the check task, but this should cause a clearer failure
if something fails.

* docs: revise INSTALL instructions

* ci: pass filename to pip update in celery container

* docs: update INSTALL to include freezing pip versions

Will be used to coordinate package versions with the celery
container in production.

* docs: add explanation of frozen-requirements.txt

* ci: build image for sandbox deployment

* ci: add additional build trigger path

* docs: tweak INSTALL

* fix: change INSTALL process to stop datatracker before running migrations

* chore: use ietf.settings for manage.py check in celery container

* chore: set uid/gid for celery worker

* chore: create user/group in celery container if needed

* chore: tweak docker compose/init so celery container works in dev

* ci: build mq docker image

* fix: move rabbitmq.pid to writeable location

* fix: clear password when CELERY_PASSWORD is empty

Setting to an empty password is really not a good plan!

* chore: add shutdown debugging option to celery image

* chore: add django-celery-beat package

* chore: run "celery beat" in datatracker-celery image

* chore: fix docker image name

* feat: add task to cancel stale submissions

* test: test the cancel_stale_submissions task

* chore: make f-string with no interpolation a plain string

Co-authored-by: Nicolas Giard <github@ngpixel.com>
Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
2022-08-22 13:29:31 -05:00
Robert Sparks c0f1fd2395
chore: update to pytz 2022.2.1 (#4342) 2022-08-18 11:40:51 -05:00
Robert Sparks aa2f843725
chore: track updates to pytz (#4319) 2022-08-12 15:14:46 -05:00
Nicolas Giard aa9490faf6
feat(ui): new dynamic agenda view (#4086)
* feat: agenda page in vue (wip)

* feat: scroll to agenda day

* fix: vue 3 composition api + eslint settings

* fix: agenda day scroll match indicator

* fix: convert vite deps to yarn

* fix: missing lodash + legacy build step

* fix: agenda - move calendar into drawer

* fix: improve agenda filter UI

* fix: download ics + move agenda into own component

* feat: use fullcalendar for agenda calendar view (wip)

* feat: add events to agenda calendar

* feat: agenda filter UI improvements

* feat: agenda add to calendar dropdown

* feat: agenda calendar filter + timezone + event coloring

* feat: agenda calendar color improvements

* chore: exclude dist-neue from git

* feat: agenda calendar event modal

* fix: rebuild yarn deps

* chore: add run migration task to vscode

* fix: agenda buttons display flag

* feat: agenda event modal component

* feat: show calendar event quick info on hover

* fix: clear calendar quick info on timezone change

* feat: agenda list view improvements

* feat: agenda list row coloring

* feat: agenda list note

* feat: agenda list icons for office hours + hackathon

* fix: agenda top links

* refactor: use pinia as store for agenda components

* feat: agenda jump to now

* fix: agenda mobile improvements

* feat: agenda search

* feat: agenda search improvements

* feat: agenda event recordings buttons for post-meeting

* fix: agenda switch to meeting timezone on load

* feat: agenda pre & live session buttons

* fix: remove agenda utc + personalize links in top menu

* feat: add pre-vue loading state on page load

* feat: filter from agenda picker mode

* fix: agenda UI improvements

* fix: django-vite non-dev mode

* chore: update yarn dependencies for vue + vite

* feat: agenda settings panel + UI improvements

* feat: agenda settings colors + import/export feature

* feat: agenda color assignments + responsive UI improvements

* feat: agenda realtime red line + debug datetime offset

* feat: agenda add aria labels for settings

* feat: add new agenda path + pages/menu

* fix: bring base/menu.html up to main

* fix: agenda various fixes

* test: add new agenda item to meetings menu for item count

* chore: restore devcontainer extensions list

* fix: agenda UI improvements + montserrat default font

* feat: agenda bolder text + hide event icons options

* feat: agenda warning badge

* fix: agenda various UI improvements + intersectionObserver fix

* feat: agenda floorplan page + various UI improvements

* feat: agenda floor plan pin

* feat: view floor plan room from agenda

* feat: agenda floor plan mobile optimization

* feat: adjust calendar options + default calendar view in settings

* feat: agenda persist picked events + change base font only on new agenda page

* feat: agenda mobile view optimizations

* fix: add .vite to cached volumes

* fix: mobile view for filters, calendar, settings panels

* test: upgrade cypress existing tests to work on bs5 + update dependencies

* fix: use named url patterns to avoid hardcoded URLs. Add rudimentary test coverage for the neue views.

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
2022-07-13 16:20:23 -05:00
Lars Eggert 495df36a77
chore: Make newer bibtexparser versions work with the tests (#4205)
* chore: Make newer bibtexparser versions work with the tests

* Fix test
2022-07-12 11:18:52 -05:00
Lars Eggert 159f89ebf3
chore: Remove six and pathlib2 from deps (#4031)
Fixes: #3895 and #3892
2022-05-31 09:12:45 -05:00
Robert Sparks 55d7629e4d
chore: use and expect python39 (#3908) 2022-04-29 09:45:41 -05:00
Robert Sparks 86923dfe96
chore: update dependency requirements (#3904)
* chore: cleanup requirements.txt. Unpin factory-boy, ignoring resulting mypy complaints.

* chore: remove the upper limit as many dependencies as possible

* chore: remove unintended bookmark

* chore: normalize spaces before comments

* chore: improve comment explaining pinned Tastypie

* chore: shift dependencies minimum version requirements forward
2022-04-28 11:06:17 -05:00
Lars Eggert 9db1d48258
fix: Correctly linkify all current TLDs (#3868)
* fix: Correctly linkify all current TLDs

* Pass a list to the build_*_re functions, not a string

* Need to sort TLDs by length to force longer ones to match first

* chore: silence incorrect mypy complaint.

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
Co-authored-by: Nicolas Giard <github@ngpixel.com>
2022-04-26 12:25:18 -05:00
Robert Sparks f4b0b459cb
feat: add analytics infrastructure (#3862) 2022-04-21 18:06:14 -05:00
Lars Eggert 3234f1a121
test: Validate HTML rendered during tests (#3782) 2022-04-07 13:30:38 -03:00
Nicolas Giard 9a4505dc74
chore: remove svn/trac infrastructure (#3649) (#3739)
* chore: Remove svn/trac related infrastructure

* chore: Remove more svn/trac infrastructure

* fix: remove commented out Trac requirement
2022-03-24 12:24:35 -05:00
Jennifer Richards 6c260a5b7e Merge 7.45.1.dev0 into Bootstrap 5 update branch. Made a first pass at reconciling differences.
- Legacy-Id: 19945
2022-02-17 20:09:49 +00:00
Lars Eggert 64d2ba2558 Run tidy as part of tests, and fix HTML issues it finds.
- Legacy-Id: 19904
2022-02-01 16:11:34 +00:00
Robert Sparks 1c1d9e885a Add gunicorn to requirements to support new deployment model. Commit ready for merge.
- Legacy-Id: 19880
2022-01-27 15:58:21 +00:00
Lars Eggert cf629a42ad And more fixes.
- Legacy-Id: 19877
2022-01-25 10:14:25 +00:00
Robert Sparks 194c690f85 Merged in [19834] from lars@eggert.org:
Add djhtml (https://github.com/rtts/djhtml), for auto-reformatting of the Django
templates via 'djlint --profile django --reformat'.
It still has some bugs and issues, esp. on complex templates and with regards to
whitespace after links, but those are manageable, and the benefits of having
consistently-formatted templates IMO outweigh them.
 - Legacy-Id: 19847
Note: SVN reference [19834] has been migrated to Git commit f185da354a
2022-01-14 19:06:58 +00:00
Lars Eggert f185da354a Add djhtml (https://github.com/rtts/djhtml), for auto-reformatting of the Django
templates via "djlint --profile django --reformat".

It still has some bugs and issues, esp. on complex templates and with regards to
whitespace after links, but those are manageable, and the benefits of having
consistently-formatted templates IMO outweigh them.

Commit ready for merge.
 - Legacy-Id: 19834
2022-01-12 07:04:16 +00:00
Robert Sparks d41c94ba4c Pin tastypie at 0.14.3. Related to #3500. Commit ready to merge.
- Legacy-Id: 19804
2022-01-05 17:15:08 +00:00
Robert Sparks f6d13b434e Pin weasyprint to an earlier version because of packaging trouble with dependencies.
- Legacy-Id: 19769
2021-12-09 22:49:40 +00:00
Robert Sparks adbf8acb81 Provide pdfs of htmlized (pdfized) documents to replace tools.ietf.org/pdf/ at /doc/pdf. Commit ready for merge.
- Legacy-Id: 19753
2021-12-07 23:49:58 +00:00
Lars Eggert 5174cb3e6f Merge ^/personal/lars/7.39.1.dev4
- Legacy-Id: 19705
2021-11-24 09:35:06 +00:00
Robert Sparks 7da8d13d49 Update changelog, pin markdown
- Legacy-Id: 19681
2021-11-18 15:18:39 +00:00
Lars Eggert 2cef8b67cf Require django-bootstrap5
- Legacy-Id: 19582
2021-11-09 13:02:43 +00:00
nick e1c7ed4c2c fix: downgrade docker/Dockerfile to Python 3.6 and selenium 3.141.0
- Legacy-Id: 19546
2021-11-03 21:52:14 +00:00
Robert Sparks 4726214190 Merged in ^/personal/nick/7.39.1.dev0@19535 from nick@staff.ietf.org:
Provide a docker environment that is friendly to vs code.
 - Legacy-Id: 19536
2021-11-02 19:01:17 +00:00
nick 8559024b8b fix: django-debug-toolbar urls import + missing pip requirement
- Legacy-Id: 19534
2021-11-02 18:37:54 +00:00
Robert Sparks b6b3592d76 Merged in [19505] from lars@eggert.org:
Bump selenium requirement. Forgotten in r19432.
 - Legacy-Id: 19532
Note: SVN reference [19505] has been migrated to Git commit af92cf024fd1c081716ab7bd77c46fc1b248a111
2021-11-02 18:15:56 +00:00
Robert Sparks eefaf8f25c Pin factory-boy and Faker until they recoordinate
- Legacy-Id: 19498
2021-10-29 18:27:15 +00:00
Robert Sparks a8aab5cb17 Added scout-apm to the requirements and added settings scaffolding.
- Legacy-Id: 19399
2021-10-07 16:39:29 +00:00
Robert Sparks 6ac363e3e2 Remove remaining use of markdown2. Enable markdown extras when rendering agendas. Fixes #3316. Commit ready for merge.
- Legacy-Id: 19358
2021-09-08 17:54:40 +00:00
Robert Sparks b99eecc1ae Bring the factory-boy and Faker dependencies forward through some minor breaking changes. Stop using the deprecated fr_QC locale in Faker. Commit ready for merge.
- Legacy-Id: 19270
2021-08-03 22:22:35 +00:00
Robert Sparks 84717102b0 Add BOF Requests to the datatracker. Commit ready for merge.
- Legacy-Id: 19228
2021-07-15 20:15:54 +00:00
Robert Sparks 8e71f4113a Remove oic patch - 1.3.0 contains the fix. Commit ready for merge.
- Legacy-Id: 19214
2021-07-14 18:31:45 +00:00
Robert Sparks 6b383255ad Staging for merge forward
- Legacy-Id: 19199
2021-07-06 18:05:54 +00:00
Robert Sparks ccf33c323c Hold Unidecode before 1.2.0 for awhile before adjusting patch to match changed __init__.py
- Legacy-Id: 18831
2021-02-16 16:40:02 +00:00
Robert Sparks 6697a131cc Bump the required setuptools to at least the 51 releases to avoid issues with some python3.6 -mvenv installed ssetuptools.
- Legacy-Id: 18818
2021-02-01 21:23:13 +00:00
Robert Sparks 8a8202d757 constrain python-libmagic to at most 0.4.18. .20 breaks, .19 is not reflected at Pypi.
- Legacy-Id: 18811
2021-02-01 16:01:40 +00:00
Robert Sparks c0a1d4e2c8 Allow setuptools to progress past py27
- Legacy-Id: 18779
2020-12-17 16:55:17 +00:00
Robert Sparks ee600c76b8 Don't allow mysqlclient 2.0.2 due to compilation issues.
- Legacy-Id: 18762
2020-12-11 22:02:13 +00:00
Henrik Levkowetz f41fd1867d Upgraded the required versions of mypy and django-stubs to the latest that support Django 2.2. Fixed some issues found by after the upgrades.
- Legacy-Id: 18717
2020-11-22 21:13:36 +00:00
Robert Sparks 30ac9833c5 Provide a management command to inform github backups. Commit ready for merge.
- Legacy-Id: 18445
2020-08-28 15:34:25 +00:00