Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Async builtin view decorators 2 #1

Closed
wants to merge 18 commits into from

Conversation

LomaxOnTheRun
Copy link
Owner

@LomaxOnTheRun LomaxOnTheRun commented Jul 7, 2022

PR just so I can see the diffs more clearly, and can track thoughts and issues in the PR description.

Decorators:

  • @cache_page (uses decorator_from_middleware_with_args)
  • @cache_control
  • @never_cache
  • @xframe_options_deny
  • @xframe_options_sameorigin
  • @xframe_options_exempt
  • no_append_slash
  • @csrf_protect (uses decorator_from_middleware)
  • @requires_csrf_token (uses decorator_from_middleware)
  • @ensure_csrf_cookie (uses decorator_from_middleware)
  • @csrf_exempt
  • @sensitive_variables
    • This is a weird one because it is applied to any function, not just views. This means that the sync_async_wrapper can't be used because it requires a request positional argument.
  • @sensitive_post_parameters
  • @gzip_page (uses decorator_from_middleware)
  • conditional_page (uses decorator_from_middleware)
  • @require_http_methods
  • @require_GET
  • @require_POST
  • @require_safe
  • @condition
    • Uses get_conditional_response function which will need to be made async
  • @etag
    • Uses get_conditional_response function which will need to be made async
  • @last_modified
    • Uses get_conditional_response function which will need to be made async
  • @vary_on_headers
  • @vary_on_cookie

@github-actions
Copy link

github-actions bot commented Jul 7, 2022

Hello @LomaxOnTheRun! Thank you for your contribution 💪

As it's your first contribution be sure to check out the patch review checklist.

If you're fixing a ticket from Trac make sure to set the "Has patch" flag and include a link to this PR in the ticket!

If you have any design or process questions then you can ask in the Django forum.

Welcome aboard ⛵️!

@LomaxOnTheRun LomaxOnTheRun force-pushed the async-builtin-view-decorators-2 branch 4 times, most recently from d5273d9 to 4bd0a9c Compare July 8, 2022 21:41
@LomaxOnTheRun LomaxOnTheRun force-pushed the async-builtin-view-decorators-2 branch 2 times, most recently from f67dffa to 461d80c Compare July 16, 2022 21:12
Co-authored-by: Hendrik Frentrup <hendrik.frentrup@gmail.com>
@LomaxOnTheRun LomaxOnTheRun force-pushed the async-builtin-view-decorators-2 branch 2 times, most recently from 46a1540 to 09b6b72 Compare July 17, 2022 21:42
@LomaxOnTheRun LomaxOnTheRun force-pushed the async-builtin-view-decorators-2 branch from 09b6b72 to 2dc8d8c Compare July 17, 2022 21:47
@LomaxOnTheRun LomaxOnTheRun force-pushed the async-builtin-view-decorators-2 branch from 2dc8d8c to 6f1da13 Compare July 20, 2022 19:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant