Skip to content

Adds typing to context where important for new multi-value headers, and streamlines header setting & getting #421

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

Open
wants to merge 22 commits into
base: main
Choose a base branch
from

Conversation

bitterpanda63
Copy link
Member

This update streamlines the context initialization process for WSGI and ASGI environments by:

  • Decoupling context creation from attribute setting.
  • Introducing WSGIContext and ASGIContext data classes to encapsulate parsed request data.
  • Adding type hints for improved code clarity and maintainability.
  • Adding a get_header function to the Context class for simplified header access.

These changes improve the modularity and testability of the context handling logic.

@bitterpanda63 bitterpanda63 changed the title Refactors context handling and data extraction Adds typing to context where important for new multi-value headers, and streamlines header setting & getting Jul 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant