Readit News logoReadit News
hackthemack commented on Kernighan on Programming    · Posted by u/chrisjj
PinkSheep · 7 days ago
Follow-up questions: Do you test manually? Why? Do you debug manually? Why?

You wanted examples: https://github.com/openjdk/jdk/tree/master/test/jdk/java/uti...

hackthemack · 7 days ago
I do test manually in salesforce. Mainly its because you do not control everything and I find the best test is to log in as the user and go through the screens as they do. I built up some selenium scripts to do testing.

In old days, for the kinds of things I had to work on, I would test manually. Usually it is a piece of code that acts as glue to transform multiple data sources in different formats into a database to be used by another piece of code.

Or a aws lambda that had to ingest a json and make a determination about what to do, send an email, change a flag, that sort of thing.

Not saying mock testing is bad. Just seems like overkill for the kinds of things I worked on.

hackthemack commented on Kernighan on Programming    · Posted by u/chrisjj
agentultra · 7 days ago
So is reviewing and verifying code. Maybe not twice as "hard" if you're skilled in such things. But most programmers I've worked with can't be bothered to write tests let alone verify correctness by other means (good tests, property tests, types, model checking, etc).

It's one thing to point out small trivialities like initialization and life time issues in a small piece of code. But it's quite another to prove they don't exist in a large code base.

Kernigan is a good source of quotes and thinking on programming.

hackthemack · 7 days ago
I am fascinated by the prevalence of wanting "tests" from hacker news comments. Most of the code I have worked on in the past 20 years did not have tests. Most of it was shopping carts, custom data transformation code, orchestrating servers, plugin code functionality to change some aspect of a website.

Now, I have had to do some salesforce apex coding and the framework requires tests. So I write up some dummy data of a user and a lead and pass it through the code, but it feels of limited value, almost like just additional ceremony. Most of the bugs I see are from a misconception of different users about what a flag means. I can not think of a time a test caught something.

The organization is huge and people do not go and run all the code every time some other area of the system is changed. Maybe they should? But I doubt that would ever happen given the politics of the organization.

So I am curious, what are the kinds of tests do people write in other areas of the industry?

hackthemack commented on Kotlin's rich errors: Native, typed errors without exceptions   cekrem.github.io/posts/ko... · Posted by u/todsacerdoti
jpalepu33 · 17 days ago
The discussion around checked vs unchecked exceptions always comes down to ergonomics vs safety.

Having worked extensively with Node.js (callback hell, then Promises), I appreciate how error-as-value patterns force you to think about failure cases at every step. But the reality is most developers don't - they either:

1. Ignore the error case entirely (leading to silent failures) 2. Bubble everything up with generic error handling 3. Write defensive code that becomes unreadable

Rust's Result<T, E> with the ? operator found a sweet spot - you have to acknowledge errors exist, but the syntax doesn't make it painful. The key innovation is making the happy path concise while forcing acknowledgment of errors.

For Kotlin specifically, I'm curious how this interops with existing Java libraries that throw exceptions. That's always the challenge with these proposals - they work great in greenfield code but break down at library boundaries.

The real question: does this make developers write better error handling code, or just more verbose code? I'm cautiously optimistic.

hackthemack · 17 days ago
Similar thoughts.

One thing I notice in enterprise java software that I have to reed through and update, is that too many times, every developer just wraps everything in an exception. I do not have vast insight into all java code, everywhere, but in my little corner of the world, it sure looks like laziness when I have to dig through some ancient java code base.

hackthemack commented on Radicle: The Sovereign Forge   radicle.xyz... · Posted by u/ibobev
lorenzleutgeb · 17 days ago
Right. Radicle nodes out of the standard distribution would be kind enough to delete. On the technological level you cannot do more (also not really less, funnily enough). But it would be possible to patch the code and remove deletion.

Often times I just take the "information theory perspective": You fundamentally cannot make something "more private". Once it's out, it's out. You cannot "untell" a secret. That's just not how it works.

But then other solutions also have this problem. Once I have `git fetch`ed from GitHub, or received that e-mail containing a patch on a mailing list, I have a copy on my filesystem. It's going to be pretty darn hard to remove it from there if I don't comply. Maybe you'd have to enforce some law.

In that context, it seems that people were led to believe that "removal from the server(farm)" is the same as "removal from the universe", but that's just not true.

Happy for any insight on how to approach this differently.

hackthemack · 17 days ago
I am just glad some thought is being put into it. Thanks for the efforts.

I keep thinking about people putting secrets up in github. You can not really get rid of something that is out there, like you said.

But people do make a request to github to remove it. And if no one has put in the effort to copy it and republish it, it is not as "out there" as if it were still on github.

Thinking on old BBS boards on the internet. Most people will use Internet Archive to search for old dead sites. If it is not on there, it is not as "out there" as if it were on the Internet Archive.

I am thinking it is not quite as black as white as it seems. There is some kind of entropy effect.

Thinking on pre-internet newspapers. If you posted something in a fan zine in the 70s, it might have faded from existence due to lost copies, or it might be in some collector's stockpile. It might even be scanned into the Internet Archive. Or not.

No great solutions come to mind. But there does seem to be some "small" value in being able to say, delete this as it was a mistake.

Maybe, also, more education, or a warning about "beware, be extra careful, this is going to be around for all to see for a long time, possibly forever".

hackthemack commented on Radicle: The Sovereign Forge   radicle.xyz... · Posted by u/ibobev
hackthemack · 17 days ago
I hang out with a small group of sysadmins who like to spin up the old internet stuff, like irc, gopher.

And that got me to thinking about Usenet and how a ton of software (usually pirated) and images (usually pornography) were posted to it.

