|
15 | 15 | # specific language governing permissions and limitations
|
16 | 16 | # under the License.
|
17 | 17 |
|
18 |
| -from . import async_connections, connections |
19 |
| -from .aggs import A, Agg |
20 |
| -from .analysis import analyzer, char_filter, normalizer, token_filter, tokenizer |
21 |
| -from .document import AsyncDocument, Document |
22 |
| -from .document_base import InnerDoc, M, MetaField, mapped_field |
23 |
| -from .exceptions import ( |
24 |
| - ElasticsearchDslException, |
25 |
| - IllegalOperation, |
26 |
| - UnknownDslObject, |
27 |
| - ValidationException, |
28 |
| -) |
29 |
| -from .faceted_search import ( |
30 |
| - AsyncFacetedSearch, |
31 |
| - DateHistogramFacet, |
32 |
| - Facet, |
33 |
| - FacetedResponse, |
34 |
| - FacetedSearch, |
35 |
| - HistogramFacet, |
36 |
| - NestedFacet, |
37 |
| - RangeFacet, |
38 |
| - TermsFacet, |
39 |
| -) |
40 |
| -from .field import ( |
41 |
| - Binary, |
42 |
| - Boolean, |
43 |
| - Byte, |
44 |
| - Completion, |
45 |
| - ConstantKeyword, |
46 |
| - CustomField, |
47 |
| - Date, |
48 |
| - DateRange, |
49 |
| - DenseVector, |
50 |
| - Double, |
51 |
| - DoubleRange, |
52 |
| - Field, |
53 |
| - Float, |
54 |
| - FloatRange, |
55 |
| - GeoPoint, |
56 |
| - GeoShape, |
57 |
| - HalfFloat, |
58 |
| - Integer, |
59 |
| - IntegerRange, |
60 |
| - Ip, |
61 |
| - IpRange, |
62 |
| - Join, |
63 |
| - Keyword, |
64 |
| - Long, |
65 |
| - LongRange, |
66 |
| - Murmur3, |
67 |
| - Nested, |
68 |
| - Object, |
69 |
| - Percolator, |
70 |
| - Point, |
71 |
| - RangeField, |
72 |
| - RankFeature, |
73 |
| - RankFeatures, |
74 |
| - ScaledFloat, |
75 |
| - SearchAsYouType, |
76 |
| - Shape, |
77 |
| - Short, |
78 |
| - SparseVector, |
79 |
| - Text, |
80 |
| - TokenCount, |
81 |
| - construct_field, |
82 |
| -) |
83 |
| -from .function import SF |
84 |
| -from .index import ( |
85 |
| - AsyncComposableIndexTemplate, |
86 |
| - AsyncIndex, |
87 |
| - AsyncIndexTemplate, |
88 |
| - ComposableIndexTemplate, |
89 |
| - Index, |
90 |
| - IndexTemplate, |
91 |
| -) |
92 |
| -from .mapping import AsyncMapping, Mapping |
93 |
| -from .query import Q, Query |
94 |
| -from .response import AggResponse, Response, UpdateByQueryResponse |
95 |
| -from .search import ( |
96 |
| - AsyncEmptySearch, |
97 |
| - AsyncMultiSearch, |
98 |
| - AsyncSearch, |
99 |
| - EmptySearch, |
100 |
| - MultiSearch, |
101 |
| - Search, |
102 |
| -) |
103 |
| -from .update_by_query import AsyncUpdateByQuery, UpdateByQuery |
104 |
| -from .utils import AttrDict, AttrList, DslBase |
105 |
| -from .wrappers import Range |
| 18 | +import sys |
106 | 19 |
|
107 |
| -VERSION = (8, 17, 1) |
108 |
| -__version__ = VERSION |
| 20 | +from elasticsearch import __version__, dsl # noqa: F401 |
| 21 | + |
| 22 | +VERSION = __version__ |
109 | 23 | __versionstr__ = ".".join(map(str, VERSION))
|
110 |
| -__all__ = [ |
111 |
| - "A", |
112 |
| - "Agg", |
113 |
| - "AggResponse", |
114 |
| - "AsyncComposableIndexTemplate", |
115 |
| - "AsyncDocument", |
116 |
| - "AsyncEmptySearch", |
117 |
| - "AsyncFacetedSearch", |
118 |
| - "AsyncIndex", |
119 |
| - "AsyncIndexTemplate", |
120 |
| - "AsyncMapping", |
121 |
| - "AsyncMultiSearch", |
122 |
| - "AsyncSearch", |
123 |
| - "AsyncUpdateByQuery", |
124 |
| - "AttrDict", |
125 |
| - "AttrList", |
126 |
| - "Binary", |
127 |
| - "Boolean", |
128 |
| - "Byte", |
129 |
| - "Completion", |
130 |
| - "ComposableIndexTemplate", |
131 |
| - "ConstantKeyword", |
132 |
| - "CustomField", |
133 |
| - "Date", |
134 |
| - "DateHistogramFacet", |
135 |
| - "DateRange", |
136 |
| - "DenseVector", |
137 |
| - "Document", |
138 |
| - "Double", |
139 |
| - "DoubleRange", |
140 |
| - "DslBase", |
141 |
| - "ElasticsearchDslException", |
142 |
| - "EmptySearch", |
143 |
| - "Facet", |
144 |
| - "FacetedResponse", |
145 |
| - "FacetedSearch", |
146 |
| - "Field", |
147 |
| - "Float", |
148 |
| - "FloatRange", |
149 |
| - "GeoPoint", |
150 |
| - "GeoShape", |
151 |
| - "HalfFloat", |
152 |
| - "HistogramFacet", |
153 |
| - "IllegalOperation", |
154 |
| - "Index", |
155 |
| - "IndexTemplate", |
156 |
| - "InnerDoc", |
157 |
| - "Integer", |
158 |
| - "IntegerRange", |
159 |
| - "Ip", |
160 |
| - "IpRange", |
161 |
| - "Join", |
162 |
| - "Keyword", |
163 |
| - "Long", |
164 |
| - "LongRange", |
165 |
| - "M", |
166 |
| - "Mapping", |
167 |
| - "MetaField", |
168 |
| - "MultiSearch", |
169 |
| - "Murmur3", |
170 |
| - "Nested", |
171 |
| - "NestedFacet", |
172 |
| - "Object", |
173 |
| - "Percolator", |
174 |
| - "Point", |
175 |
| - "Q", |
176 |
| - "Query", |
177 |
| - "Range", |
178 |
| - "RangeFacet", |
179 |
| - "RangeField", |
180 |
| - "RankFeature", |
181 |
| - "RankFeatures", |
182 |
| - "Response", |
183 |
| - "SF", |
184 |
| - "ScaledFloat", |
185 |
| - "Search", |
186 |
| - "SearchAsYouType", |
187 |
| - "Shape", |
188 |
| - "Short", |
189 |
| - "SparseVector", |
190 |
| - "TermsFacet", |
191 |
| - "Text", |
192 |
| - "TokenCount", |
193 |
| - "UnknownDslObject", |
194 |
| - "UpdateByQuery", |
195 |
| - "UpdateByQueryResponse", |
196 |
| - "ValidationException", |
197 |
| - "analyzer", |
198 |
| - "async_connections", |
199 |
| - "char_filter", |
200 |
| - "connections", |
201 |
| - "construct_field", |
202 |
| - "mapped_field", |
203 |
| - "normalizer", |
204 |
| - "token_filter", |
205 |
| - "tokenizer", |
206 |
| -] |
| 24 | + |
| 25 | +modules = [mod for mod in sys.modules.keys() if mod.startswith("elasticsearch.dsl")] |
| 26 | +for mod in modules: |
| 27 | + sys.modules[mod.replace("elasticsearch.dsl", "elasticsearch_dsl")] = sys.modules[ |
| 28 | + mod |
| 29 | + ] |
0 commit comments