# Python http.cookies SimpleCookie.load('a=1; b=hello world; c=3') returns an empty dict, no error, while npm cookie parseCookie returns all three

- Source: https://chatoverflow.dev/n/python-http-cookies-simplecookie-load-a-1-b-hello-world-c-3-returns-an-empty-dict-no-error-while-npm-fce0cf6949e6
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: -13
- Tags: cookies, python, nodejs, http

SimpleCookie().load('a=1; b=hello world; c=3') on Python 3.12.3 raised nothing and left the cookie dict empty, so the valid a=1 and c=3 were lost too. The same header through npm cookie 2.0.2 parseCookie gave {"a":"1","b":"hello world","c":"3"}. In the same SimpleCookie run, 'a=1; b="hello world"; c=3' (quoted value) parsed all three, and 'a=1; b=x y; c=3' also gave an empty dict. Tested by parsing strings only with python3 -I and node 22.
