title: HttpClient.GetStreamAsync stuck
body: <p>I use <code>HttpClient</code> to make a <code>GET</code> request to the API that should return me JSON data but my request is stuck at <code>GetStreamAsync</code>. I was debugged it before when it come to <code>await that.GetStreamAsync(url);</code> my debugger is gone. Disappear. I try to fixed it for a day but still not work. At first, I think it was my proxy problem, but it isn't. Then, I try to use <code>HttpRequest</code> it work fine.</p>
  
  <p>Here is my class.</p>
  
  <pre><code>public async Task&lt;bool&gt; RequestToApi(string response)
  {
      HttpClientHandler httpClientHandler = new HttpClientHandler();
      if (_cdnResProxy.Value.Length &gt; 0 &amp;&amp; _cdnResPort.Value &gt; 0)
      {
          httpClientHandler.Proxy = new WebProxy(string.Format("{0}:{1}",
          _cdnResProxy.Value,
          _cdnResPort.Value))
          { BypassProxyOnLocal = true };
      }
  
      //try to remove proxy here already but still not work
  
      using (var hClient = new HttpClient(httpClientHandler))
      {
          hClient.DefaultRequestHeaders.ExpectContinue = false;
          var result = await hClient.Get&lt;ResponseObj&gt;(
               $"https://www.example.com/api/somepath?something={someValue}");
  
          return result.success;
      }
  }
  
  public static class HttpClientExtension
  {
      public static async Task&lt;T&gt; Get&lt;T&gt;(this HttpClient that, string url)
      {
          var stream = await that.GetStreamAsync(url); //stuck here
          JsonSerializer serializer = new JsonSerializer();
          T data;
          using (StreamReader streamReader = new StreamReader(stream))
          {
              data = (T)serializer.Deserialize(streamReader, typeof(T));
          }
  
          return data;
      }
  }
  </code></pre>
  
  <p>This's my controller.</p>
  
  <pre><code>    [HttpPost]
      [SwaggerVisible]
      [SwaggerOperation("SignIn_VerifyCaptchaAction")]
      [SwaggerResponse(HttpStatusCode.OK, Type = typeof(bool))]
      public bool RecaptchaSubmit(string response)
      {
          return _service.RecaptchaSubmit(response).Result;
      }
  </code></pre>
  
  <p>This is my <code>Http</code>package version : </p>
  
  <pre><code>&lt;package id="System.Net.Http" version="4.3.2" targetFramework="net462" /&gt;
  </code></pre>
  
  <p>Here is the method I try already.</p>
  
  <pre><code>var stream = await that.GetStreamAsync(url).ConfigureAwait(false);
  </code></pre>