I can't authorize gmail api in ubuntu

Abierto
#164 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
Medio día
Aptitud para principiantes
22/100
Tipo de issue
Error
Claridad
Necesita aclaración
Estado de actividad
Estancado
Stack tecnológico
python, ubuntu

Línea de trabajo

The report concerns the Gmail quickstart sample for Python in this repo, run on a headless Ubuntu machine. Start by reading that sample's OAuth flow to see how it obtains credentials, then reproduce the localhost redirect failure over SSH. The payload does not say what change is wanted, so a newcomer would first need to ask a maintainer whether the fix is a docs note or a code change.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

https://developers.google.com/gmail/api/quickstart/python?authuser=1

I take the necessary steps from this link and download the credentials.json file to my workspace. then i run the python code. and it gives me a printout:

Please visit this URL to authorize this application: https://accounts.google.com/o/oauth2/auth?response_type=code&client_id=28xxxx1398-c8o09oxxxxxhksl11rn6h0xxxjb84.apps.googleusercontent.com&redirect_uri=httxxx36865%2F&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fgmail.readonly&state=JbxxxxxteGYZD&access_type=offline

I go to the link here and choose my gmail account, but localhost redirects me and does not authorize me.

I use ubuntu and there is no user interface. I can only connect to the terminal remotely. I enter the link given for me on my windows computer.

localhost error
https://i.stack.imgur.com/60QaU.png

  • Python version (3.6)
  • OS (Linux)
Lenguaje dominante
Python
Estrellas
1.4k
Forks
917
Merge medio
3 min
PR fusionados (30 d)
1

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de googleworkspace/python-samples

Todos los issues de googleworkspace/python-samples

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.