gax-php icon indicating copy to clipboard operation
gax-php copied to clipboard

RetryMiddleware uses CredentialsWrapper scope when invoked

Open pkruithof opened this issue 5 months ago • 0 comments

The RetryMiddleware triggers a fatal error in some conditions: Call to undefined method Google\ApiCore\CredentialsWrapper::getRetryFunction()

The issue is caused when the middleware is invoked, seemingly with the scope of the CredentialsWrapper, causing the getRetryFunction() method not to be found in the class. I've tried to extract this portion of the client trait into a reproducible script, but that does not trigger the error unfortunately.

Environment details

  • OS: Linux (on Docker)
  • PHP version: 8.3.7
  • Package name and version: google/gax

Steps to reproduce

I cannot reproduce it with a short script, however we occasionally have issues popping up in Sentry about this. I hope this information provides more insights into why this is happening.

Screenshot 2024-09-17 at 09 28 47

pkruithof avatar Sep 17 '24 08:09 pkruithof