And people often posted stupid stuff they said (usually because they were young and dare I say afflicted by a moment of dumb).

I think one of the problems with p2p distributed systems is how do you handle "mistakes". Things you want deleted.

What if someone accidentally posts their address and phone number?

What if you post a communication system with encryption methods, but then the government passes a law that is criminal? Maybe in some regimes that puts you on a list for arrest? Look at what is happening with HAM radio operators and Belarus...

https://www.niemanlab.org/reading/ham-radio-operators-in-bel...

To me, none of this raises above the idea that distributed p2p content should not be used. It is just that it has some issues.

Also, unrelated, but I think the plethora of "How does this compare to XYZ" type comments are not very helpful. It is too easy to write that kind of post, but much harder to answer.

hackthemack commented on FreeBSD   docs.freebsd.org/en/books... · Posted by u/vermaden
dev_l1x_be · 19 days ago
We need to say goodbye to the unix philosophy. From the security point of view there are much better options. Also text based tooling is cumbersome compare to the alternatives. We should aim higher than just the cathedral approach of unix alternatives.
hackthemack · 19 days ago
Like so many things in life, there are so many variables/criteria and different ways to weigh them that I do not think one can make a claim like "text based tooling is cumbersome compare to the alternatives".

What are the alternatives? I had to do a little windows shell programming when working on Chef orchestration to set up windows servers.

There was "flow" programming in WebMethods I had to work on that tried to provide a snap in place component GUI to program data transformation.

I would say that there is something limiting in all the GUI based interfaces I have had to work with. Some option you can not get to, or it is not apparent how two things can communicate with each other.

Text based options have always seem more open to inspection, and, hence, easier to reason about how it works. YMMV.

hackthemack commented on Command-line Tools can be 235x Faster than your Hadoop Cluster (2014)   adamdrake.com/command-lin... · Posted by u/tosh
wccrawford · 22 days ago
I've spent my last 2 decades doing what's right, using the technologies that make sense instead of the techs that are cool on my resume.

And then I got laid off. Now, I've got very few modern frameworks on my resume and I've been jobless for over a year.

I'm feeling a right fool now.

hackthemack · 22 days ago
I have hung on to my job for many years now because of being in a similar situation in regards to trying to do the right thing and the fear of not being hire-able.

There is something wrong with the industry in chasing fads and group think. It has always been this way. Businesses chased Java in the late 90s, early 00s. They chased CORBA, WSDL, ESB, ERP and a host of other acronyms back in the day.

More recently, Data Lake, Big Data, Cloud Compute, AI.

Most of the executives I have met really have no clue. They just go with what is being promoted in the space because it offers a safety net. Look, we are "not behind the curve!". We are innovating along with the rest of the industry.

Interviews do not really test much for ability to think and reason. If you ran an entire ISP, if you figured out, on your own, without any help, how to shard databases, put in multiple layers of redundancy, caching... well, nobody cares now. You had to do it in AWS or Azure or whatever stack they have currently.

Sadly, I do not think it will ever be fixed. It is something intrinsic to human nature.

hackthemack commented on Jensen: 'We've done our country a great disservice' by offshoring   barchart.com/story/news/3... · Posted by u/alecco
hackthemack · a month ago
Ross Perot in 1992

https://www.youtube.com/watch?v=VRr60nmDyu4

We have shipped millions of jobs overseas, and ... a strange situation, we have a process in Washington where after you serve for a while, you can cash in, become a foreign lobbyist.

We have got to stop sending jobs overseas.

You're paying 12, 13, 14 an hour for factory workers and you can move your factory South of the Border, pay a dollar an hour for your labor, have no health care. That's the most expensive single element making a car. Have no environmental controls, no pollution controls and no retirement and you don't care about anything but making money.

There will be a giant sucking sound going south.

hackthemack · a month ago
Side point about this HN post "Jensen: 'We've done our country a great disservice' by offshoring" currently 3 hours and 129 points

Why does it seem like it is getting pushed down relative to other posts that have less upvotes and with longer times?

Here are some posts that are currently higher ranked.

https://news.ycombinator.com/item?id=46445412 currently 8 hours and 82 points

https://news.ycombinator.com/item?id=46465493 currently 4 hours and 29 points

https://news.ycombinator.com/item?id=46497589 currently 5 hours and 82 points

It does not make sense unless some force is pushing the Jensen post down, or the other posts up?

hackthemack commented on Jensen: 'We've done our country a great disservice' by offshoring   barchart.com/story/news/3... · Posted by u/alecco
hackthemack · a month ago
Ross Perot in 1992

https://www.youtube.com/watch?v=VRr60nmDyu4

We have shipped millions of jobs overseas, and ... a strange situation, we have a process in Washington where after you serve for a while, you can cash in, become a foreign lobbyist.

We have got to stop sending jobs overseas.

You're paying 12, 13, 14 an hour for factory workers and you can move your factory South of the Border, pay a dollar an hour for your labor, have no health care. That's the most expensive single element making a car. Have no environmental controls, no pollution controls and no retirement and you don't care about anything but making money.

There will be a giant sucking sound going south.

hackthemack commented on IPv6 just turned 30 and still hasn't taken over the world   theregister.com/2025/12/3... · Posted by u/Brajeshwar
hypeatei · a month ago
So... just a less ambitious IPv6 that would still require dual-stack networking setups? The current adoption woes would've happened regardless, unless someone comes up with a genius idea that doesn't require any configuration/code changes.
hackthemack · a month ago
Sort of. I think people would understand

201.20.188.24.6

And most of what they know about how it works clicks in their mind. It just has an extra octet.

I also think hardware would have been upgraded faster.

u/hackthemack

KarmaCake day521December 10, 2018View Original