News for hackers. Stuff that matters.
Re:The 5 Stages of YAML by ben509 on Monday August 20, 2018 @06:03PM (#17804417)
I got somewhere between stage 2 and 3 and had to try reading the YAML spec and figuring out the YAML libraries.

It's a mess... it has enough "features" it's a security hole, and you wind up porting a parser / serializer to every platform you want to use it on.

Re:The 5 Stages of YAML by jolmg on Monday August 20, 2018 @06:11PM (#17804481)
> 5. The declarative YAML format now supports conditional, iteration, and inheritance syntax; it is now turing complete.

* glance at Ansible

Re:The 5 Stages of YAML by trelliscoded on Tuesday August 21, 2018 @12:50AM (#17807092)
Overheard: “this thing has more translation steps than C??”
Re:The 5 Stages of YAML by ris on Monday August 20, 2018 @05:59PM (#17804389)
There is nothing simple about yaml. Only things that seem simple from a first glance.
Re:The 5 Stages of YAML by aijoe on Tuesday August 21, 2018 @08:57AM (#17809118)
Isn't this just a matter of, "Recognize when you're using config for something dynamic and refactor because config is no longer the best tool for that job"? And you can continue using yaml (or whatever config format you're using) wherever config remains the right tool for the job.
Re:The 5 Stages of YAML by dpc_pw on Monday August 20, 2018 @10:12PM (#17806294)
This isn't a critique of YAML itself (which , only of people using YAML for things, where they should have started with Lua/Python/Scheme.

Someone already mentioned Ansible. I find it particularly terrible. And bunch of other half-assed DSLs, terrible templating languages and such.

Re:The 5 Stages of YAML by sytelus on Wednesday August 22, 2018 @12:32AM (#17816319)
5th point could have read: There was no way to put breakpoints in this declarative stuff and debug things so now we just use JavaScript.
Re:The 5 Stages of YAML by paulddraper on Monday August 20, 2018 @06:12PM (#17804489)
For something in between 4 and 5 for JSON, see https://jsonnet.org/
Re:The 5 Stages of YAML by BugsJustFindMe on Monday August 20, 2018 @10:12PM (#17806296)
That's kinda funny. Once you add comments and function calls to JSON, you've basically just made a Python module.
Re:The 5 Stages of YAML by beaconstudios on Tuesday August 21, 2018 @05:29AM (#17808224)
at that point you might as well just require() a js file instead of skirting around the issue of code vs config.
Re:The 5 Stages of YAML by paulddraper on Tuesday August 21, 2018 @03:05PM (#17812715)
It is Turning complete, but also pure (side-effect free).
Re:The 5 Stages of YAML by beaconstudios on Tuesday August 21, 2018 @03:51PM (#17813075)
You don't need a whole new language to have that though, just don't put side effects in your config.js
Re:The 5 Stages of YAML by blt on Tuesday August 21, 2018 @02:29AM (#17807484)
...and yet people give me a hard time for using python dict/array literals for config.
Re:The 5 Stages of YAML by jasonpeacock on Tuesday August 21, 2018 @09:39AM (#17809424)
Checkout TOML for a standard config that does just that.
Re:The 5 Stages of YAML by PopeDotNinja on Monday August 20, 2018 @08:21PM (#17805558)
I'm currently stuck in stage 4.

shakes first at Kubernetes wrapper wrapper wrapper wrapper