-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Duplicate IDs when indexing #1716
Comments
Thank you so much for the report! |
369: Add test checking the bug reported in meilisearch issue 1716 r=Kerollmops a=ManyTheFish The bug is not present in the newer milli version. Related to [Meilisearch#1716](meilisearch/meilisearch#1716) Co-authored-by: many <maxime@meilisearch.com>
Hello @philippeauriach! Thanks for your bug report, this should be fixed in the next version of Meilisearch. The bug occurs because a Document addition of philippeauriach/meilisearch-dup-id#1 Thanks again for your issue! 👍 |
FWIW, I've come across this issue with a pure Ruby client. Now I don't know if it is the same issue or not, but there is how you can recreate it: (in this example
This will break the index in a way that while the API returns the documents correctly with This means if you run the first line again (add docs), you will end up with duplicates. This is caused by adding an empty array. Here is how you can reproduce it with only CURL on a clean setup: $ curl -X POST http://localhost:7700/indexes/acme/documents --data '[{"id": "foo"}, {"id":"bar"}]'
$ curl http://localhost:7700/indexes/acme/documents/foo
{"id":"foo"}
$curl -X POST http://localhost:7700/indexes/acme/documents --data '[]'
$curl http://localhost:7700/indexes/acme/documents/foo
{"message":"Document with id foo not found.","errorCode":"document_not_found","errorType":"invalid_request_error","errorLink":"https://docs.meilisearch.com/errors#document_not_found"} All the while, |
Hello @khash! Your bug should not be present in the next version. I did not succeed to reproduce your issue on our branch that will be merged into |
Closed by #1711 |
I face this problem in version 0.29.1 when I update index setting more than 1 time. Before update : Every works fine |
Indeed it looks related to #3021 and will be fixed in the next release of Meilisearch, i.e. v0.30. |
Describe the bug
Uploading several batches of the same content result in duplicates ids in meilisearch. Objects are coming from a Strapi service, and sent to a meilisearch instance (local docker latest image : 0.22.0) via the meilisearch nodejs package.
Full reproduction project available at : https://github.com/philippeauriach/meilisearch-dup-id
To Reproduce
hooks/meilisearch/utils.js
if neededyarn install
yarn develop
yarn develop
Expected behavior
Products should be replaced when having the same ID
Screenshots
MeiliSearch version: v0.22.0
Additional context
Strapi ?
The text was updated successfully, but these errors were encountered: