-
Notifications
You must be signed in to change notification settings - Fork 121
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
[BUG] index() complains on a different type that set up in mappings #780
Labels
Comments
Is this the print out of the index's mappings using
|
Yes, that's it. Actually, it started working somehow. I kept creating and
deleting the index trying to find the reason and suddenly it worked.
Working since then. As if the index was to blame, not Js client. But of
course I am guessing here.
…On Mon, Jun 3, 2024, 21:02 Theo Nam Truong ***@***.***> wrote:
Is this the print out of the index's mappings?
labels: {
type: 'nested',
include_in_root: true, // this allows to search in 'labels' without filtering
properties: {
id: {
type: 'keyword'
},
name: {
type: 'text',
analyzer: 'keyword',
fields: {
raw: {
type: 'keyword'
}
}
},
confidence: {
type: 'float',
coerce: true
},
status: {
type: 'keyword'
},
description: {
type: 'text'
}
}
},
—
Reply to this email directly, view it on GitHub
<#780 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABBI253AOMOAMMCOW63FM5LZFSORJAVCNFSM6AAAAABIHE65SSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBVG4YDSNZUGU>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Let's close. If you can reproduce this outside of the client that'd be great @PlkMarudny. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the bug?
I have an index with defined mappings, so no dynamic mapping happens, the interesting part is here:
I try to use index() function like below:
And OpenSearch throws an error:
I suspect that the
confidence: 100
is a problem,100
being treated aslong
that cannot be coerced tofloat
(but why?), however, the same document got indexed properly is used at/ans/_doc/id
endpoint with a simple POST request.How can one reproduce the bug?
What is the expected behavior?
I expect the document to be indexed.
What is your host/environment?
Windows 10, AWS hosted OpenSearch, Node client 2.8.0
Do you have any screenshots?
If applicable, add screenshots to help explain your problem.
Do you have any additional context?
100
value seems to be a number like any other number with decimal places in the document I try to index.The text was updated successfully, but these errors were encountered: