GoBooDo
GoBooDo copied to clipboard
Problems with connecting
When trying to fetch a book, I am persistently getting this error:
"name='NID', domain=None, path=None" Received invalid response
Can anyone help?
Same here
Maybe the cause is that the cookie from https://google.{country} does not have key NID
.
However, I have no idea why. GoBooDo works in my environment.
Please try other countries.
I wrote short test program. In my environment, this work (KeyError does not occurs).
NOTE: This program should be run in the same directory as settings.json
.
#!/usr/bin/env python3
# This program is in the public domain and no warranty.
import json
import requests
with open('settings.json') as ofile:
country = json.load(ofile)['country']
print(country)
req = requests.get("https://google."+country,verify=False)
print(req.cookies['NID'])
Commenting out line 58 of GoBooDo.py
might be workaround, but it's not safe.
- 'Cookie': "NID=" + str(req.cookies['NID']),
+ #'Cookie': "NID=" + str(req.cookies['NID']),
#63 in reset_head(self)
req = requests.get("https://google."+self.country, cookies={'CONSENT': 'YES+1'}, verify=False)