Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "utf8"
-
When we found out MySQL utf8 isn't actually utf8..... it's a proprietary subset of utf8 that only includes up to Unicode 255..... and there is a separate "utf8mtb4" that is actual utf8.8
-
So apparently using utf8 with LaTeX isn't enough to get € symbol working, I have to include two more packages for that (two, because one handles the character, and the other one makes it look "not weird"). How hard can it be to just use a single utf8 font, and have it work with whatever utf8 character you type in? And apparently there are at least 3 packages specifically for euro symbol - a certain XKCD comic comes to mind...11
-
Wow, what a fucking mess this sunday was.
My boss wrote me an email that one route of a RESTful API we wrote for a customer was not working anymore and puking back a status 500 with some error mentioning invalid UTF-8 characters.
Not one single person has had touched nor changed the code on production in some 6 months, so what the fuck could it be?
Phpunit did not give any errors (running only locally), the code had no syntax errors and the DB dump did not contain any invalid bytes (tested with a hex editor).
WHAT THE FUCK?!
OK so I started to comment out lines (all tested directly on production of course) until the error vanished.
Guess what was the culprit?
.
.
.
.
.
.
In the code (PHP) we used strftime(...) to get nice time strings. Of course we set the correct locale on the server, thus having months and days formatted in German.
So, in Geman there is this one mysterious month called "März" which contains an umlaut character.
Calling strftime generated the date with März in it, but the server locale was de_CH.iso-8859-1 and not fucking de_CH.utf8, so the "ä" was returned as 0xE4 instead of 0xC3A4 (valid UTF-8), which json_encode(...) did not want to swallow but instead threw an exception.8 -
So many developer that does not know how to generate a simple .csr file. Here you go:
$DOMAIN=www.yourdomain.com
$STATE=State
$CITY=The city
$COMPANY=Company Name Gmbh
openssl req -utf8 -nameopt multiline,utf8 -new -newkey rsa:2048 -nodes -sha256 -out $DOMAIN.csr -keyout $DOMAIN.key -subj "/C=Your CountryCode/ST=$STATE/L=$CITY/O=${ORG:-$COMPANY}/OU=${ORG:-IT}/CN=$DOMAIN"11 -
I actually never had to deal with that so far and wondered too.
https://stackoverflow.com/questions...6 -
Yesterday, after six months of work, a small side project ran to completion, a search engine written in django.
It's a thing of beauty, which took many trials, including discovering utf8 in mysql isn't the full utf8 spec, dealing with files that have wrong date metadata, or even none at all, a new it backup policy that stores backups along side real data.
Nevertheless, it is a pretty complete product. Beaming with pride I began to get myself a drink, and collapsed onto the floor, this caused me to accidentally hibernate my computer, which interrupted the network connection, which in turn caused an OSError exception in one of my threads, which caused a critical part of code not to run, which left a thread suspended, doing nothing.
From the floor I looked at my error and realised my hubris and meditated on my assumptions that in theory nothing should interrupt a specific block of code, but in reality something might, like someone falling over...7 -
Fuck mysql charset shit. Pretty easy to forgot setting charset in server side config file. And after creating several databases/tables, boom! All in latin1. That's just so convenient. are you kidding me? Why would any modern database have their default charset to be latin1??? rather than utf8? Oh, just forgot again, that's utf8fuckingmb4 on mysql land.6
-
Forget stress balls!
Relieve your stress with this giant enter button!
Punch it like you mean it.
Tell your boss off with every punch of the enter button!
Smash those bugs with the might of Zues!
Cause a lotta damage!
https://amazon.com/Hongxin-Novelty-...10 -
// Rant
I can understand that people accidentally commit something sensitive to GitHub, I did it too once, but ...
WHY THE FUCK DO YOU MAKE YOUR MISTAKE WORSE BY MAKING IT SEARCHABLE VIA THE GLORIOUS COMMIT MESSAGE OF "REMOVING PASSWORD"
... seriously just google "git remove password" and there is a step by step guides on how to remove sensitive data from git.
Reference (320,006 free passwords):
https://github.com/search/...9 -
Screw MySQL/MariaDB. Who the fuck thought not to document that utf8 is only 3 bytes and not unicode capable. You have to use utf8mb4 for it to work. Fuck those idiots that don't want to admit they made a mistake and put this info in a footnote on a pricy documentation piece.7
-
Yesterday a strange bug appeared in Chrome: In a small web app we have some umlaut characters like äöü. Strangely said characters were displayed as cyrillic, but only on my pc... On every other device it worked. I spent about 5 hours of checking encodings (everything was in UTF-8), reading posts in the almighty stackoverflow.
Finally i figured out, the font was broken. After reinstalling it, everything was peaceful again in my head. -
I was working on this mustachio fork called Morestachio and changed the Default Encoding from "Encoding.Default" to UTF8 while creating a .NetStandard version of it. After i have created everything i thought "Hey just for the lolz run my tests again" ...2
-
For fucks sake! It's 2018 and MS™ Excel™ is still not able to store a file in UTF-8...
And neither can you choose the separators when opening a CSV.
Go eat a bag of corporate dicks and greedily choke on it to an agonizing death.5 -
Just completed developing my first Amazon Alexa skill. Please try it out on your Alexa device and give reviews on how I can improve this skill.
This skill uses Apertium, a free and open-source rule-based machine translation platform to provide translations for exotic and divergent languages.
The link to the skill: https://amazon.com/Techievena-Smart...
Here is an article to demonstrate the use of the skill.
https://linkedin.com/pulse/...7 -
So I enventually spent 2 years working for that company with a strong b2b market. Everything from the checkouts in their 6 b2c stores to the softwares used by the 30-people sales team was dependant on the main ERP shit home-built with this monstruosity we call Windev here in France. If you don't know it just google and have some laugh : this is a proprieteray FRENCH language. Not french like made by french people, well that too, but mostly french like the fucking language is un fucking french ! Instructions are on french, everything. Hey that's my natural language okay, but for code, really ?
The php website was using the ERP database too, even all the software/hardware of the massive logistic installation they had (like a tiny Amazon depot), and of course the emails of all employees. Everything was just handled by this unique shitty and so sloooooow fucking app. When there was to many clients on the website or even too many salespeople connected to the ERP at the same time, every-fuckin-piece of the company was slowing down, and even worse facing critical bugs. So they installed a monitor in the corner of a desk constantly showing the live report page of Google analytics and they started panic attacks everytime it was counting more than 30 sessions on the website. That was at the time fun and sad to observe.
The whole shit was created 12 years ago and is since maintened locally by one unique old-fashion-microsoft dev who also have to maintain all the hardware of all the fucking 150+ people business. You know, when the keyboard of anyone is "broken" cause it's unplugged... That's his job too. The poor guy was totally overstressed on a daily basis and his tech knowledge just saddly losts themeselves somewhere in the way. He was my n+1 in a tech team of 3 people : him, a young and inexperimented so-called "php developer" who was in charge of the website (btw full of security holes I discovered and dealed with when I first arrive at the job), and myself.
The database was a hell of 100+ tables of business and marketing data with a ton of specific logic added on-the-go during years. No consistent data model or naming. No utf8. Fucked up relations that ends with queries long enough to fill books. And that's not all, all the customers passwords was just stored there uncrypted. Several very big companies and administrations were some of these clients. I was insisting on the passwords point litterally all the time, that was an easy security fix and a good start... But no, in two years of discussions on the subject I never achieved to have them focusing on other considerations than "our customers like that we can remind them their password by a simple phone call if they lost it". What. The. Fuck. WHATTHEFUCK!
Eventually I ran myself out of this nightmare. I had a few bad jobs already, and worked on shitty software already. But that one really blows my mind (and motivation for a time too). Happy it's over.1 -
This morning I woke up because some light from the hallway was comming from under my door. I went on investigation. Was a bit scared. But it was just Kiki sitting there solving a rubiks cube while speaking UTF-8 to herself. I went back to bed6
-
Whenever I want to type the shrug emoji, I copy it from a Google note ¯\_(ツ)_/¯
I can type emojis just fine, enjoy a 🍓, yet there is a clear lack of accessibility for ASCII-emojis input on any device.
How is this fair!?
PS: I do know that this shrug is actually utf8 and not ascii. But that's beside the point. Also try saying “utf8 emoji” three time in a row.8 -
Todays rant is about me trying to add some long text into my database. I tried it all day long, but the text was inserted partially all the time. I changed the collumns data type to BLOB, this felt false, but it seemed to work. The bad feeling triggered me to search further, so I rewrote my code and found the source of this behavior. I used utf8-decode-function on my text and that triggered some problems when inserting the text. I don't completely understand it, but I solved the mystery, that fucked up the day. I will sleep good now.
-
Problem saving emojis to your database? MySQL’s utf8 only allows you to store 5.88% of all possible Unicode code points. https://mathiasbynens.be/notes/...2
-
How it started:
Need to replace in a lot of SQL files certain stuff...
find . -type f -iname '*.sql' -exec sed -i 's|new|old|g' {} \;
12 hours later that find executed a shell script containing roughly 120 lines of text pipelining.
The jolly of inconsistent workflows.
Different SQL format stylings... Makes fun when single line string replace needs to be extended to multiline RegEx handling. Or matching SQL comment configuration..
Different line endings. MacOS, Windows, Unix, Bukkake.
Different charsets / collations. Anyone wants latin1_swedish_ci... utf8... utf16... :/
Realizing some people even left sensitive data inside the SQL files (e.g. API Tokens..... Yayyyyyyy).
...
Ugh. It's never a one liner. It's never easy. -.-
I hate cleaning up messy shit.3 -
iOS is rotting my soul.
I've been a user of iPhone for 6 years now. For the first couple years, I wasnt really mindful of software I use, or I guess I didnt really care. As long as it did the bare minimum, I.e. bank app, call, text, browse, watch youtube vids, I didnt really care. However, in the last couple years, ive become very interested in tech and have worked on small developer projects, spent a lot of time coding in my free time, found really inspiring software and apps on my regular computer that just blow my mind on how advanced they are, and how I, some dumb guy with internet access, can just download it on my PC and use it.
This led me into a kind of software honeymoon phase, where I created a shiny new Github account and started exploring what other cool tools are just out there, available to me for free. My software honeymoon was spent on the beaches and resorts of the open-source software ecosystem. Exploring the gem-bearing caves and beautiful forests of anything from free open-source OCR programs(I needed it to convert my dads manuscript from scanned PDF .jpeg's to actual UTF8 text) to open-source RGB lighting/keymapping software to escape the memory-and-CPU-hungry(and most likely advertising-ID-interested) proprietary software that comes with the brand of mouse/keyboard/controller/etc.
It was like I was a kid exploring Disneyland for the first time or something. But then... then... I got off my computer. Picked up my phone to check notifications. Ew, tinder is blowing up notification center with marketing shit. I go to settings. Notification settings. Tinder's at the bottom so I just want to use a search bar instead of scrolling. There's no search bar. Minor inconvenience. Dark mode isnt dark enough for me. I guess thats just too damn bad, because for the next two hours, I'll have to figure it out by messing with accessibility settings. Time for bed, and I'm just getting plum tired of having to turn on my alarms every night for work the next morning. So I used the 'Automations' app to do it for me. For the next two weeks, at the time specified, 'There was an error running your automation' until I just delete the automation. Browsing through the FaceID settings, I see 'Attention Aware Features'. Cool, maybe now my phone won't automatically dim the screen when im in the middle of reading notifications on my lock screen. Haha, nope still does it. After turning on my alarms, I go to sleep. I wake up an hour late for work because those handy 'Attention Aware Features' silenced my alarm immediately because I fell asleep watching a youtube video.
I could go on and on. Its actually making me feel depressed typing this on my phone, fighting with Apple's primitive autocorrect and annoying implementation of Swype to type.4 -
I spent hours trying to support \n, \r and \r\n in my algorithms to convert between utf16 line/col and utf8 absolute indices to comply with the LSP, before realizing that
- Orchid itself doesn't support \r
- There is no established user base
so I'm in the best position to reject all files that contain \r and offer to convert them instead.10 -
a lot of dev have a miss concept about Unicode/utf8 including me but I believe my understanding get Better and this my last version.
For a project i was developing a rest api for mobile app
when an ios dev asked me
"I send you Unicode string but it appears as ????? in admin web panel "
OMG!!!😨😨😨
Unicode is not an encoding nor an algorithm. it's a standerd which just map a glyph to a codepiont .
but utf8 is the encoding of Unicode and how it's stored or transferred ,
the string you send must be a utf-8 encoded string as the rest of the json you sent . -
In some cases only emojis are not encoded properly - dont know how to replicate - dont know why its happening (made sure im setting to utf8)3
-
Please help me before I get mad,
First day with Linux Mint.
Objective: Make a 3Tb Hdd Read and Write, Right now I can use it only to Read.
Finally Installed Linux after some bumps (bad ISO).
I have 2 HDDs, the SSD with Linux and a 3Tb HDD
Right now the 3T has 4 partitions, one for windows, 3 for personal use with lots of personal stuff I can't lose.
I've been looking for videos, tutorials and the maximum I got was to had one partition mounted as a folder
<code>
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=f0a65631-ccec-4aec-bbf5-393f83e230db / ext4 errors=remount-ro 0 1
/swapfile none swap sw 0 0
UUID=F8F07052F07018D8 /mnt/3T_Rodrigo ntfs-3g rw,auto,users,uid=1000,gid=100,dmask=027,fmask=137,utf8 0 0
</code>
What am I missing?
PS.: Next: Make fingerprint work in Linux14 -
I remember playing games like wolfenstein3D, supaplex, sokoban etc. on our family computer 486 which had as I remember around 100mhz processor. (120mhz in TURBO mode)
Yeah and I did created a few levels in wolfenstein, there was a simple editor.
From programming view I did code my first website only using html and inline css in early 2000s. However internet was a thing of a rich people back then (in my country), so my brother downloaded the whole website with docs and basics of html/css/js for me in collage. My first website was coded on 300mhz pentium2 (or 3?) with no internet connection, took me about a two months to complete and was total mess. But was graphically satisfying with nice gifs which took tens od seconds to download. Main container had 600px width and looked pretty good on my 800x600 resolution.
I still remember messing with BOM signature because of notepad could not save a file without BOM. Leaving all utf8 chars as mess after saving.
Good old times. -
What is the problem with nowadays colleges? So many of the programmers I know know absolutely nothing regarding encodings and such.
It's pretty nice to see people resorting to hexadecimals to show their Latin characters in HTML instead of simply learning about bloody UTF8 -
So this rant:
https://devrant.com/rants/3969110/...
introduced me to the unicode's "zero width space". Lately I've been using it to cheat on "required" fields in forms. Hahaha thanks!4 -
I had to program a webservice in PHP (never touched it before). First of all, i get why this language is so much hated. Second i had to debug one function for 5h because of 'é' in my DB.... UTF8 FTW i guess.
Let's finish this by a pun
PHP is really a rich language. -
Want a simple but terrible annoying prank?
Change the keyboard map from UTF8 to ASCII or vice versa and set the system font to something funky like a Greek or Cyrillic variant... :)1 -
The one thing I need, a "LATIN SMALL LETTER REVERSED C WITH DIAERESIS" doesn't seem to exist but "LATIN SMALL LETTER C WITH DIAERESIS" the one thing that I don't need, does D:
Like there's a god dang sideways u with an umlaut (or diaeresis I guess) but not a reversed c̈? pls9 -
Came across a book by Clinton L. Jeffery that details in programming language design, a topic that has always fascinated me. So I went ahead and bought the book knowing full well it uses an obscure language called Unicon (cool fucking name) devised in order to mimic the Icon programming language (obscure as well) which are languages that detail goal oriented programming. While I do not mind the language itself, seems pretty good for my taste, does not use curly braces or semicolons and a lot of other scripty things, gets compiled to bytecode and works well, but shit man, trying to find documentation for this outside of its own (I don't like it) book is a pain in the ass. To give some perspetive: you know you are dealing with some obscure shit when there ain't any youtube videos on the language. It has some interesting notions, but I just fucking hate the "documentation standard" book that it has for it, and yes, this is because the language has not taken any actual traction from the masses, there are some things that it does not have such as full utf8 support among other things, it really is a nice tech but I hate the lack of proper documentation/tutorials on it.
rant off2 -
I spent fuckin whole day on a defect..
I made a cma content using fatwire in which I added £ on a html snippet and it converts to (£) and when I use it in page it shows £ even it's in utf8..
Can anybody help? -
Anyone find a Pixel 6 Pro tempered glass protector?
I can find films... Ordered this for now. https://amazon.com/dp/B09JYJ278J/...
. Is it because of the curved edges...
Or the on screen finger print scanner...
Only found thin films.... No it's how good those are... -
I have question related to hardware -
I recently order a M.2 SSD on amazon but I don't know is it compatible or not with my system and I order it can anybody help me I am really apricate it.
My SSD link on amazon -
https://amazon.in/gp/product/...
My system link -
https://amazon.in/Lenovo-Ideapad-33... -
Fuck powershell.
How in the world can one lang have so much problems with date conversion, and chars like üöä. Its so funny how they get through just fine sometime when u specify encoding utf8 but other times it has no ides wha5 these chars are.
Honestly fuck powershell