Live data from Hacker News

That's a Lot of YAML

noyaml.com

21–30 of 78 posts

Re: That's a Lot of YAML

#21
post #7

Put quotes around your strings an you'll be mostly fine.

It really is that simple.

You really should not blame it on YAML that if you put a random hash value in a field that it may be a number. Like, duh. If you want a string, use quotes.

Re: That's a Lot of YAML

#22
post #11

There is no problem with YAML, just like there was no problem with XML at all. The problem is with the software devs who use it for the wrong thing. I just wonder why JSON doesn't get all the hate, while it is a terrible format also: it is not streamable (YAML is), it doesn't have comments... and non-standard workarounds are used for these features. Norway better than YAML, in my opinion.

There are plenty of problems with YAML as the article shows. The biggest problem with YAML is, that serializer and deserializer need to agree on rules outside of the spec, because otherwise they can be both compliant and still don't understand each other.

isn't this true for most formats? You'd use a string to encode a date or version in JSON just like you would in YAML[0].

Either you have an infinite spec, or you always have things outside it.

[0] YAML would allows you to tag the type, but nobody does it anyway

Re: That's a Lot of YAML

#24

There is no problem with YAML, just like there was no problem with XML at all. The problem is with the software devs who use it for the wrong thing. I just wonder why JSON doesn't get all the hate, while it is a terrible format also: it is not streamable (YAML is), it doesn't have comments... and non-standard workarounds are used for these features. Norway better than YAML, in my opinion.

> Norway better than YAML, in my opinion.

I agree that Norway is better than YAML. Let's keep Norway and dump YAML.

> There is no problem with YAML

I am reminded of: "There are no American infidels in Baghdad. Never!"

Re: That's a Lot of YAML

#25

Earlier quoted context omitted.

EDN? Probably too flexible from some perspectives. No surprise Norways though.

That’s the problem people IMO don’t understand - flexibility is one of many requirements; simplicity and ecosystem around are two more. Hating YAML is same as being childish - yo using like something but can’t come up with anything better. Worse than YAML can be only complaining about YAML. Hating YAML is a cliche. Its much easier to come up with jokes like this website than to change the ecosystem for better. And I…

The modern societies are being infantilized. This is a symptom of that.

Re: That's a Lot of YAML

#26

There is no problem with YAML, just like there was no problem with XML at all. The problem is with the software devs who use it for the wrong thing. I just wonder why JSON doesn't get all the hate, while it is a terrible format also: it is not streamable (YAML is), it doesn't have comments... and non-standard workarounds are used for these features. Norway better than YAML, in my opinion.

YAML is (or at least, is declared by its maintainers to be) a superset of JSON, making any JSON document also a valid YAML document.

So surely if YAML is streamable, JSON must be too?

Or are the YAML maintainers incorrect?

Re: That's a Lot of YAML

#29

There is no problem with YAML, just like there was no problem with XML at all. The problem is with the software devs who use it for the wrong thing. I just wonder why JSON doesn't get all the hate, while it is a terrible format also: it is not streamable (YAML is), it doesn't have comments... and non-standard workarounds are used for these features. Norway better than YAML, in my opinion.

I find json annoying to write a lot of the time, but I do enjoy that it's a lot more difficult to get wrong than yaml. The json spec is pretty clear, and can be learned and memorized by any programmer in 5 minutes. I'd much rather write in a format that's slightly annoying than a format that's slightly ambiguous.

Re: That's a Lot of YAML

#30

There is no problem with YAML, just like there was no problem with XML at all. The problem is with the software devs who use it for the wrong thing. I just wonder why JSON doesn't get all the hate, while it is a terrible format also: it is not streamable (YAML is), it doesn't have comments... and non-standard workarounds are used for these features. Norway better than YAML, in my opinion.

There numerous problems with YAML. It is underdefined, ambiguous, fragile, and is just impossible to write a portable parser for.

JSON is naive, lacks almost everything. But is supereasy to parse and read.

As funny as it sounds, XML is overspecified. Parsing is possible and predictable but supporting the full standard (all of them) is so much work that nobody does it anyway.

So, given the choice above, i'd go for naive simplicity.

Post reply on HN