Friday, March 29, 2024

Windowsization of MacOS

I'm killing it on the new project, so I felt comfortable to ask my boss for the MacBook, instead of buying it on my own, and have it as a work computer, since I'm attending quite a few meetings lately and it's a pain to look for a wall plug all the time.

To my surprise he didn't bat an eye and he even said it's better to go for a better SSD as well, so 16/512 it is. The only available color at that time was Starlight, which was my least favorite, but it was already ordered when I was told that.

The laptop arrived the next day and I was eager to try it. When I peeled off the protective sheet, I was quite stunned how beautiful the actually color is, basically silver with subtle gold accent. Looks so lavish and I love it! :-)

I had some basic experience with MacOS, so I wasn't that lost, but 30 years of daily driving Windows has it's toll. I started to look for ways how to make it feel more like “home” and apparently that's quite common thing among Windows users :-)

Document based, not Window based

Raycast, removed Rectangle

Double Commander

Mouse fix UnnaturalScrollWheel

AltTab for hidden windows, Shift instead of ShiftTab to go back is great!

App to remap keys

Thursday, February 29, 2024

MacBook Air

For years I've been struggling with iOS development, as I didn't have a direct access to a Mac, so I had to circumvent this issue and it wasn't always easy. I feel like I've spend similar amount of time coding and getting to be able to.

My daily driver is now entering it's second decade of service and there wasn't a sufficient replacement so far. It's a really reliable workhorse, but as time goes by, I'm getting afraid it can kick the bucket any day - in the past I had some issues during bootup, so I don't even turn it off any more, only put it to the Sleep Mode, and restart just few times a year, usually to resolve some annoying issue that couldn't be resolved in any other way.

Travel device, not that light (1.24 kg / 2.7 lbs, 3 times Apple Magic Keyboard) but almost as small as my old ThinkPad X31 (3 cm wider, but 1 cm shallower and 2 cm thinner)


MacBook Air 13" in "Starlight" color

I also kinda dislike a second device, when I prefer to have everything just in my phone. But the tech simply isn't there yet.

Phone with kbd is clunky, turning on, no on-lap possibility

Dev debug device

Xcode dev

Great tech - Apple Silicon, larger display with workable resolution, TouchID power button, backlit keyboard, Magsafe as well as USB-C charging, ridiculous battery life

No OLED

Sync files - daily backup to USB (broken USB port), via phone

At home I keep it i “clamshell mode”, connected to a simple dock with passthrough power and HDMI cable to my LCD screen as HDMI2(?), use my Magic Keyboard and second position on my Logitech mouse.

M3 for xcode, months of support, latest macos

Thursday, January 11, 2024

Looking back on 2023

I have to say, I had some great years, but 2023 must be one of the best so far, despite it wasn't all rainbows and unicorns.

final version quid, wrinkles here and there

qard getting nicely, looking forward to 2024

codebase getting big, but not bloat

business is doing great, but maintaining pretty much all versions all the way back to the first one, with direct DOM manipulations.

My workflow has been fundamentally affected by Chat GPT, in a positive way. I've never transition so quickly from "I don't know this" to "I can't live without this", I suspect it was during a single day!

Wednesday, July 26, 2023

Arctica (Svalbard)

Our trip to Antarctica was fantastic and the very special occasion we went there for repeated once again in the summer as well, so a thought of visiting both polar regions just a few months apart really intrigued us. This time only for a few days though, because 99 % of Arctic tours are “just” around Svalbard anyway and it's quite pricy there.

To our surprise my wife found a 6 day trip with 4 day expedition cruise, similar to the Antarctic one (yay!), costing as much as just accommodation in Longyearbyen with guided day trips for the same duration. It was no brainer, we booked it matter of hours.

Fixed dates made airfare booking much simpler. I found 4-leg itinerary, via Brussels, Oslo and Tromsø, with Business Class for just €20 extra! But  the flight home wasn't ideal, so we went for the much cheaper 2-leg option, with almost a full day in Oslo.


Home-smoked seal, reindeer and whale.

It felt kinda weird to just hop on a plane and go way past the Arctic Circle – no all day flight, no Drake Passage... Per usual, we didn't hesitate to taste the local fauna, even though some items on the menu can be controversial.

To my glee the expedition cruise was really similar to the Antarctic one, the weather and scenery as well, although “low-grade” – smaller icebergs, fewer animals (oops, did we ate them all?), but more colorful surroundings.

Because, to my very surprise, I didn't mind the polar plunge in the Southern Ocean, I was ready to repeat it. But this time as a polar swim – going to the icy water from a shore. Yikes!

I confirmed my previous experience, that I need to endure first ~20 seconds of big discomfort, but after that I can stay in the water for minutes. The only downside was we both injured our feet from stomping on stones while rushing into the 6 °C / 43 °F water.


Smeerenburg Glacier over Bjørnfjorden

There was a Wi-Fi on the ship and I was curious to try their mobile app, that works only while connected to the on-board Wi-Fi, but it's apparently only for the bigger ships, because it didn't work on this particular expedition ship.

GSM signal kms from Longyearbyen, EU roaming, radio silence in Ny Alesund

logbook in Canva

