Re:Show HN: HTTPLang – a scripting language for making HTTP ...
by daenney on Monday May 25, 2015 @08:08AM
(#9599707)
Besides that, I feel like I'm writing plain HTTP, which is something I really don't want to do or have to think about.
Re:Show HN: HTTPLang – a scripting language for making HTTP ...
by harel on Monday May 25, 2015 @07:13AM
(#9599523)
Not to mention curl is also already very simple.
> I find the process to be stupidly complicated, and handling cookies is a nightmare.
However this is about as straightforward as it can get with Requests. This is the HTTPLang example:
Here is the equivalent in Python using Requests: Where's the stupidly complicated nightmare?The only complicated things I see above are in the HTTPLang version: a variable called "URL" that isn't actually the URL that is being requested, and I guessed at how the cookie functionality worked because it's not at all obvious – I'm assuming that `set COOKIE $TMPCOOKIE` gets the cookie from the previous request and sets it for the subsequent requests.