question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cookies not set when dont_merge_cookies is True

See original GitHub issue

This example is straight from the documentation, and does not work because if dont_merge_cookies is set on the request, then the cookie middleware skips all cookie processing and no cookies are ever set.

Request(url="http://www.example.com",
        cookies={'currency': 'USD', 'country': 'UY'},
        meta={'dont_merge_cookies': True})

Does not work, however, this does:

Request(url="http://www.example.com",
        cookies={'currency': 'USD', 'country': 'UY'})

Issue Analytics

  • State:open
  • Created 7 years ago
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Hardeepsingh980commented, Apr 18, 2020

Is it fix. I am having the same issue. If if pass dont_merge_cookies = True than then these cookies are send : - Cookie: JSESSIONID=91F0E399DC07C621F3D29780E67813CB; cookiesession1=2A5CC2143KP0OE23AJ1U442TNWKP4C0D; cookiesession1=2A5CC214CDUPRVWBMDZ0WE63VVMIBC2C

cookiesession1 is being sent two times. If i pass dont_merge_cookies = False than no cookies are sent at all.

Please help me out. I am stuck with this from 2 days.

Thanks is advance.

1reaction
bb9696aacommented, Aug 15, 2019

@Ferrer-Jeremy It works. Thanks a lot. @Gallaecio This bug has not been fixed yet.

Read more comments on GitHub >

github_iconTop Results From Across the Web

php - Why are my cookies not setting? - Stack Overflow
So if you set a cookie without setting path at a.com/b/setcookie.php the cookie ... desired execution point has been reached & a valid...
Read more >
7 Keys to the Mystery of a Missing Cookie
7 Keys to the Mystery of a Missing Cookie · 1. SameSite attribute Defaults to Lax · 2. withCredentials is not Set to...
Read more >
Set-Cookie - HTTP - MDN Web Docs
The Set-Cookie HTTP response header is used to send a cookie from the server ... to the client the cookie is being set...
Read more >
Turn cookies on or off - Computer - Google Account Help
On your computer, open Chrome. At the top right, click More More and then Settings. Under "Privacy and security," click Site settings. Click...
Read more >
HttpOnly - OWASP Foundation
<session-config> <cookie-config> <http-only>true</http-only> ... If the HttpOnly flag is set, then your browser should not allow a client-side script to ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found