Description
The server returns an "unknown query type" error. The SDK is setting the field 'regex' in the request, but the server expects a 'regexp' field
For example:
InternalServerFailureException(<ec=5, category=couchbase.common, message=internal_server_failure (5), context=SearchErrorContext({'last_dispatched_to': '127.0.0.1:8094', 'last_dispatched_from': '127.0.0.1:63908', 'retry_attempts': 0, 'client_context_id': '920405-19d8-3044-7c95-8b66e2eeaa0591', 'method': 'POST', 'path': '/api/index/global_index_0b920c/query', 'http_status': 400, 'http_body': '{"error":"rest_index: Query, indexName: global_index_0b920c, err: bleve: QueryBleve parsing searchRequest, err: unknown query type","request":{"ctl":{"timeout":75000},"explain":false,"query":{"regex":".*hae.*"}},"status":"fail"}\n', 'index_name': 'global_index_0b920c', 'query': '{"regex": ".*hae.*"}', 'parameters': '{"ctl":{"timeout":75000},"explain":false,"query":{"regex":".*hae.*"}}', 'context_type': 'SearchErrorContext'}), C Source=[...]/couchbase-python-client/src/search.cxx:551>) |
Attachments
For Gerrit Dashboard: PYCBC-1490 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
192143,4 | PYCBC-1490: Rename 'regex' field to 'regexp' in RegexQuery so it is recognised by the server | master | couchbase-python-client | Status: MERGED | +2 | +1 |