Saturday, February 4, 2023

ChatGPT

Mind blown. When it comes to anything regarding IT, I consider myself a seasoned veteran and there aren't many things that astound me. I went from “I don't know what all that fuss is about” to “I can't live without it” in about two hours. It's like Google, but instead of personalised ads you get personalised responses. For me it might be the biggest jump since the internet itself.

I love I can be super lazy in writing prompts, it doesn't care about typos or abbreviations and is very context aware, so I don't have to write extra words. It will grasp terminology, acronyms, newspeak, slang or even mixed languages! It can translate no problem and its sentence elaboration helps my learning Japanese immensely.


ChatGPT Logo

Asked for source, it gave me the source. I asked for links, gave me the links. Many of which were 404 and I thought they simply changed since the learning cutoff, but after a while I started to suspect those links were actually hallucinated by the language model.

Quantum computing explained, simple WebGL 3d engine or basic isometric engine created. There are devs with mobile apps accepted to the stores with zero lines of code written by themselves. It's endlessly helpful with regular expressions, I just describe what I need and the model is often correct on it's first try.


Neural network schema

Although I sometimes struggle, it's still VERY helpful. It's much quicker to simply ask ChatGPT, which will usually respond on topic and distills the info into four paragraphs. I don't have to click on dozens links, half of which doesn't even contain the keywords for some reason.

I kinda like bouncing off ideas or asking GPT to provide lists of things, like when I was looking for inspiration for Qard, I asked: "how they do it in all major game engines?".

It really excels for "easy" programming tasks in languages I'm not that familiar with (like code to download and unzip file), or to translate code from one language to another. But it could be frustrating to have a specific code in mind and force GPT to comply. In a few instanced it started to loop around, disregarding any further prompts.

It's kinda strange, but while many others complain it plagiarizes a work of thousands, I'm so mesmerized by the language model's capabilities I've started to think how to give it even more sources. Maybe QB data will come in handy for a plugin?

Despite all it's flaws, like hallucinations, it's very handy sidekick. I even tried to task it with a few topics for this blog :-)

Monday, February 27, 2023

Antarctica

When we put all the reasons together, it was obvious our decade of Earth exploration have to conclude in a grand finale – the last continent. And it doesn't matter what you consider a continent, we've done all of them. Well, except for one, but that was about to change.

We didn't want just to dip a toe into the peninsula, because the time and money are considerable in any case, so we were looking for a cruise that goes below the Antarctic Circle. That decision made things a bit easier, because only a handful of companies offers such voyages and those reasonably priced you can count on one hand of not so skillful carpenter.

And one day we found ourselves in the middle of the Drake Passage, heading south on an expedition-type ship. But to stay on-topic, let me describe the level of IT we had available.


Antarctic Peninsula from Stonington Island

First of all, they managed to print “á” in my last name incorrectly on a few occasions. I always thought it's a safe letter, it's been around since the Extended ASCII from 1970s. They all usually want my name EXACTLY as printed in my passport, but it contains accented letters, which they can't process or even disallow them completely (like most airlines do).

On my plastic passenger ID card there was “Ô in my last name, which is apparently double-encoded Unicode “á”. At the end of the day it didn't matter, so maybe that's why nobody raised an eyebrow about that.

Next, on 2 of my certificates of achievement in PDF there was “¡” instead of “á” , which is also a remnant of the same error, because the full conversion is “á”. Oddly enough, on one certificate, using the same font and everything, was my last name correct.

Later I was told different certificates are created by a different staff member, so my assumption they'd generate them was quite naïve. Now I suspect they just have a DOCX template, which they copy for each certificate and only change the name. As if they don't have so much things going on as it is...


My Polar Plunge (water had allegedly -0.5 °C/31 °F). Photo courtesy of a fellow passenger.

There was satellite internet on board, you could purchase a 1 GB voucher for $40 or 5 GB for $120 to use it either in your device (on-board Wi-Fi) or at one of the three desktop computers in the Computer room, that were mostly used for sharing pictures among passengers.

There were two big antennas on either side of the topmost outside deck, reading “Marlink” (connectivity provider) and “Intellian” (antenna manufacturer). Besides that there were all kinds of antennas, weather sensors and detectors on the deck, each one labelled.

I opted for an on-line detox, so I can't tell how reliable it was, but I could see an "Internet Offline" sign at the reception for longer periods than a paying customer would like.

