Skip to content

fix: resolved error handling of larger batch request message #916

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

Merged
merged 10 commits into from
Sep 10, 2024

Conversation

andrueastman
Copy link
Member

@andrueastman andrueastman commented Sep 10, 2024

Fixes microsoftgraph/msgraph-sdk-dotnet#2661
Fixes microsoftgraph/msgraph-sdk-dotnet#2660

Larger batch response is currently not validated for success status code due to the use of the NativeResponseHandler.
This PR adds a validation of the same in the BatchRequestBuilder to ensure the reponse is valid for handling.

Microsoft Reviewers: Open in CodeFlow

@andrueastman andrueastman marked this pull request as ready for review September 10, 2024 09:41
@andrueastman andrueastman requested a review from a team as a code owner September 10, 2024 09:41
@andrueastman andrueastman requested a review from baywet September 10, 2024 13:31
Copy link
Member

@baywet baywet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should work just the same while simplifying the code, we might even be able to get rid of the string is null or empty

Co-authored-by: Vincent Biret <vibiret@microsoft.com>
baywet
baywet previously approved these changes Sep 10, 2024
Copy link
Member

@baywet baywet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for making the changes!

baywet
baywet previously approved these changes Sep 10, 2024
@andrueastman andrueastman requested a review from baywet September 10, 2024 14:59
… cancellation token

Signed-off-by: Vincent Biret <vibiret@microsoft.com>
Signed-off-by: Vincent Biret <vibiret@microsoft.com>
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
79.2% Coverage on New Code (required ≥ 80%)

See analysis details on SonarCloud

@andrueastman andrueastman merged commit de75d5c into main Sep 10, 2024
8 of 9 checks passed
@andrueastman andrueastman deleted the andrueastman/fixBatch branch September 10, 2024 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to deserialize content from batch request, Graph API appears to be returning HTML which is not handled by SDK Info on 401 in Batch.PostAsync
2 participants