eddie3 / gogrepo

Python-based tool for downloading all your GOG.com game and bonus collections to your local computer for full offline enjoyment.
481 stars 114 forks source link

ValueError: unknown url type: undefined #36

Closed albert2742 closed 5 years ago

albert2742 commented 5 years ago

12:05:05 | attempting gog login as 'REDACTED@EMAIL.COM' ... 12:05:05 | fatal... Traceback (most recent call last): File "D:\GOG Downloads\gogrepo.py", line 1121, in main(process_argv(sys.argv)) File "D:\GOG Downloads\gogrepo.py", line 1093, in main cmd_login(args.username, args.password) File "D:\GOG Downloads\gogrepo.py", line 550, in cmd_login with request(login_data['auth_url'], delay=0) as page: File "D:\GOG Downloads\gogrepo.py", line 170, in request page = opener.open(req) File "C:\Program Files (x86)\Python\lib\urllib2.py", line 421, in open protocol = req.get_type() File "C:\Program Files (x86)\Python\lib\urllib2.py", line 283, in get_type raise ValueError, "unknown url type: %s" % self.__original

oriwheb commented 5 years ago

This is a known and solved issue. You can solve this yourself by changing the line "login_data['auth_url'] = elm.text.split("'")[1]" to "login_data['auth_url'] = elm.text.split("'")[3]"

Eddie can fix this on his own (heck, it's just one number), but I'll put a pull request anyway.