I missed the internet only for checking CruiseMapper (to see how well we're doing, apparently we were the southernmost vessel at some point) and to hope for an Antarctic Pokémon, which would definitely spoil my overall experience. It was nice to be immersed in the wilderness without any distractions from the “real world”, which we actually had it all around us.

There was a big screen with OpenCPN 2.3.1 (current version is 5.6.2, what a surprise... :-) to plot our route and show us marine map of our surroundings, which was interesting and quite useful couple of times.

P. S. This trip was another big reason why I upgraded my iPhone. Totally worth it! And even months later, I still love the thing. I wish I'd find such upgrade for my decade old laptop...

Saturday, January 21, 2023

Still baking

It's been two years and I still bake, now more than ever – with the ongoing inflation some items went up 20 %, so I'm using my wisely created stockpile of cheap flour and olive oil, and we try to use the electric oven for as much items at once as feasible, because it takes 10-15 minutes to heat it up.

While my wife was out skiing, I enjoyed some alone time and tried to bake a pizza. To my surprise it went really well and the dough was delicious! However, regular oven is not hot enough for pizza, the best you can do is to preheat it to the max (250°C / 480°F in my case), including the baking tray, and bake it nearest the top heating element (for just 7 minutes).


Salami mozarella pizza with green olives

As I mentioned, we regularly eat savory pastry with something (cheese in my case) for dinner, as lunch is the main meal of the day. So now I bake twice a week, on Monday and Friday. I found a way to bake as soon as possible after we return home from work, using retarded dough.

I prepare the dough in the evening and let it proof. Then I shape the rolls and stuff, put them covered in cling film to the fridge till the next evening. Then I take them out of the fridge to heat up a bit, preheat the oven to 230 °C / 450 °F and bake it for 18 minutes.


Buns, bread rolls and my signature GridBites with caraway

poppy seed filling non cooked using yogurt, with plum spread (povidla)


Poppy seed star
Tuesday, November 29, 2022

iPhone 13 mini

Here on the blog I digress quite often, so this time it will be how I decided to upgrade my old iPhone SE from 2017 on this year's Black Friday.

Long story short, I don't want to migrate do Android (yet?), even the smallest iPhone 14 is too big for me, rumor has it another mini iPhone may never come, so this form factor won't be any newer, so why wait?


iPhone 13 mini

The transition would have been smooth, but quite a few of apps I used were pulled out of AppStore, so for about three days I tried (and failed) to move them to the new phone. I even purchased a license of iMazing, but it was no help either – apps were either 32-bit or otherwise unsupported by the current iOS version.

So I finally wiped the new phone and used the intended way of wirelessly transfer everything from my old iPhone to the new one. The process looked like magic to me, to be honest.

I have to admit I'm more happy with the investment than I anticipated. While the body is only slightly bigger, thanks to edge-to-edge display the screen size difference is astonishing. I quickly adapted to the size, the 4" screen of SE now looks so tiny! :-)


iPhone SE vs iPhone 13 mini

On SE I had Touch ID difficulties more often than I would like and my earlier attempt to refresh stored fingerprints resulted in auth resets and lock-up from my bank app (I didn't have backup 2FA method for some reason), so I wasn't keen to do it again. But Face ID is quick and easy, it's so seamless it makes me joyful :-)

It was good I had the SE around, because I had to migrate all the bank and auth apps, this time without a lockup only just because I was able to use the “previous” app on the SE.

I didn't want to migrate to Android mainly because of the long history of various app data I collected – I've been an iPhone user for over a decade now. But several apps wasn't compatible with the current iOS version, so I lost that anyway. With the new phone I'm more careful about data formats and migration options. I'm still waiting for my ideal phone and if it's Android or Windows, so be it.

Thursday, September 29, 2022

Indonesia

With my wife we're keen travelers and our goal is to visit at least one new country every year. Our 62nd country was Indonesia – Java + Bali + Flores/Komodo + Lombok. It was interesting to see the huge difference between Java and Bali, it's like a difference between California and Hawaii. I can claim I was in the US when I only visited Hawaii, but I kinda wasn't, was I...

The reason why I mention this trip here is I was amazed about the level of digitalization there. First of all, it felt like one quite significant level of living standards is missing – especially garbage handling. It made me sad and hopeless to see garbage burned in the streets and dumped into rivers, especially with EU's Green Deal having some economic impact on us.

But, on the other hand, every major thing has its app and website, albeit often only in Indonesian and often somewhat partially broken or obsolete. I added six apps to my phone before the trip and two more during our time there. Later I found out the situation is quite similar even in my home country of Czechia.


We eat locally as much as possible, so tourist restaurants weren't option for us. We opted for local eateries called `warungs` instead. They often use a shallow woven basket with waxed paper inside instead of plate, but you can also have the food delivered to your hotel by an on-line services, like Grab or GoFood. Apps are very straightforward; it took me less than an hour from downloading the app to eating.

Everyone (including some businesses) is using WhatsApp and they often expect you to do so as well. Similarly to Costa Rica we visited last year, there are also mobile data plans, that exclude WhatsApp (and some other apps) traffic from the data cap, so you can chat away as much as you want.

Because of that, we purchased a local prepaid SIM card with a data plan. At the airport they offer only a single abundant plan (25 GB for Rp150,000), while our prepaid from a Telkomsel's stall on local market was sufficient 7 GB for just Rp25,000.

But the SIM card still needed an activation, that could be done only at their locations (called “GraPARI”), and it requires IMEI registration with the government, so the process takes at least 20 minutes. Take that into account, especially if there are other tourists already waiting before you.

Public Wi-Fi is on many places, especially airports. At Jakarta, Yogyakarta and Bali airport they use the same login process, which was quite... original. I tried my .cz e-mail address, but it said it's not valid – Gmail was OK. Then they wanted my phone number, but a list of country prefixes was unsorted sorted by country name, but without the country names! So you either spent eternity scrolling thru dozens of prefixes, or you just gave up and entered a fake number.

Another login option was to use Facebook, but mine is secured by 2FA and on my iPhone I wasn't able to return to the login form without forced reload, after which I had to start over.

So I waited for authenticator code to refresh, I copied it and immediate connected to the network, which prompted the login screen to appear. I used password manager to quickly fill my credentials and in the next step used the 2FA code from clipboard – all in under 30 seconds, before the code expires. This can't be done in busy times, when the network is overloaded though.

Friday, January 28, 2022

Are you REALLY debugging what you think?

Last year I wrote about making sure you're editing the correct file. Now I have a similar topic.

It happened to me, that I was mentally expecting some value, so I was baffled why the code doesn't work. It was a numeric code, so it wasn't apparent that actually the code did what it supposed to do (duh!) and I was in fact expecting some other code, which wasn't the one I was getting.

Friday, September 3, 2021

I'm not a code monkey

As I wrote before, I've decided, that whenever I'll feel the project is steering into a skid, I'll either take over, or quit. I've got this feeling after I dove into the new codebase in project I [|mentioned in June].

I expected the guy, who took over, had much more experience, but from my point of view he's something like a seasoned junior. He does the exact same design mistakes I did when I created my first iteration of Qedy five years ago.

His approach creates a lot of static code, spaghetti code, many copy-pastes, tons of element queries, no internationalization, multiple versions of the same thing (like modal window), ignoring accessibility, and with lack of guidelines it creates multiple coding styles.

He enforced heavy gulp, compiling JS modules with Webpack and Babel into a single .js file, which currently has over 1.5 MB.

My original version didn't have this size even with all assets and featuring triple the functionality. Plus, I believe the widely used querySelectorAll to data attributes takes as much CPU cycles as my version needed for the whole module to parse and render.


I tried to object to all this, but the other junior sided with him, so my complaints were dismissed. My further ideas for improvement got glided over as well. I didn't want to look offended they replaced me, which I was, to be honest, but I was also relieved it won't all stand on my shoulders.

And he configured the gulp with BrowserSync, which is probably used by someone who doesn't save their code often, because I do and the constant unnecessary reloads drive me and my CPU temperature up the wall. Also, I often lost my progress within the app, because I did a change and PhpStorm saved it for me.

So, I obeyed and started re-creating three modules under this new paradigm. Yes, it was really nice and refreshing, that everything was possible, but I was also quickly forced to create a bunch of sets of fairly similar functions. I took the liberty of not optimizing anything, because it was faster and apparently that's what matters now.

But soon I had enough of it, with a very slow progress and a lot of annoyances. I took advantage of my younger colleague and introduced him to the team as my upcoming replacement. At work I have the golden opportunity to refuse working on projects like this, so after a point of no returned I gladly, but also sadly, played this card.

I wish the team the best of luck. I simply don't want to sink so many hours into blindly coding thousands and thousands of lines of single purpose code.

Friday, June 18, 2021

Forking

This blog post is not about either of the things you may think ;-) As I mentioned in my dev curses, I'm a forker – person, who likes to start new projects. For me it's mostly because I like the quick progress in the beginning and the initial simplicity of the code.

The Pareto principle says, that initial 80 % of work require 20 % of time. The problem is, when I start reaching the last 20 %, the task tends to get much harder and with to incentives to finish it, I abandon it.

Especially with a new generation of my framework, I tend to try it on so many previous projects or even projects we competed for but didn't get to do. But because I have all the public documents for it, I'm basically eligible to do it on my own anyway.

So with ES6 Qedy.js it was the same story all over again.

My reasoning is I can test the framework in different scenarios, before there's a real project with no time for reengineering, so all needed changes would go to a tech debt. The reasoning is valid, but even better would be to just write thorough tests.

The initial simplicity of the code stems from lack of coverage for all the edge cases it may encounter. Also there's not enough features for all the intended use cases, only for the current ones. Again, tests would be much more useful. But they are often tiresome and boring thing to do.

Thursday, June 3, 2021

Reality check

On one of my projects the project owner hired a junior JavaScript programmer, so there are 3 devs in the frontend team now. I gave the newbie a two hours long walkthrough of the system and we agreed on further steps.

During the following status call I was told it's too complicated and the team decided to go with a simpler approach, led by the second dev, who proposed the rewrite in the first place. I didn't protest much, because I could use some free time right now, after months of long hours.

But I expected him to have a solution in the pocket, not to come up with it along the way, as he apparently did. The project leader warned we need it up an running in a better than current shape by September and it looks he thinks it could be done.

I have to admit I was kinda disenchanted by the decision, so I didn't confront them with a warning the current version took over a year to finish. Moreover, the “simpler approach” is pretty much vanilla JS with HTML in it. In my eyes it's a recipe for a maintainability and customizability disaster and it feels like how I did stuff in early PHP 5 almost two decades ago.

I created quite comprehensive list of all the features the current and past versions have, to give him some kind of check-list and overall scope of the task, but I got the feeling they just read it and were done with it. I also hoped it might put them into perspective how much work it will be.

But what strucked me the most was the whole concept of QetriX was apparently incomprehensible for them. They didn't get it's pretty much just a different approach to MVC, because they argued the new version will be MVC at last. My primary motivation was to make stuff easier – did I fail?

I admit I'm no mentor and I didn't want to dump all the quirks of QetriX on them, so I glossed over it and explained only modules, components, datastores and converters. In my eyes this is sufficient enough and everything had an example and some documentation.

I probably didn't emphasise enough the HTML structure is defined in Converters, so the second dev tried to manipulate basic Converters into what he needed for his design to work, instead of creating a fork of the Converters he used. He basically used QView as DIV and didn't ask. Not to mention he wasn't supposed to code the module in the first place...

Anyway, pretty much all my projects went away from IE11 now, so I don't need to stick with ES5 any more. ES6 allows for much leaner code in many ways, so I decided to try what I can do with it. Because it suppose to be fun project (at last), to distinct it from work, I'll use VS Code for it.

And because it should be as straightforward as possible, my goal is to keep everything within 1000 lines of uncompressed and well documented code.

Sunday, February 14, 2021

Baking

As a keen developer, I'm mostly happy with nonstop coding. But time goes by and there's more to the life, than just that. People, like me, are often encouraged to collect “positive life points” by doing something different, to clean their heads.

As I already mentioned, to help with my looming back aches I started running, around 3 miles every other day or so, listening to podcasts, comedy or my custom playlist I crafted to support my running tempo.

Last Christmas I sampled a few vanilla crescents, as I usually like to do, because almost everybody has their own style and recipe for them. My wife nudged me to try her nanna's recipe myself. I was intrigued to sample my own crescents, it was quite an easy recipe, and I finally had an old tablet for Qip to display it while I'm baking, so I took it as a challenge.

Honesty aside, they were awesome! I was really proud my favorite kind of vanilla crescents is the one I did myself.

Timing and COVID caused we didn't get our traditional New Year's small gingerbread piggy from my aunt, which made me somewhat sad, so after my success with the crescents I decided to try them as well. I found a recipe simple enough for me to try, with positive feedback in the comments.

It took much more time than I anticipated, mostly because I had to cut some of them out with knife and draw on them by hand, but yet again I succeeded, and I even made a batch of meringues from leftover icing. The most important part was it didn't bother me at all – I kinda had fun. So it got me thinking and because I love pastry, I upped the ante. Next level: bread rolls.


Gingerbread stuff, hand drawn by sugar icing.

Side note: In Czechia, lunch is the main meal of the day, often hot. At home we adopted my in-laws' fashion of cold dinners – usually bread with sausages, ham, cheese, spread etc. I eventually phased out processed meats and in Switzerland we discovered multitude of great cheeses, so my usual dinners now are just bread + gouda, also with lettuce and cherry tomatoes.

I found very simple recipe for yeast-leavened bread rolls from wheat dough and, as before, I tried various shapes and sizes. I was encouraged by low cost of used ingredients, so if I fail, I would have wasted about a buck.

The first batch wasn't that good, but it wasn't bad either. I used too much yeast and not enough salt, so it tasted yeasty. Apart from that it was OK. I still had fun doing it, even there were some rough edges in the process.

I smoothed them by gearing up our kitchen a bit :-) I found a 20 % store-wide discount at my favorite Czech kitchenware manufacturer, so I ordered a digital kitchen scale, infrared thermometer and new silicon baking mat.


