![](/static/e3814064/assets/icons/icon-96x96.png)
![](https://lemmy.world/pictrs/image/eba14d9b-c90b-44ff-aafb-95d5ed4f4eba.jpeg)
He has found the precious… Braincell
He has found the precious… Braincell
As if I had a choice. Most of the time I’m only on the receiving end, not the sending end. I can’t just magically use something else when that something else doesn’t exist.
Heck, even when I’m on the sending end, I’d use JSON. Just not bullshit ones. It’s not complicated to only have static types, or having discriminant fields
The schema is this SQL statement
If a item can have different type, those label fields are actually quite useful. So I don’t see the problem
You guys have docs?
Sadly it doesn’t fix the bad documentation problem. I often don’t care that a field is special and either give a string or number. This is fine.
What is not fine, and which should sentence you to eternal punishment, is to not clearly document it.
Don’t you love when you publish a crate, have tested it on thousands of returned objects, only for the first issue be “field is sometimes null/other type?”. You really start questioning everything about the API, and sometimes you’d rather parse it as serde::Value
and call it a day.
To whoever does that, I hope that there is a special place in hell where they force you to do type safe API bindings for a JSON API, and every time you use the wrong type for a value, they cave your skull in.
Sincerely, a frustrated Rust dev
I would do that… If CI wouldn’t be set to -D warnings
Who even does that? Oh wait, it was me.
Joke aside, it does help to keep the code clean, even more for open source projects where multiple separate people may all have their own codding style, and it helps make it easier to organise.
But I do agree that it can be really, really annoying.
Idk about the article but the image is nice
My attempt to explain was squashed by this comment
It’s the second time I see it on a programmer humor community. I get you want to advertise, but we already told you that this isn’t the place for that
I do push often as I’m often switching between two devices. And I do make draft PR so I got an easy git diff that I can live reference with
Virgin toddler squasher Vs chad adult compressor
I often do the same for my memes. I like them high quality
NGL I 'm a bit like that. I often do “work” commits so that my working tree is a bit more clean/I can go from working state to working state easily.
But before a PR, I always squash it, and most times it’s just a single commit
Also, looking at the road, it doesn’t seems to be that bad. It ain’t central France bad
It’s an option!? I get severely motion sick in cars and I’d love those easier roads
Or as would Dearrow put it: “Explaining the Effects and Treatment of M. Tuberculosis”
Or as I would put it: “Big space cum monster is a threat to earth”
I think I get it but explain nonetheless?
This was a really funny scroll up. Thanks op