-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
757: Fixing empty TaskError response r=curquiza a=larskristianhaga # Pull Request Seems like the `TaskError` object is only returning empty Strings when trying to get the error details of a task. Seems to be a missmatch between the field naming, and number of fields based on the API response. Therefor it dosent understand what to map, and only gives empty strings back. ## Related issue None ## What does this PR do? - It moves the `TaskError` class to the `model` package, closer to the usage in `Task` class. - Since its peers`TaskDetails`, and `TaskStatus` are already here. - Updates the field in `TaskError` to match the API naming, and number of fields. - Updates the Exception integration test to use the correct naming and import. - Adds Integration tests to check that `TaskError` fields is not blank or null. ## PR checklist Please check if your PR fulfills the following requirements: - [X] Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)? - [X] Have you read the contributing guidelines? - [X] Have you made sure that the title is accurate and descriptive of the changes? Co-authored-by: larskristianhaga <[email protected]>
- Loading branch information
Showing
5 changed files
with
64 additions
and
20 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package com.meilisearch.sdk.model; | ||
|
||
import lombok.Getter; | ||
import lombok.Setter; | ||
|
||
/** The code, type‚ error and message of the task error */ | ||
@Getter | ||
@Setter | ||
public class TaskError { | ||
|
||
public TaskError() {} | ||
|
||
protected String code = ""; | ||
protected String type = ""; | ||
protected String link = ""; | ||
protected String message = ""; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters