Skip to content
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

[BUG] Response was not set, make sure SendAsync was called #47917

Open
aspallsux opened this issue Jan 21, 2025 · 2 comments
Open

[BUG] Response was not set, make sure SendAsync was called #47917

aspallsux opened this issue Jan 21, 2025 · 2 comments
Assignees
Labels
Azure.Core Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that

Comments

@aspallsux
Copy link

Library name and version

Azure.Storage.Blobs 12.23.0

Describe the bug

Sometimes when calling methods in Azure.Storage.Blobs, an InvalidOperationException is thrown with the message Response was not set, make sure SendAsync was called.

Expected behavior

Methods should not throw, or should throw RequestFailedException.

Actual behavior

Attached a partial stack trace from App Insights where Azure.Core.Pipeline.RedirectPolicy.ProcessAsync is the final call, implying it's the cause:

error.json

It looks like it comes from this line, which accesses message.Response:

Response response = message.Response;

Other places in code (e.g., RetryPolicy) check whether a Response exists before accessing the property:

if (lastException != null || (message.HasResponse && message.Response.IsError))

Reproduction Steps

Random.

Environment

No response

@github-actions github-actions bot added Azure.Core Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Jan 21, 2025
Copy link

Thank you for your feedback. Tagging and routing to the team member best able to assist.

@jsquire jsquire assigned m-nash and unassigned annelo-msft Jan 21, 2025
@jsquire
Copy link
Member

jsquire commented Jan 21, 2025

@m-nash: Would you please take a look?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Azure.Core Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Projects
None yet
Development

No branches or pull requests

4 participants