My latest masterpiece - vánočka, braided from 9 strands.

I immediately started experimenting, because I was curious what would happen if..., and learning, why it needs to be that way. All batches remained edible so far. Now I make my bread rolls with rye/spelt/wheat flour, sea salt, water, olive oil, and leaven from baker's yeast. I'm also baking sweet pastry for weekend breakfasts, like sweet rolls, cinnamon buns, kolaches or strudel.

I'm gonna need to run even more! :-)

Friday, January 22, 2021

Are you REALLY editing what you think?

Developers should be aware, that sometimes they think they're editing a particular code, but it's in fact some other code. It may be the same file in a different project, or the same file but in a backup folder, or really the same file but wrong section of the code, or recently copied class to be modified as a different class, but you accidently started rewriting the original class, or something else like so.

But even if you truly edit the correct piece of code, you're not out of the woods yet, because you may test your changes on a different one. For example, you're editing a local script, but running it on a server and wondering why your changes aren't there.

And there's also caching and compilation. PHP has opcache, which may keep the old code for minutes or hours. Also various frameworks cache precompiled code for better performance and after any change you need to wait for the cache to update or update it manually.

In JS you may accidentally export an incorrect named variable, which may happen after refactoring, if you forget to rename the export as well.

In a different dev setup you may rely on a process restart, but if the process remains active, it could just keep running with an old code. If this is unexpected behavior, you might not even get an error message during compile.

