in reply to HTTP::Cookies -> CookieJar

The use of HTTP::CookieJar is recommended over HTTP::Cookies

Recommended by whom? Each of those modules has its own pros and cons and it is up to the user (coder) to choose between them given any particular scenario. They each have roughly 6,400 total dependents (according to MetaCPAN) so it isn't like one or other is dominating the scene.

If you want to use HTTP::Tiny for whatever reason then you have to put up with the consequences of that choice such as the manual translation between formats which you have shown. Hopefully it isn't too brittle.


🦛

Replies are listed 'Best First'.
Re^2: HTTP::Cookies -> CookieJar
by Anonymous Monk on Mar 31, 2025 at 14:33 UTC

      Something that got me confused here is this: you're concerned about recommendations from LWP::UserAgent docs when instead you picked HTTP::Tiny for the task. But anyway, HTTP::Tiny also mentions this:

      Cookie support requires HTTP::CookieJar or an equivalent class.

      return on_success() or die;