r/ProgrammerHumor 14h ago

Meme bugFreeAppMeetsUncheckedUnicodeChaos

Post image
1.4k Upvotes

38 comments sorted by

95

u/SeraphOfTheStart 14h ago

Claude told me it was my turn to repost this

22

u/AgVargr 13h ago

Can we spin up an agentic workflow to repost this every day?

4

u/the_poope 13h ago

OP is already such a bot. This has existed for 5+ yours and accounts for 80% of the posts on all meme subreddits.

-3

u/[deleted] 11h ago

[deleted]

0

u/the_poope 11h ago

You should reply with: "No fellow human, I certainly created this meme myself. Beep boop"

-2

u/mr_nonameuser 13h ago

Would you burn your tokens just to get karma on reddit? Seriously?

3

u/SuitableDragonfly 13h ago

Is it my turn to say "if your app can't handle unicode it's not perfectly coded", or is it someone else's turn now?

43

u/LostInSpaceTime2002 12h ago

No proper input sanitation, and you call it "perfectly coded"? What does that even mean?

9

u/The_Illegal_Guy 11h ago

It means I asked Claude to code it and I wrote "make no mistakes"

2

u/Adventurous-Map7959 10h ago

You also need to instruct "You are a master programmer" so it doesn't use the "amateur programmer" preset.

4

u/pi_three 11h ago

also no test case with random unicode characters

1

u/wizkidweb 11h ago

This exact thing happened to me, and we were sanitizing our input. In our case, the database system was using an older version of Unicode, so we had to validate against that explicitly.

6

u/FelisCantabrigiensis 14h ago

That was JIRA, until a few years ago.

17

u/DT-Sodium 13h ago

Apparently you didn't have 100% test coverage.

21

u/MartinMystikJonas 13h ago

100% tests coverage means 100% of code is covered by tests it does not me you covered 100% of all possible inputs

2

u/Murky-Run2246 12h ago

Yeah, 💯 test coverage is like the safety check you run  after editing the code to make sure your changes did not break something somewhere.

Does not mean your code is tested for all possible scenarios though.

1

u/breZZer 8h ago

that's mostly unit testing

1

u/breZZer 8h ago

nope, that's code coverage.

1

u/DT-Sodium 11h ago

In this case, either it causes an encoding issue of some kind and crashes your app, in which case your code is not tested properly, or the result will simply be that the username will display an emoji, which isn't a bug per say.

1

u/MartinMystikJonas 11h ago

This is usally problem on database layer that uses utf8mb3 that does not support emoji characters. Your app works and all code is 100% covered and tested. But it still crashes in prod because DB uses utf8mb3 not utf8mb4 (dont ask how I know 😁). But you cannot test all posible inputs and run environments because there is infinite posibilites.

2

u/DT-Sodium 10h ago

Bro my database system doesn't even support the € symbol, don't talk to me about utf8mb3. Anyway, your dev environment, pre-production and deploy environment should be using the exact same database system.

1

u/MartinMystikJonas 10h ago

Yeah should 😁

3

u/Professional_Top8485 12h ago

USA: we don't need stinky non-ascii characters here.

3

u/Lower-Bodybuilder-16 11h ago

They can accept only those rules good for their business. If not they create their own rule. Like tomato 🍅 is a vegetable by business. Scientifically it's a fruit.

4

u/Loading_M_ 10h ago

"Vegetable" is a social construct. There isn't a biological definition of term vegetable. Every vegetable actually falls into one of several different biological categories, like leafs, roots, stalks, etc. Tomatoes are classified biologically as a fruit. However, since vegetable isn't a biological classification, a tomato can also be considered a vegetable at the same time.

2

u/white_sheets_angel 11h ago

Regex comes to save you: \w

2

u/backstubb 11h ago

"100% test coverage"

2

u/PrestigiousGuava8005 11h ago

The database really said 'I can survive anything' and then met someone named 👁️👄👁️

3

u/The_Real_Black 5h ago

The moment I learned Window and point opend the emoji menu
User: 🍣
Password: 🍣💣❄️🔥🥓🍔💥🤡
Item 🍕
Variants 🔥❄️
Info 🪵🪵🪵🪵🪵🪵

5 minutes later a scream in the office, why is the test database so colorfull?
We know now, the PDF printer is old and a API really disliked it also...
got 5 new tickets that day. :-P
the user still works

2

u/DarkYaeus 13h ago

Wait until someone uses turkish locale on their computer

3

u/Various_Squash722 12h ago

Just use Cyrillic or Greek letters that look identical to Roman letters, but have a different Unicode ID.

2

u/DarkYaeus 12h ago

I am not sure what you are referring to outside of the use of unicode letters. I was talking about how people in Turkish locale would have the toLowerCase() function turn I into a letter that is not i.

1

u/insolent_kiwi 13h ago

Some devices won't work when you put emoji in the wifi name

1

u/Bomaruto 8h ago

Where we don't want emojis we block it and where we don't care we don't block it. Doesn't cause any issues at all.

1

u/JackNotOLantern 5h ago

Not perfectly coded nor 100% (branch) covered with test then

1

u/wildrabbit12 11h ago

I hate this subreddit

1

u/Terewawa 11h ago

I have seen this post before, it's a duplicate. I wouldn't go that far, though.