phacility/phabricator · error · PhutilProxyException

Expected valid JSON response from GitHub account data reques

Error message

Expected valid JSON response from GitHub account data request.

What it means

Error "Expected valid JSON response from GitHub account data request." thrown in phacility/phabricator.

Source

Thrown at src/applications/auth/adapter/PhutilGitHubAuthAdapter.php:70

  protected function loadOAuthAccountData() {
    $uri = new PhutilURI('https://api.github.com/user');

    $future = new HTTPSFuture($uri);

    // NOTE: GitHub requires a User-Agent string.
    $future->addHeader('User-Agent', __CLASS__);

    // See T13485. Circa early 2020, GitHub has deprecated use of the
    // "access_token" URI parameter.
    $token_header = sprintf('token %s', $this->getAccessToken());
    $future->addHeader('Authorization', $token_header);

    list($body) = $future->resolvex();

    try {
      return phutil_json_decode($body);
    } catch (PhutilJSONParserException $ex) {
      throw new PhutilProxyException(
        pht('Expected valid JSON response from GitHub account data request.'),
        $ex);
    }
  }

}

View on GitHub (pinned to 5720a38cfe)

When it happens

Trigger: Thrown at src/applications/auth/adapter/PhutilGitHubAuthAdapter.php:70 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21). Data as JSON: /api/errors/ab6187ab1844e27b. Report an issue: GitHub.