Skip to content

Support guzzlehttp/guzzle:^8.0.2 #336

Description

@juukie

Having a new major version of guzzlehttp/guzzle ^8.0.2, it would be nice if this package gets compatible.

As far as I could see:

Header values passed to guzzle should be of type string. For example:

// Before
$headers = [
    'Resource-ID' => 123,
];

// After
$headers = [
    'Resource-ID' => '123',
];

Guzzle GuzzleHttp\Psr7\Request method isn't uppercased

When using new GuzzleHttp\Psr7\Request(..), the method isn't uppercased anymore. Resulting in one assert to fail in IncomingWebhookTest::testMakesWebhookFromGlobals.

Guzzle's RequestException constructor's signature changed.

// < 8
public function __construct(string $message, RequestInterface $request, ?ResponseInterface $response = null, ?\Throwable $previous = null, array $handlerContext = [])

// 8
public function __construct(string $message, RequestInterface $request, int $code = 0, ?\Throwable $previous = null)

There are three exceptions extending the RequestException:

  • AuthenticationException
  • RateLimitExceededException
  • ValidationErrorException

I'd love to contribute to making it compatible, but don't know what steps would be best.

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