Live data from Hacker News

My 20 year career is technical debt or deprecated

blog.visionarycto.com

381–390 of 585 posts

Re: My 20 year career is technical debt or deprecated

#381
post #358

Earlier quoted context omitted.

> And most devs hating on Java are using an IDE written mainly in Java (all the JetBrains ones): the irony of that one gives me the giggles. Guilty as charged! I hate using Java because everything written in java seems to blend into the same indistinguishable swamp of classes with meaningless names, full of methods that constantly find new and interesting ways to obscure what your program is actually trying to do. De…

I've spent most of my programming life working in OOP. I see people critical of it, but I don't know what the alternative is for the kind of stuff I do for my job (not to say I have a choice in changing how we do it). Does anyone know of an open source project that implements a complex GUI app that doesn't use OOP so I can see what that code can look like?

We even use OOP in Javascript today, although capsulation is still a but sketchy and there is no support for interfaces and abstract classes. There is support for interfaces in Typescript, which was added because, well, it makes a lot of sense :)

Re: My 20 year career is technical debt or deprecated

#383

Earlier quoted context omitted.

> And most devs hating on Java are using an IDE written mainly in Java (all the JetBrains ones): the irony of that one gives me the giggles. Guilty as charged! I hate using Java because everything written in java seems to blend into the same indistinguishable swamp of classes with meaningless names, full of methods that constantly find new and interesting ways to obscure what your program is actually trying to do. De…

Do you know of any well written articles of critique against OO? I've read a few against Clean Code, that actual went over the problems with the actual examples given. Nevertheless I hardly ever see good critiques against the principles themselves. I'd be interested in reading about it in more detail.

In my mind there are two major issues with java/c# style OO.

1) Subclass universality isn't great for cognitive comprehension

2) Subtyping component of subclassing has no compiler enforcement

Okay, for the first point, consider the universal NAND gates. You can build any circuit that uses not, or, and etc logic gates by converting it into only nand gates. This is great for manufacturing (I guess) where you can 'compile' a straightforward series of logic gates into just nand gates and then you only need to product one kind of gate in your hardware. However, imagine if you needed to program this way (say with an imaginary nand (!&) boolean operator):

  today || tomorrow => (today !& today) !& (tomorrow !& tomorrow)
Yeah ... just rolls off the tongue.

Now, subclassing (and interfacing) provides an existential (to borrow from logic) property. That is, there exists some class such that the following methods exist (and maybe there's also some default implementations spread out amongst every super class in the inheritance hierarchy, but focus on the simple case).

Existential is also universal. You can use it to simulate a forall property (think generics), an or property, or an existential property. The problem is that now you're converting what would be a straightforward structure in a more fully featured language (like unions, or ADT, or Sum types, or discriminated unions) of This thing OR That thing into something much more complicated. It might be an infinite number of things which delegate logic that should exist right here into some other class someplace else where you cannot see it without difficulty or maybe cannot see it at all.

Or you can just cast the super class into a sub class ... which isn't great either.

Regardless, you also have to hope that nobody goes off and implements another case that shouldn't exist because subclassing is open where an OR property in something like discriminated unions is closed. Knowing you have all of the cases considered nigh impossible.

Now, this is good when you straight up want an existential property. It does happen that you get a thing and then you call a method on that thing and there really are an infinite number of things that it could potentially be both now and in the future such that you want support for that behavior. However, I assert that this requires much more complicated and careful coding and isn't applicable for most of the work that ends up needing to occur.

Part two is a bit more simple. When you subclass you're also declaring a subtype. The problem is that there's no compiler support or assistance to ensure that all subclasses are actually valid subtypes of the superclass. But it's a property that you get whether or not it's true.

So at any point in time you can have some object where you aren't supposed to know it's actual class, but for which if you don't know it's actual class you'll end up writing incorrect code. A superficial example can be had with exception (a whole other topic that will otherwise not be covered here). Imagine a Storage class which is just a key-value store. The CloudStorage class can throw NetworkExceptions, the InMemoryStorage class can throw OutOfMemoryExeptions, and the FileStorage class can throw FileNotFoundExceptions. Code that handles just Storage doesn't know which exceptions it might have to make sure it catches. The subclass isn't necessarily a subtype. [Of course you can open up a different discussion here about the appropriate way to handle exceptions, but I hope the simplified example here makes clear what the issue is. A more complex and realistic example can be constructed to show the same issue in a way that completely bypasses exceptions.]

Re: My 20 year career is technical debt or deprecated

#384
post #196

Earlier quoted context omitted.

Who are the people who belong to "I hate Java" and "I love Jira" sets? I'd love to see that Venn diagram.

Do people who loves JIRA exist for real?

Worked at AAA game developer. They had shit ton of custom workflows build on top of JIRA.

Imagine you want to add a weapon to the game. With one click you could generate 100s of tasks for all the related stuff. It touches pretty much all the game. This is very very incomplete list for what Jira created tasks:

- concept, 2d, 3d art

- sounds, and there's quite a bit of them: just gun sound, reloads, impact on different surfaces etc

- animations - this is a large one

- writing: for example, background info on the weapon

- gameplay design: how the gun fits into the game

- world design: where the gun can be found, who (some fraction?) uses it

- quest design: maybe the gun is a reward in some quest, or is used in a particular way

- balance

- obviously, programming for all the above

- and even more obviously, testing all of the parts.

And that's one workflow. You had those for many parts of the game.

Re: My 20 year career is technical debt or deprecated

#385
In the future there won't be any technical debt. You were lucky to live early.

Code, most code, will eventually turn into some sort of sanitised applied maths corpus (with a heavy overlay of "AI" analytical tools).

In applied mathematics you have cultural obsolescence (stuff that we no longer find interesting or relevant, like an asymptotic formula for the Airy function [0]) but the corpus is intrinsically add-only. Once something is solved it does not have be solved again. Its essence is eternal, so to speak.

Think about code development in such as mature state. It will mostly work by pulling together (using AI prompts) logical units from the future version of Rosetta [1].

When we get to that stage it will be hard to add something truly new. Just like it takes a long incubation and a PhD to add some marginal new thing to applied mathematics, it will take effectively trained applied mathematicians to add something minor to the evolving code corpus.

Coding for the common folk will be mostly compositing. It might be productive and even fun, but not quite the same.

We lived through a period of widespread democratization of development. Cherish the freedom of reinventing the wheel in countless flawed ways :-)

