MeiliSearch/meilisearch-lib/src
bors[bot] 9e344f6576
Merge #2207
2207: Fix: avoid embedding the user input into the error response. r=Kerollmops a=CNLHC

# Pull Request

## What does this PR do?
Fix #2107. 

The problem is meilisearch embeds the user input to the error message. 

The reason for this problem is `milli` throws a `serde_json: Error` whose `Display` implementation will do this embedding.  

I tried to solve this problem in this PR by manually implementing the `Display` trait for `DocumentFormatError` instead of deriving automatically.

<!-- Please link the issue you're trying to fix with this PR, if none then please create an issue first. -->

## PR checklist
Please check if your PR fulfills the following requirements:
- [x] Does this PR fix an existing issue?
- [x] Have you read the contributing guidelines?
- [x] Have you made sure that the title is accurate and descriptive of the changes?

Thank you so much for contributing to Meilisearch!


Co-authored-by: Liu Hancheng <cn_lhc@qq.com>
Co-authored-by: LiuHanCheng <2463765697@qq.com>
2022-04-04 17:35:17 +00:00
..
index Make sure that offsets are clamped too 2022-03-30 10:06:15 -07:00
index_controller chore(all): bump milli 2022-03-16 16:34:44 +01:00
index_resolver chore(all): bump milli 2022-03-16 16:34:44 +01:00
tasks chore(all): bump milli 2022-03-16 16:34:44 +01:00
analytics.rs rename user-id to instance-uid 2021-10-29 17:25:52 +02:00
compression.rs implement new dump v2 2021-09-30 14:49:13 +02:00
document_formats.rs change truncate strategy and coresponding test 2022-03-31 10:39:21 +08:00
error.rs feat(auth): API keys 2021-12-06 09:52:41 +01:00
lib.rs Export milli's heed from meilisearch-lib 2022-03-24 15:30:10 +01:00
options.rs Add more detailed comments for max_indexing_threads 2022-03-31 09:32:45 +09:00
snapshot.rs chore(all): bump milli 2022-03-16 16:34:44 +01:00
update_file_store.rs feat(all): Task store 2021-12-02 20:14:42 +01:00