google-auth-library-ruby icon indicating copy to clipboard operation
google-auth-library-ruby copied to clipboard

Missing access token. (ArgumentError) #243

Open ar-abdurrehman opened this issue 1 year ago • 4 comments

Environment details

  • Ruby version: 3.1.3
  • Rails version: 7.0.4

I use multiple Google services, such as Translate, speech-to-text, and text-to-speech. They were working fine before, but recently, I have been encountering missing access token errors on my Dockerize Development environment, though it is working fine locally.

signet-0.19.0/lib/signet/oauth_2/client.rb:1117:in `generate_authenticated_request': Missing access token. (ArgumentError)

ar-abdurrehman avatar Dec 11 '24 08:12 ar-abdurrehman

Can you provide a bit more information:

  • Operating system and version and system architecture you're running (e.g. macos 15.1, linux-amd64, Alpine 3.20.3, etc.)
  • Versions of the google api client gems (such as google-cloud-translate, etc.) you are using
  • Versions of the googleauth and signet gems. (It looks like from the data you gave already that you're using signet 0.19.0, but the googleauth version is also important.)
  • Full stack trace of the errors you are seeing
  • What kind of credentials you're using (e.g. exported service account key, default credentials on Cloud Run, credentials federated from AWS, etc.) and how you're specifying them (e.g. environment variable, setting a configuration on a client object, etc.)

dazuma avatar Dec 11 '24 19:12 dazuma

We have a possible (possibly partial) fix, if you update your google-cloud-translate-v2 gem to version 1.0.1. Let me know if that helps.

dazuma avatar Dec 12 '24 21:12 dazuma

We have a similar issue with Bigquery...

See https://github.com/googleapis/google-auth-library-ruby/pull/490/files#r1890853813

Linuus avatar Dec 20 '24 10:12 Linuus

We have a possible (possibly partial) fix, if you update your google-cloud-translate-v2 gem to version 1.0.1. Let me know if that helps.

For now, I set the dependency googleauth to version 1.11.1', which fixed the issue for me.

ar-abdurrehman avatar Dec 21 '24 12:12 ar-abdurrehman