If the code doesn't change after first few tries, make sure you're REALLY editing what you think. You can lose a lot of time because of such silly reason. I didn't make up any of those scenarios, all of that happened to me. The only commiseration is I gained quite a lot of experience, as described before, to quickly realize the situation.

Saturday, March 21, 2020

COVID-19

You probably read a zillion articles on this topic, so I'm going to focus on QetriX in particular. I'd like to point out it's safe to work with official QetriX implementations, because all the inputs are properly sanitized... (tumbleweed)

As a software developer, with only long-term contracts, I wasn't affected by the mayhem that much. The only major change was a switch to online meetings, which I personally prefer, and as an introvert I was preparing for social distancing for years :-)

I don't mind wearing a face mask, after visiting Japan I learned Japs wear them for years during the sniffles, so they don't spread it, which I'd love to see in other countries as well and personally would totally do.


Due to many restrictions I spend more of my spare time at home, so I have more time to experiment with approaches and think about them. Less traffic also help me to get to and from work more quickly, so there's another time right there.

I was planning to get a haircut in March, but the restrictions came and my only hope now is there will be another Woodstock coming. Fortunately, my spouse is talented in many ways and she managed to adjust my receding hair quite nicely.

Summer update: I was really hoping my mid-October travels to remote places of the Earth, planned and even already heavily paid for since last year, would remain unaffected, but sadly the airline bloodbath made some deep cuts into it and ultimately all three transcontinental journeys were canceled.