[0] https://en.wikipedia.org/wiki/Airy_function

[1] https://rosettacode.org/wiki/Rosetta_Code

Re: My 20 year career is technical debt or deprecated

#387

Earlier quoted context omitted.

It's because conservatism whether big or small c, political or technological, tends to be seen as standing in the way of progress by those who didn't arrive at the same underlying intuitions about the difficulty of tabula rasa development. Because the intuitions are so deep, we barely articulate them and that leads quickly to misunderstandings. Conservatism can easily be perceived as errant obstructionism or even the…

Steven Colbert once jokingly said, "Reality has a well known liberal bias". It should probably be the other way around, that liberals have a reality bias, but it doesn't quite land. Liberalism is based on what can be proven. Especially in science, starting with some preconceived reservations leads to inaccurate models. If you can't articulate it, all the worse. Even things like categorization and taxonomy can't accou…

Trying desperately to stay on technical topic here, I'd say the only places where this dichotomy comes up are in cases that are inherently ambiguous and subjective. If something is genuinely proven then everyone does actually accept it. Conservatives and liberals don't disagree on the energy of an electron or the color of the sky. Disagreement occurs over things that can't be proven: how valuable is spending time on feature X instead of rewrite Y? Is this choice of library really "debt" that needs to be paid down by rewriting, or is it a mature tech whose imperfections should just be accepted as an inevitable part of life? If you rewrite, how likely is the project to create new problems at the same time as solving old ones? How can anyone prove such a thing one way or another ahead of time? It will ultimately always boil down to a complex interacting set of intuitions and experiences which vary between people.

The Colbert snark is illuminating because it gets to the nub of the conflict. It's an attempt to claim that reality, something often ambiguous and subjective, as if it was simple and obvious. Look at how straightforward the world is to comprehend - why, all you need is a few nice and neutral academics who do a few studies, write it all down in a model and you're done! Now you know what everyone, everywhere should be doing. Others look at this aghast and say no, that approach has a history of going spectacularly wrong. The model did not match reality and disaster followed.

In the software space it leads to conservatism of the Joel Spolsky "never do rewrites" variety. That's too strong, but it's a famous and widely cited essay even 20 years later because it represented a rare articulation of the value of conservatism in technology along with clear real world examples of cases where the lack of it led to (commercial) disaster. Fortunately, attempts to rewrite Navigator or Word only led to financial disaster and only for specific companies. When attempts are made to rewrite society instead of software the cost of failure is drastically higher.

Re: My 20 year career is technical debt or deprecated

#388
post #260
post #164

That's fine. We build code for issues that are here and now. Like most jobs: they answer immediate needs. The small amount of code that's useful for years or decades needs to be built on a stable foundation and with few dependencies. This probably matters a lot more than the code being a bit messy. It should require as little maintenance as possible. I have two pieces of PHP code I wrote more than 10 years ago, in PH…

Same here. I have PHP code in production that dates back to 2008. zero dependencies, a few quirks, it runs on PHP 7.something for now, might upgrade to 8 at some point. It’s ugly, but it gets the job done. Best thing is that front-facing HTML and JS from 10+ years ago still works flawlessly, even though the UI is certainly dated. But I guess that’s the same with HN, where the design never really changed at all and ju…

You do realize PHP 7 is EOL for quite a while now[1]? PHP 8.0 is on security updates only. You might want to upgrade sooner rather than later unless you're paying for backports.

[1]: https://endoflife.date/php

Re: My 20 year career is technical debt or deprecated

#389
post #220

That's like calling a chair you built 10 years ago "technical debt" because it can eventually break. No, it's just a fucking product you made. The fact it has to be maintained doesn't mean it is "debt", it's just like any other asset. You don't get to your car and think "that's technical debt". There is nothing technical about it. It's a tool with maintenance needs. The difference is choosing worse now to get it fast…

I don't understand the need for obscenities. Their are children on this blog.

Re: My 20 year career is technical debt or deprecated

#390

Earlier quoted context omitted.

> And most devs hating on Java are using an IDE written mainly in Java (all the JetBrains ones): the irony of that one gives me the giggles. Guilty as charged! I hate using Java because everything written in java seems to blend into the same indistinguishable swamp of classes with meaningless names, full of methods that constantly find new and interesting ways to obscure what your program is actually trying to do. De…

I've seen people take Bob Martin's concepts and do some truly awful things with it. Mind-bogglingly awful contortions of concepts into classes in arrangements that have to be sourced from demonic inspiration. At the same time, I've seen the best code of my entire life formed from his concepts. Code that will last decades, far outlasting the UIs that feed it data or the databases that will store it. I think the differ…

Your last paragraph is really interesting to me. It obviously makes total sense. Yet, three environment I've used most in my career is Rails which also splits these things into folders by type rather than feature. It's never bothered me. Now I wonder if that because Ruby isn't Java and folders aren't packages or because I'm so very used to it.
Post reply on HN