From f0040ce53e8f9e5e6db4cfb31836ac9481e87e0f Mon Sep 17 00:00:00 2001 From: Sean Whalen Date: Wed, 1 Aug 2018 08:51:42 -0400 Subject: [PATCH] Change uses of DocType to Document support refactoring in Elasticsearch 6.2.0 https://github.com/elastic/elasticsearch-dsl-py/blob/master/Changelog.rst#620-2018-07-03 --- parsedmarc/elastic.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/parsedmarc/elastic.py b/parsedmarc/elastic.py index d06db68..e0ff7ff 100644 --- a/parsedmarc/elastic.py +++ b/parsedmarc/elastic.py @@ -4,7 +4,7 @@ from collections import OrderedDict import parsedmarc from elasticsearch_dsl.search import Q -from elasticsearch_dsl import connections, Object, DocType, Index, Nested, \ +from elasticsearch_dsl import connections, Object, Document, Index, Nested, \ InnerDoc, Integer, Text, Boolean, DateRange, Ip, Date aggregate_index = Index("dmarc_aggregate") @@ -37,7 +37,7 @@ class _SPFResult(InnerDoc): results = Text() -class _AggregateReportDoc(DocType): +class _AggregateReportDoc(Document): class Index: name = "dmarc_aggregate" @@ -92,7 +92,7 @@ class _EmailAddressDoc(InnerDoc): address = Text() -class _EmailAttachmentDoc(DocType): +class _EmailAttachmentDoc(Document): filename = Text() content_type = Text() @@ -133,7 +133,7 @@ class _ForensicSampleDoc(InnerDoc): content_type=content_type) -class _ForensicReportDoc(DocType): +class _ForensicReportDoc(Document): class Index: name = "dmarc_forensic"