this post was submitted on 23 May 2024
266 points (91.6% liked)

Programmer Humor

19480 readers
178 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS
 

...from people who seem to refuse to install paredit or coloring plugins for either? ps lisp syntax ftw, it's a feature!

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 56 points 5 months ago (2 children)

YAML is the Excel of data formats due to the Norway Problem

[–] [email protected] 21 points 5 months ago (3 children)

OK, that's excessively "convenient" for booleans. But I don't get the passionate YAML hate, seems like a simple enough language for config. Didn't have the pleasure ("pleasure"?) to work with it though, so what's why else is it shitty?

[–] [email protected] 31 points 5 months ago (2 children)

A property can have the wrong indentation and it would still be a syntactically correct yaml. It’s hard to distinguish whether a line is wrongly indented or not. Copy and paste a line and mistakenly use the wrong indentation, and the entire production breaks.

In json it’s much harder to do similar mistakes.

[–] [email protected] 2 points 5 months ago

I think TOML found a pleasant compromise there

[–] [email protected] 1 points 5 months ago

It’s hard to distinguish whether a line is wrongly indented or not.

That’s very much not my experience. I use YAML regularly and while I’ve had copy paste indentation errors when I look at the offending line it’s always obvious to me how to fix the indentation. The only indentation thing that’s ever given me trouble is embedding YAML as a string within a file that uses tabs.

[–] [email protected] 27 points 5 months ago

Do a search for 'why yaml is bad' and you'll get a lot of stories.

Constant passing problems, especially when the yaml gets very large and complex. After I implemented a new feature I was pulled into a call with 12-15 people demanding to know why it didn't work. The new feature worked fine, The guys yaml had the wrong amount of white space and so it didn't parse.

[–] [email protected] 19 points 5 months ago

White space in the wrong place? Fails Wrong amount of tabs? Fail

Working in a big configuration file that has a lot of nesting? Good luck.

Best part is that most of these things don't throw errors or anything, it just doesn't work and you are left scratching your head as to why your deploy only fails in the production environment.

[–] [email protected] 1 points 5 months ago

since yaml is just a superset of json, you can easily avoid all problems like this

yaml is like a less strict json for me