4 ms·
Naming things - one of the four hardest problems in computing (the others are sorting and off-by-one errors) :)
by loloquwowndueo 6y ago
Naming things - one of the four hardest problems in computing (the others are sorting and off-by-one errors) :)
- jwdunne 6y agoLooks like you need to invalidate your cache of hardest problems in computing ;)
- amelius 6y agoProper caching makes any problem 10x as hard.
- athrowaway3z 6y agoTwice as hard is a underestimate imo.
- GuB-42 6y agoTwice as hard? Or is it three times? Like they say, there are 10 kinds of people, those who understand ternary, those who don't, and those who mistake it for binary.
- froh 6y agofive... naming, sorting, of by one concurrency errors and.
- fiddlerwoaroof 6y agoI see a transaction rolled back, and the autoincrement id column no longer matches the row count.
- mod 6y agoWell, the app is broken now because we relied on the autoincrement id column never having a missing value and didn't handle the error when it has one missing.
- karmakaze 6y agoSorting actually isn't one, at least anymore. Exact once and in-order delivery although part of 'distributed' computing should be, since most computing is distributed, right down to our multicore processing hardware.
- loloquwowndueo 6y agoIt is - do your sorting, then show the results to stakeholders and you’ll see they all want different, mutually conflicting sort orders.
- ravenstine 6y agoDon't forget time comparison. Your unit test of a function comparing dates relies on server time and usually fails if run around 12pm. Whatever. Nobody uses this app around lunch time anyway. Just tell your teammates in the to ignore that. Wait, why is the test failing every time today?! Did we just switch to DST? Uh oh...
- papito 6y agoThis has to come with a trigger warning.
- fiddlerwoaroof 6y ago“Our JavaScript date library and the date library we’re using in Clojure disagree on the first day of the week. Elasticsearch disagrees with both too”
- emodendroket 6y agoYou can avoid this problem by always passing in either a time or a time provider and never just relying on Time.now or whatever it is your language provides.
- fiddlerwoaroof 6y agoThis. Nearly every date/time library comes with this sort of attractive nuisance that is just waiting for a chance to ruin your day.
- gavinflud 6y agoFunnily enough, I recently had to help with an issue where a company's payment screen was not loading correctly and instead displaying "Invalid session". They use a third-party vendor to handle payments and display their payment form in an iFrame on their website. There is an initial request to create a session that has to pass the desired expiration time of the session. Unfortunately, the vendor requires the time to be in Eastern Time. The poor, naive soul that originally implemented this just got the current date, added 15 minutes, and converted it to "EST". As soon as daylight savings hit a few weeks ago, the expiration time was automatically being set to 45 minutes in the past, the vendor was responding with "Invalid Session" and the company was unable to take payments from customers.
- netflixandkill 6y agoDiscussions about naming schemes make me think of the old joke "until I got married, I had no idea there was a wrong way to boil water" or other variations of banal tasks :) Perhaps there is an answer lurking out there in the universe, but it feels more likely it'll only be invalid pointer Aborted (core dumped)
- mmmd 6y agoHonorary mention: Copy/Pass by reference or value