Autumn update: Believe or not, our mid-October travels happened! We booked our tickets just two days before departure, after our PCR tests came out negative, despite the fare for two climbed up by €600 (“by”, not “to”...), because the cheapest ones sold out.

Airlines reduced their schedules to a right amount, because most flights were packed, but on many places we were the only visitors. And of course we travel responsibly and cautiously, and underwent a test before, during and after the trip – all of them came out negative.

From this experience I can say traveling is possible and it's not important that you travel, but how. It's far better to travel safely, than have a beer on an illegal party with strangers. I'd say the latter is the case for more people.

I was amazed when learning about mRNA vaccines and honestly I think this  research deserves the Nobel Prize in medicine. Not only it turbocharged COVID-19 vaccines, but there are tons of other opportunities for previously failed drug attempts to be finally successful using mRNA approach.

Saturday, December 21, 2019

Making content is hard!


Sometimes I arrive to a meeting very early, so I kill the time with my laptop in a café. It makes me feel somewhat special, glamorous. I can imagine myself copywriting on lightweight device and such, as seen on Instagram, obviously. My dream job would be a content creator – flying around the world, taking pictures, shooting videos and writing about stuff.

The first problem is I'm not able to take a good picture. The second problem is for content I'm quite a perfectionist, I like my texts crafted. If I write a comment, at first I spend 15 minutes researching my arguments and then, if I'm unable to articulate them perfectly, I rather delete the post completely, than submitting text I don't like or I'm not 100% sure is correct.

Also I'm trying to make my posts as short as possible, especially on Twitter and sometimes here in the blog (apparently not this time though), but at the same time I want to include as much info as possible, without sacrificing clarity for the audience. And it takes time. Quite a lot of it, actually.

My other problem is I have some form of ADHD, so I lose focus quite easily, especially when facing a harder task or task I somewhat don't want to do. If I need to create content, I often can't write it in one sitting, I'm more likely going to abandon it for a while and finish it in further attempts, going back and forth between different unfinished posts.

Next problem is I'm rather doing things, than writing about them, so as a result I often neglect all my content channels, like my several Facebook pages and Twitter accounts. This blog was dead for a few years and to be completely honest, many articles in that period were written ex-post in a retrospect, some original drafts were resurrected, reviewed and edited.

Sometimes it's a challenge even to come up with a topic to write about in the first place. I admire Factorio team for their Friday Factorio Facts (FFF), with interesting post of usually respectable length every week.

In a quest for more topics I wrote a few posts about fairly generic things, like (spoiler alert! :-) UML diagrams, and during verification searches I found some stuff I didn't know before, and because I tried to compress it as much as possible, I had to think about it a lot and it just stayed in my memory.

So despite such posts are all over the internet, I'll create one more place for them, because they help me assort thoughts and knowledge, memorize stuff better and as a nice side-effect, it makes me to add features to the blog content editor and learn a bit of English on top of that.

If I want to beautify a post with a picture, I usually look for an inspiration and because I can't find anything royalty free, I create it myself. I mostly use draw.io for vector illustrations and Paint.NET to edit photos.

And don't let me started on videos. Purely out of curiosity I shot a pumpkin carving tutorial in the past, completely with editing, voiceover from script and I even composed a simple background music in FL Studio for it.


It took me about two full days in total to record everything and another day to put it all together, while the video is just 3 minutes long. I don't share the final video here not because it's in Czech, but because it didn't age well :-)

There is a slightly easier way, which has been widely adopted by YouTubers: use stock footages. There are millions of high quality clips in many banks, you “just” put them together, record a voiceover, slap a message from your sponsor somewhere inside it and release, rinse and repeat.

If done right I have nothing against that, but what I realized after I watched many of them is they make them unnecessarily long. The message itself would often fit into a minute, but they create at least a 5 minute video about it. I don't know if it's because of the revenue or sponsor (to fit another ad-slot in the middle), but my time is precious and I prefer clutter-free answers over “stories”.

I also tried to shoot and create a vlog video in Casey Neistat's style, during a solo hike near Zermatt. Again, just out of curiosity. I knew it wouldn't be easy, but the actual amount of time it required for a decent (yet still quite bad) clips to shoot and later to edit and put together really surprised me.

