Skip to content

WithPriority leads to deserialization errors #30

@mujahidislam

Description

@mujahidislam

While using "WithPriority", it seems like in case a duplicate request is made, it leads to deserialization error with inner exception says "System.ObjectDisposedException: Cannot access a disposed object."

Logs are as follows:

: Same request has been sent yet. Waiting for it.

An error occured deserializing the response. ---> Refit.ApiException: An error occured deserializing the response. ---> System.ObjectDisposedException: Cannot access a disposed object. Object name: 'System.Net.Http.HttpConnectionResponseContent'. at System.Net.Http.HttpContent.ReadAsStreamAsync(CancellationToken cancellationToken) at System.Net.Http.Json.HttpContentJsonExtensions.GetContentStreamAsync(HttpContent content, CancellationToken cancellationToken) at System.Net.Http.Json.HttpContentJsonExtensions.ReadFromJsonAsyncCore[T](HttpContent content, JsonSerializerOptions options, CancellationToken cancellationToken) at Refit.SystemTextJsonContentSerializer.FromHttpContentAsync[T](HttpContent content, CancellationToken cancellationToken) in c:\temp\releaser\refit\Refit\SystemTextJsonContentSerializer.cs:line 48 at Refit.RequestBuilderImplementation.DeserializeContentAsync[T](HttpResponseMessage resp, HttpContent content, CancellationToken cancellationToken) in c:\temp\releaser\refit\Refit\RequestBuilderImplementation.cs:line 465 at Refit.RequestBuilderImplementation.<>c__DisplayClass15_02.<b__0>d.MoveNext() in c:\temp\releaser\refit\Refit\RequestBuilderImplementation.cs:line 350
--- End of inner exception stack trace ---
--- End of inner exception stack trace ---`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions