You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
76: Update old code r=curquiza a=Mubelotix
I copied a few data structures from the meilisearch core project when I started this SDK.
It seems that these structs and enums were modified during the last months and that breaking changes were introduced.
It would be useful if GitHub allowed me to subscribe to the changes on the 2 concerned files but it's not possible.
### TODO
- [x] Update the outdated code
- [x] Add new tests so that we can detect breaking changes faster (note that test structure is not ideal and there will be a new PR about this)
Co-authored-by: Mubelotix <[email protected]>
Copy file name to clipboardExpand all lines: src/indexes.rs
+13-7Lines changed: 13 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -338,7 +338,7 @@ impl<'a> Index<'a> {
338
338
/// let client = Client::new("http://localhost:7700", "masterKey");
339
339
/// let mut movie_index = client.get_or_create("movies_add_or_replace").await.unwrap();
340
340
///
341
-
/// movie_index.add_or_replace(&[
341
+
/// let progress = movie_index.add_or_replace(&[
342
342
/// Movie{
343
343
/// name: String::from("Interstellar"),
344
344
/// description: String::from("Interstellar chronicles the adventures of a group of explorers who make use of a newly discovered wormhole to surpass the limitations on human space travel and conquer the vast distances involved in an interstellar voyage.")
@@ -354,6 +354,7 @@ impl<'a> Index<'a> {
354
354
/// },
355
355
/// ], Some("name")).await.unwrap();
356
356
/// sleep(Duration::from_secs(1)); // MeiliSearch may take some time to execute the request
357
+
/// # progress.get_status().await.unwrap();
357
358
///
358
359
/// // retrieve movies (you have to put some movies in the index before)
359
360
/// let movies = movie_index.get_documents::<Movie>(None, None, None).await.unwrap();
@@ -425,7 +426,7 @@ impl<'a> Index<'a> {
425
426
/// let client = Client::new("http://localhost:7700", "masterKey");
426
427
/// let mut movie_index = client.get_or_create("movies_add_or_update").await.unwrap();
427
428
///
428
-
/// movie_index.add_or_update(&[
429
+
/// let progress = movie_index.add_or_update(&[
429
430
/// Movie{
430
431
/// name: String::from("Interstellar"),
431
432
/// description: String::from("Interstellar chronicles the adventures of a group of explorers who make use of a newly discovered wormhole to surpass the limitations on human space travel and conquer the vast distances involved in an interstellar voyage.")
@@ -441,6 +442,7 @@ impl<'a> Index<'a> {
441
442
/// },
442
443
/// ], Some("name")).await.unwrap();
443
444
/// sleep(Duration::from_secs(1)); // MeiliSearch may take some time to execute the request
445
+
/// # progress.get_status().await.unwrap();
444
446
///
445
447
/// // retrieve movies (you have to put some movies in the index before)
446
448
/// let movies = movie_index.get_documents::<Movie>(None, None, None).await.unwrap();
0 commit comments