TypeError: GoogleAuth.LocalWebserverAuth() missing 1 required positional argument: 'self'

lungsang

I am trying to authenticate google api and after following all the necessary steps like making credentials and installing pydrive, I am faced with this error when running the main.py module TypeError: GoogleAuth.LocalWebserverAuth() missing 1 required positional argument: 'self' Do you guys have any idea how to fix it. thank you in advance :)

main.py code

from pydrive.drive import GoogleDrive

gauth = GoogleAuth
gauth.LocalWebserverAuth()
drive = GoogleDrive(gauth)
DaImTo

The Python "TypeError: missing 1 required positional argument: 'self'" occurs if you call a method on the class instead of on an instance of the class.

You are missing from pydrive.auth import GoogleAuth

pydrive

from pydrive.auth import GoogleAuth
from pydrive.drive import GoogleDrive

gauth = GoogleAuth()
gauth.LocalWebserverAuth()
drive = GoogleDrive(gauth)

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

TypeError: Missing 1 required positional argument: 'self'

How to Solve this " TypeError: read() missing 1 required positional argument: 'self' "

TypeError: gassens() missing 1 required positional argument: 'self'

TypeError: save() missing 1 required positional argument: 'self' : DjangoRestframework

TypeError at / save() missing 1 required positional argument: 'self'

TypeError: open_file() missing 1 required positional argument: 'self'

TypeError: get_params() missing 1 required positional argument: 'self'

TypeError: Function() missing 1 required positional argument: 'self'

TypeError: save() missing 1 required positional argument: 'self'

TypeError: GetSize() missing 1 required positional argument: 'self'

TypeError: endturn() missing 1 required positional argument: 'self'

Python - TypeError: listen() missing 1 required positional argument: 'self'

TypeError : kollision() missing 1 required positional argument: 'self'

TypeError: close() missing 1 required positional argument: 'self'

TypeError: player_attack() missing 1 required positional argument: 'self'

TypeError: str() missing 1 required positional argument: 'self'

TypeError: grid_configure() missing 1 required positional argument: 'self'

TypeError: main() missing 1 required positional argument: 'self'

TypeError: check() missing 1 required positional argument: 'self'

Getting TypeError fit() missing 1 required positional argument: 'self'

TypeError at /listing: save() missing 1 required positional argument: 'self'

TypeError: draw_shape() missing 1 required positional argument: 'self'

Missing 1 required positional argument: 'self' missing

save() missing 1 required positional argument 'self'

python: missing 1 required positional argument: 'self'

fit() missing 1 required positional argument: 'self'

main() missing 1 required positional argument: 'self'

missing 1 required positional argument: 'self' in class

missing 1 required positional argument: 'self' in odoo?