HNHacker News
TopNewBestAskShowJobs

bjarneh

1,777 karma · joined November 11, 2016

who cares
submissionscomments
bjarneh··on So I took a corporation to arbitration
> Of course, they refused to pay. Trying to find someone at HWC who could show an iota of free-will and thinking was hilarious and impossible.

This always annoys me; a 100 sellers for every person working in any type of customer care/support role seems to be the norm. If you can actually get in contact with someone in customer care/support their job always seem to be to brush you off nicely, not really help you.

bjarneh··on WTFPython: Exploring and understanding Python through surprising snippets
Those two strings aren't equal though, missing some spaces in b :-)
bjarneh··on WTFPython: Exploring and understanding Python through surprising snippets
Luckily you don't typically compare numbers in Python with 'is'. In Java you should not compare Integer objects with '==' either of course, but '==' is typically used with numbers, and the auto-boxing features of Java makes it very easy to shoot your self in the foot with this stuff.

I once ran into a bug which had been there for years, since some Integer values had never crept over that magic limit, and auto-boxing allowed the numbers to be treated as int's all over, so it really took me some time to figure out what was going on...

bjarneh··on WTFPython: Exploring and understanding Python through surprising snippets
That Python uses the exact same string if they contain the same immutable content can probably be a bit confusing. But if you want truly confusing behavior look at how Java treats numbers wrapped in their object type:

     public class Main{
 
         public static void main(String[] args){
 
             Integer a = 300;
             Integer b = 300;
 
             System.out.printf(" %s == %s: %s\n", a, b, (a == b));
 
             a = 100;
             b = 100;
 
             System.out.printf(" %s == %s: %s\n", a, b, (a == b));
         }
     }


     // output

     300 == 300: false
     100 == 100: true
When combined with Java's auto-boxing, this can create some serious confusion
bjarneh··on Logging C Functions
I visit that URL to feel like an idiot.
bjarneh··on Introduction to Microsoft Excel (1992) [video]
> this might be as good as business projections get

It almost seems like weather reports. Anyone can make a good short term forecast by looking out the window, but the amount of complexity, uncertainty and variables going into a long term forecast makes them almost pointless. Which is where Excel comes in I guess :-)

bjarneh··on Introduction to Microsoft Excel (1992) [video]
I think that's exactly how most business projections are made...
bjarneh··on Cities with Nice Weather
Also Iceland/Reykjavík in the top ranking makes me agree with you. I went to school with a girl from Iceland and she told me school was cancelled on days with nice weather in Iceland.

A location where every sunny day becomes an instant holiday shouldn't end up at the top of a list like that. Cool website and demo of R nonetheless I guess.

bjarneh··on Short URLs: Why and How
If those hierarchical directories actually work, i.e. http://example.com/blog/2022/05 actually lists blog entries written in May 2022, I'd certainly prefer that to this type of "optimization".
bjarneh··on Bugs that the Rust compiler catches for you
Thanks for the explanation. I guess most languages need this feature i.e. fail anywhere below this call, then return the type error + where it occurred + a stack trace. I've even heard of people doing stuff like that in C, where they store the stack trace in a list they populate and return errors as part of the same struct, in order to have something similar to exceptions.

I have to say I really enjoyed Rust when it was in its infancy (version 0.1 - 0.2 or thereabouts), but have since fallen off. It used to be so simple and so clean, and unlike anything else. Today it's just way to complex for me :-)

bjarneh··on Bugs that the Rust compiler catches for you
> The survival of the entire process is not a decision to delegate to every possible line of code or library author.

Stated like that, who can really disagree?

I remember when I was writing a bunch of Go when the language was still very new (2009 - 2011). One of the most popular use cases for the language was making websites. All sorts of unexpected problems caused the entire website to go down, due to unexpected panics here and there. The suggested solution from the Go team was to just restart the web-server whenever it was killed by a panic. Surely that cannot be the best way to do it..

bjarneh··on Bugs that the Rust compiler catches for you
OK, I'm not into Rust. It just seems a bit too complicated :-)
bjarneh··on Bugs that the Rust compiler catches for you
> it is easy to be a cause of error and just throw the exception, then expect up the stack to handle it.

Agree, this can happen. Perhaps the bad attempt at fixing this in Java for instance - checked exceptions, made people dislike exceptions ever more. The caller "has to handle" the exceptions or re-throw them of course. Even though RuntimeException's can come from anywhere at anytime, so "guard" provided by checked exceptions just made a complete mess of things. People are lulled into thinking that methods without the 'throws BlaBlaException' signature are safe and so on.

I guess no language is 100% on everything, but I've always felt that exceptions are one thing I really like; especially when a language manages to do them correctly.

bjarneh··on Bugs that the Rust compiler catches for you
Wasn't this argument used all the time by the Go community. I.e. only use panic when you intend the program to halt, and handle all potential problems with the Error type.

