scratchclient
scratchclient copied to clipboard
KeyError: 'set-cookie' [bug]
This is an error I get on a fresh install and the only code is the login code. This is running on replit.
self.login(password)
File "/home/runner/scratchbot/venv/lib/python3.8/site-packages/scratchclient/ScratchSession.py", line 66, in login
self.session_id = re.search('"(.*)"', request.headers["Set-Cookie"]).group()
File "/home/runner/scratchbot/venv/lib/python3.8/site-packages/requests/structures.py", line 52, in __getitem__
return self._store[key.lower()][1]
KeyError: 'set-cookie'```
I saw the replit thing... but I still get this error:
File "/home/runner/scratchbot/venv/lib/python3.8/site-packages/scratchclient/ScratchSession.py", line 34, in __init__
self.get_csrf_token()
File "/home/runner/scratchbot/venv/lib/python3.8/site-packages/scratchclient/ScratchSession.py", line 83, in get_csrf_token
"scratchcsrftoken=(.*?);", request.headers["Set-Cookie"]
File "/home/runner/scratchbot/venv/lib/python3.8/site-packages/requests/structures.py", line 52, in __getitem__
return self._store[key.lower()][1]
KeyError: 'set-cookie'
This happens when your login credentials are incorrect.
Minus the part where the credentials are correct.
on replit scratch auth has broken use cookie auth, without username and pass
I saw that post. I tried using the cookie, and it didn't work. Sooooo
Hi, I am having the same issue, this is getting pretty bad
It's probably not going to be fixed soon as this repo is no longer updated. I could be wrong, but right now I have no time to update it.