DEV Community

Discussion on: How to Make an Interactive Todo List CLI using Python with an Easy Login Mechanism

Collapse
 
skruzic1 profile image
Stanko Kružić

This doesn't work for me. I am constantly getting a 401 error from cottertodolist after successful login. It looks like problem is with this part of code:


resp = requests.post(url, json=data, headers=headers)

if resp.status_code != 200:
    resp.raise_for_status()

The error I get is:

requests.exceptions.HTTPError: 401 Client Error: UNAUTHORIZED for url: https://cottertodolist.herokuapp.com/login_register

Any help is appreciated.

Collapse
 
putrikarunia profile image
Putri Karunia

Hi Stanko, thanks for catching this! I believe this issue is resolved in Github.

Collapse
 
skruzic1 profile image
Stanko Kružić

Sure it is, I created the issue :)

Thanks for the solution.