I think Rob Pike even said it's easy to see where a program fail in one of his talks?

But to me the superb thing about exceptions, is that error handling can be done where it makes sense. I.e. we can try{ problem-code }catch(problem){ handle problem } in a single location. Otherwise we end up peppering the entire code base with a ton of error checking far down the call stack, where we really cannot do much about the problem anyway (unless we are writing command line tools where error handling is just writing the problem to stderr).

Exceptions gives us a nice way to let problems bubble up to the surface, while also stating what the problem was, and where it occurred. That is great IMO.

bjarneh··on 100-year-old Brazilian breaks record after 84 years at same company
> On 17 January 1938, Walter Orthmann started work as a shipping assistant when he was fifteen years old at a textile company in Santa Catarina

Hard to wrap your head around someone working at the same place from before 2. world war. Both him and his employer must have been quite good at adapting to a changing business landscape.

bjarneh··on A Gentle Introduction to SSR
We need to find another term for this (Server Side Rendering = SSR). SSR is starting Firefox on a server with X-forwarding or something. How is producing a complete HTML document on the server = rendering? Then PHP has been rendering webpages for years.

Offloading the actual rendering-engine from gluing together the HTML document from parts fetched or produced by Javascript prior to actually rendering the webpage can probably be a good idea in some instances. But this is hardly a new technique. Using Javascript to do it doesn't make it something different than PHP or the good old CGI scripts in Perl/Python.

bjarneh··on Using QGIS to apply a 1777 style to today's OpenStreetMap data
Superb website, very cool!
bjarneh··on Show HN: How did I live without Pipe Watch?
This is super handy. I've often found myself 'tail'-ing logs to 'grep' to filter out stuff; pw makes that process 10 times better. Very cool.
bjarneh··on Venmo forces binding arbitration unless you opt out by mail before June 22
> When you initially agreed to the TOS, there was a clause that said Venmo/PayPal can modify the terms whenever they want

That is the thing which really should be illegal. It doesn't even make sense. You agree to terms that we can be modified any time they want? What are you even agreeing to with a contract like that?

bjarneh··on I decided to move away from big tech for my children and myself
Of course he will, he will also review it with his own parents in order to win back their trust.
bjarneh··on I decided to move away from big tech for my children and myself
He says him and his kids are going to "review it together" until they earn his trust, sure sounds like fun.
bjarneh··on I decided to move away from big tech for my children and myself
> that they would have full access to the monitoring and we would review it together.

Can you imagine your own parents asking you for the same (at any age)?

Perhaps it's not technically spying when they know they are being monitored or spied on, but it's not something better...

We always discuss power abuse in terms of corporate bosses, politicians; but parents seem to abuse their power very frequently. Almost everywhere I've worked most of my coworkers have had exactly this attitude. I.e. that they can spy on their kids (cell phone/iPad/computer), or invade their privacy in all sorts of ways, and they always do this to protect them of course, so nice of them. If it were to happen to me, I'd be leaving home as soon as possible at least - and I don't think I'd come back to visit.

bjarneh··on I decided to move away from big tech for my children and myself
> I may or may not go as far as putting a custom cert on the phone so I can monitor all the traffic -- that will depend on if I catch them violating my trust.

You are going to spy on you kids if they violate your trust, what does it take to violate your trust; visit a website that you don't like? How will your kids ever trust you again, if they find out you're spying on them for possible trust-violations?

bjarneh··on What software engineers can learn from the rapid collapse of Fast
> No-one needs that kind of money.

I'm currently renovating an old house, I certainly need it :-)

bjarneh··on A project with a single 11,000-line code file
I worked one year with "accounting software". The single-file-VBS-approach was almost all I ever saw. Anyone who knows anything about software development quits, and those who don't stay there and fiddle more with the incomprehensible 11.000 line VBS script to try to figure out why nobody born before 1981 didn't get their salary paid out last month...
bjarneh··on Apple's whitelist of the 250k auto-completable domains in iOS
zombo.com is there :-)
bjarneh··on Finding Waldo in π
Another victory for PIFS:

https://github.com/philipl/pifs

bjarneh··on Stage win: FinFisher is bankrupt
> to build a post-and-beam house from scratch

Sound like fun, and you shouldn't let age stop you from doing that. Instead you should adjust your dream to building a smaller post-and-beam house. It's not back breaking work if it's a small house; our inner cave men wants to work with timber for some reason.

bjarneh··on 2022 World Cup Ball: Al Rihla
> This is a stunning, sustainable and high-quality Official Match Ball from adidas

The only thing about this whole tournament which is sustainable I guess...

bjarneh··on Stage win: FinFisher is bankrupt
> 'a small spot of rot'

is similar to "a small spot of rust" I guess, there is no such thing :-)

Fascinating to see how these old tree constructions are made. I still find it hard to comprehend that a few bricks and some timber logs are all that separates me from living directly on the dirt like a cave man..

← PreviousPage 5 of 16Next →