Another experiment was with animated illustrations. I created “How to draw a QetriX Logo” video in, don't laugh, Microsoft PowerPoint. It may sound ridiculous, but it's actually a really nice piece of software for this purpose, as it's easy to use, timing and animations are simple to make and it can export the final presentation into a FullHD 4K video file out of the box.

I played violin as a kid and I still keep one set at home, so I tried how hard it is to play a duet with myself. I recorded myself playing first violin on a voice recorder app in my phone, then put that recording to my ear and tried to sync playing second violin with that.

My favorite duet appeared to be a bad choice, because it requires both musicians to wait for each other from time to time, but nevertheless I didn't expect the timing to be that hard! After third failed attempt I declared it “good enough” and moved on.

It didn't occurred to me at that time I was in fact supposed to record a video of myself, giving visual cues as a proper first violinist. When I tried this a few years later, it wasn't that hard to sync after all.

Sunday, August 5, 2018

No more management issues

In March I spilled some concerns about management of the project I was working on. I'm not using “my project” on purpose, because all my attempts to take over as a project owner failed.

Since then they contracted another developer and assigned to him half of the project, the whole custom e-Learning environment. Moodle turned out to be more complex than what we wanted.

His idea was he'll deliver quickly and effortlessly, because our managers gave him the same notion of their vision for the platform, as they gave to everybody else. He looked skilled and we did a lot of improvements based on his suggestions, many of which I suggested a few times in the past already... Never mind.

Long story short, he didn't deliver anything. Every other meeting the managers came with another change, another use case, another feature request, but when we wanted more thorough info from them, they just repeated the notion of their vision, which was overwhelming, not detailed.

It felt like the managers didn't cared much about the project, they just wanted it to start making money already. After all, they're businessmen, not project owners. That's why I wanted to take over this part from them.

We wrote a technical overview of each component and tried to stick with that, but we also had to account for all of the extra garbage in our minds they threw at us and at least in my case it created a huge overhead, because I was trying to include every possibility that could come up. Instead of a light at the end of the tunnel there was a boring drill.

I was quite struggling at that point, but out of nowhere, a deliverance came. Something felt odd that day and the next day the managers came to me to conclude the project (apparently contract negotiator made a mistake, which canceled approved funding). I was to return to my previous job and start once again on my own projects. God, I missed that!

Lesson learned. From now on I'll listen to my gut more. If the project won't feel right, I'll either take over or quit. But also I'm grateful for the job, even despite the struggle, as it wasn't always there. I worked hard on Qedy and got tremendous amount of experience, thanks to the freedom and trust they gave me.

Tuesday, March 27, 2018

Management issues

I was hired to create an integration platform between custom backend and WordPress, PrestaShop, Moodle and payment gateway. The idea was to create an e-learning platform, where users can publish content, shop for on-line courses and study, using video lectures, reading materials and tests.

In fact, I was hired to take over from two other guys, who failed to deliver. I honestly didn't understand how they could be so incompetent! I offered Qedy and managers agreed to further extend and expand it, which was really tempting for me, so I took the opportunity.

I was waiting for specifications and in the meantime I was working hard on a middleware, that will be flexible enough to catch whatever they throw at me. I had a complete freedom, which was truly magnificent. During the time I was briefed about the concept to get an idea what I'm building the middleware for.


I finished API integrations with all four systems and when I presented an early version, I was told there's no need to integrate WordPress. Ok, never mind, it was the easiest one to do anyway.

When I finished all workflows and was ready to tailor it, I was asked, how to create a booking for a real-life course. Umm, what? The original premise was all courses are on-line! “No, we already have a client, who wants to do a real-life courses”, the manager said.

So I tried to customize PrestaShop to include dates for that, but the integration was too complex, with double-nested entities. E-shop is simply not a reservation system.

Therefore I proposed I'll use Qedy to create a custom reservation system instead, which will dub as an e-shop as well. They understood there's no other way, so they agreed.

In the following months I worked more closely with the management and on almost every weekly meeting they either altered the specification, described the system in the way I heard numerous times before, or asked for a feature which was out of scope.

I started to understand, why those guys didn't deliver.

Thursday, May 25, 2017

Japan

On our travels in Japan and especially during preparation of our thorough itinerary I noticed Japanese websites look at least a decade behind “western” site styles and technology.

Many styled texts are in a picture, like we did before CSS2. They often use just a single font face – MS PGothic, which became a staple of a Japanese website for me.


But because we fell in love with Japan, I decided to ditch my former decision to not support non-latin languages in my apps. In Japan they have staggering four alphabets: kanji, logographic characters borrowed from Chinese, hiragana and katakana, two syllabic scripts (“kana”) and rōmaji – romanized Japanese.

  • English: Japan
  • Kanji: 日本
  • Hiragana: にほん
  • Katakana: ニホン
  • Rōmaji: Nihon / Nippon

Room to grow web apps

※ reference mark, using tilda to mark from-to, esp. in times. 7~23 (seven-eleven)

Thursday, July 28, 2016

My dev curses

