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

[Backport 8.x] Use Python types to declare document fields #1847

Merged
merged 1 commit into from
Jun 21, 2024

Commits on Jun 21, 2024

  1. Use Python types to declare document fields (#1845)

    * basic type annotation support
    
    * support for optional, list, and other type hints
    
    * additional typing support
    
    * dataclass-like behavior for Document and InnerDoc
    
    * unit tests
    
    * support InstrumentedField in Search class
    
    * documentation
    
    * Update docs/persistence.rst
    
    Co-authored-by: Quentin Pradet <quentin.pradet@gmail.com>
    
    * Update elasticsearch_dsl/document_base.py
    
    Co-authored-by: Quentin Pradet <quentin.pradet@gmail.com>
    
    * addressed review feedback
    
    * better docs for Optional
    
    * fix optional in test
    
    ---------
    
    Co-authored-by: Quentin Pradet <quentin.pradet@gmail.com>
    (cherry picked from commit 0c3ffcd)
    miguelgrinberg authored and github-actions[bot] committed Jun 21, 2024
    Configuration menu
    Copy the full SHA
    f165e05 View commit details
    Browse the repository at this point in the history