Hello,
When defining a document using typehints, the way it should working according to the documentation is not working. I have a document in which i have a field org_type, when defining it as follows it works
org_type = Keyword(required=True)
But when adding typehints, it will no longer be added to my index parameters in Elastic (using the document.Init() method).
I have tried several options including the following
Hello, When defining a document using typehints, the way it should working according to the documentation is not working. I have a document in which i have a field org_type, when defining it as follows it works
But when adding typehints, it will no longer be added to my index parameters in Elastic (using the document.Init() method). I have tried several options including the following
This is exactly how the documentation suggests to add typehints according to this page https://elasticsearch-dsl.readthedocs.io/en/latest/persistence.html#python-type-hints
Adding typehint only will work, but now MyPy is complaining about incompatible types
I am using the latest version (8.15.4) at the moment of writing in combination with python version 3.11.9.