From my posts so far you can already see some of my developer curses. 

#1

The first curse is I want to have a control over my software experience, which either means the program has to be highly customizable, or if the task is somehow simple, I want to create the program myself.

Sometimes I'm only curious, how hard can it be, but even I usually learn a lot during the process, it also cost a lot of time. Also I'm that kind of guy who if wants a bread, he doesn't go to bakery, but opts for wheat seeds and learns how to mill.

Obviously I don't have much spare time, because if I'm not experimenting, I'm working, only because I persuaded somebody to use some of my unfinished creations (which looked quite finished to me before the pitch).


#2

The second curse is I'm a “forker”. I like to start new projects, but I don't have the endurance to deal with the hard stuff afterwards. As a result, most of them remain unfinished, also because I often treat them more like an academic endeavour and I prefer to have everything thoroughly thought thru, than glue it somehow together.

I like starting new projects also because in the beginning everything is small and simple and I like that. After a year of development the source code is huge and bloated, with technical debt here and there, so it gets messy and I start to lose motivation to work on such project any longer because of it.

It's the well-known Pareto rule of 80:20. After I finish the 80 % of work that require 20 % of time, that's it for me. I'd love to have somebody else to pick up the task right there and finish it.

When dealing with difficult problems, that requires a lot of time and effort, I have a tendency to procrastinate. Other times I figure out a better way how to do it during the development, so my motivation shifts to reengineering and hey – new project! Tada!

When I did a roadmap for Quiky, it was quite nice, but it wasn't effective enough. I created the WPF version, which I still heavily use, but my needs exceeded what was easily achievable and now I'm in the unfinished state once again, currently because I'm having hard time syncing changes between the app, a server and a mobile version.


#3

The third curse is I'm a performance freak, I want my code as much microoptimized as possible. Last year's ECMAScript 2015 (ES6) added great new features, but in most cases it's just a syntactic sugar, that in general is slower, than older constructs (as performance tests are showing).

Array.forEach is slower, than plain for loop; array.push(x) is slower, than array[array.length-1] = x; promises looks slower, than callbacks; classes and modules have bigger overhead than plain functions.

I also order clauses in IF statement, so the fastest one is evaluated first, and I prefer OR over AND, because while in AND all clauses are evaluated, if one OR clause evaluates to false, it skips the rest, saving some CPU ticks.

#4

This goes hand in hand with my dislike of various third party frameworks, which in fact may be my fourth curse. But it makes me furious to see how some other devs mash together tens or even hundreads of packages and libraries, without much thought about performance and amount of data the page will need to download and process in order to work. I saw a project that combined Angular, React, jQuery and Underscore. The final bundled JS script had over 10 MB minimized. Running that on a phone, it would make it a nice heater, but only for a few minutes, until the battery runs out.

#5

And finally, my fifth curse is, that my brain is for whatever screwed up reason wired in the way I'm keeping my code compatible with legacy versions of the runtime.

It's maybe because some of our customers still use IE11 (company policy), as well as some of my WinForms programs use WebView, which is also powered by IE11.

In PHP I still retain backward compatibility with 5.X as much as possible, maybe because many shared environments I have to run my apps in still use PHP 5.6 or even 5.4.

I internally struggle to get on a bleeding edge, despite it offers way better programming experience most of the time. It's like I expect some new device will be powered by [insert_platform_name], but only with limited set of features. This may be remnants of my long term “relationship” with .NET Compact Framework, which was pretty much exactly that.

Saturday, May 14, 2016

Idea – Test – Code – Post

My usual life cycle of a new feature or even a whole new product is usually I analyze what I came up with, how it should work and what benefits it should bring or what issues it should solve.

Then I write tests for all the cases, even edge ones, which helps me to sort my thoughts about the code and the functionality itself. What I like about TDD is, that during writing all the test cases I have more time to think about it, so sometimes I find improvements for the idea or, on the other hand, a dead end.

Then I write the code, trying to fulfill all the tests I wrote. This was helpful in particular when testing QPage.parsePath, which has quite specific behavior in certain situations.

Finally, if I encounter something interesting and worth sharing during the process, I write a blog post about it. Sometimes writing the post takes more time, then the coding itself, especially if I want to create illustrations for it, which is why there mostly aren't any :-)

Idea – Test – Post – Code

Sometimes it's hard to make the code, so writing a blog post about it may help to sort out the thoughts. So the last two steps in the process may get switched.

Friday, March 28, 2014

My dev beginnings

We got our first family computer on Christmas 1994. It was 486DX2 50 MHz with 4 MB RAM and 260 MB HDD, running DOS 6.22. In 1996 my older brother showed me QBASIC and I started to learn how to create a simple text game.

Later I upgraded to QuickBasic, which was able to compile to EXE.

Pascal, TurboVision

Video Memory - read box under sprite, draw sprite, put box, draw sprite on a new location. Double buffering

Created my font with added diacritics, text game with speech synthesis

Mouse, PCX, SVGA, DOS4GW

C++

PHP

C++Builder

Vypínač, Teploměr, Diskmag, Servant

Train Station announcement, Speech (slabiky)

Delphi at high school just for fun

C# in SharpDevelop