HNHacker News
TopNewBestAskShowJobs

alblue

1,569 karma · joined November 5, 2013

Java Champion, Eclipse guru, Mac fanatic and occasional fair weather pilot. Blogs occasionally at https://alblue.bandlem.com and writes for InfoQ. Can be found as @alblue on Twitter.
submissionscomments
alblue··on I Made a Self-Quoting Tweet
As I said, the write up was quite interesting, so don’t take it the wrong way! A long read - including the journey taken to get there - can be educational itself (including wrong turns, proof of concepts etc).

The only reason I posted the tweet was because the lede was well and truly buried at the end of the article, and you may have lost some readers’ interest by the time they get there.

You could have started with something like “This is how I managed to post a self referential tweet [link]” which would both bring it up front and centre, as a means to entice readers to find out more.

Sort of like how some TV episodes begin with “[record scratch] You may wonder how I ended up here...” – deadpool is a movie that begins in that way, for example.

For really long posts you might want to have a kind of table of contents that sets up the structure which you can link to parts.

Anyway, don’t take my abbreviated summary as negative; I enjoyed it.

alblue··on I Made a Self-Quoting Tweet
To save people some time, here’s the tweet:

https://twitter.com/quinetweet/status/1309951041321013248

In essence, the approach was:

* Find out what the tweet id is of a recent tweet * Find out what a tweet is shortly after * Estimate the rate of new tweets appearing * Publish a tweet with a reference to a tweet with a now+guess id

The write up is well done and interesting but a little long winded.

alblue··on Flappy Bird in 228 bytes
The comments in the ongoing code golf have got it down to 205 bytes.
alblue··on ‘Why did it take nine hours to go 130 miles in our new electric Porsche?’
It looks like they were unlucky in the number of chargers stops they went to that were either not working or were already occupied.

It does say that they didn’t want to use a 7kw charger because of the time it would have taken to charge it; perhaps it would have helped them if they had.

Most of the stories I have heard of people with electric cars are good, but most charge and drive from home. The motorway network has lots of fast chargers but they are not reliable in terms of whether they are working.

Given the uk wants to end the sale of fossil fuel vehicles in the next 10 years there will have to be a lot more investment in motorway charging spots if they are going to succeed.

alblue··on Boeing’s 737 Max Is a Saga of Capitalism Gone Awry
It is probably pretty safe. The issues that occurred are now widely known about and pilot training will include dealing with an MCAS issue, so an exact repeat is incredibly unlikely.

Although the FAA and EASA have certified the Max as safe to fly again, it will only be for airframes that have had the required modifications to prevent the runway trim and only once operation instead of continuous. They have also allowed the pilots to override by the stick which they weren’t able to do before.

Statistically it’s highly likely that there won’t be any further occurrences of this issue with the 737 Max again.

Depending on when you are doing it may be that the airline won’t have time to train the pilots in which case they won’t be flying it at the start of next year. However I expect that to change over the year and that most 737 Max flights are back in operation by the end of the year, or at least as many as are needed to fly in the reduced circumstances of today’s pandemic.

alblue··on What was it like to be a software engineer at NeXT?
Whoops! Yes, you’re right. I had misremembered its colour depth, but I recall it was bigger than the 256 colors of the VGA displays of the time.

Unfortunately I can’t go back and edit the original post to fix. Thanks for correcting me!

alblue··on Ask HN: Why do some timestamps on HN have a full stop at the end?
It triggers mild OCD reactions for me, since there is inconsistency between the formatting of posts, a bit like missing apostrophes do, and as noted in a sibling comment affects how screen readers cover it.

Perhaps keep it a mod only feature?

alblue··on What Went Wrong with the Libdispatch
The issue is that dispatch needs to know what’s running and to allow for the threads to effectively work with the thread schedule to service dispatch in an appropriate way.

On macOS, the implementation is done in kernel, although there is a front end user library that used to interact with it.

This article, although a few years old, talks about the separation of the parts and goes to explain why it’s not a trivial port to other operating systems.

https://gigaom.com/2009/09/14/apple-open-sources-grand-centr...

alblue··on What was it like to be a software engineer at NeXT?
Sure, but Delphi was released in 1995 as the first version, whereas this was something I was programming in 1992 (and I came late to the party with Nextstep 3).

https://en.wikipedia.org/wiki/History_of_Delphi_(software)

Visual Basic came out in 1991, by which time Nextstep was already at version 2.1

So yes, these things existed, but after Next had demonstrated them.

alblue··on What was it like to be a software engineer at NeXT?
At the time of NeXT’s heyday in the early ‘90s, most GUI programming was textual. You’d call add(button) and button.text = “Hello World” to build up your GUI, and have to wire up the events from your button to take specific actions. Quite a lot of GUI programming is still like this, even now.

What NeXT brought was a GUI editor that allowed you to drag a button from a palette and onto a window (or view). You could then change the text on the button by double clicking on it and renaming the default text. You also got to determine where and how large the button was in relation to the rest of the window.

Most GUI builders could do this, so what was special about Interface Builder?

Two things stood out. First, you could specify how the button reacted to window resizing. There was a “springs and struts” layout mechanism that allowed you to say which parts were fixed offsets and which were variable. You could also say if the button would resize, and if so, in the X or Y or both directions.

The second thing was the ability to connect the button to an action. By Ctrl clicking and dragging, you could wire up the default action to a “selector” — in effect, a virtual method call, on the owner of the button. This owner would be populated at startup, typically the application (controller). So you could have your code with the responder and another team build the UI, and they would join together at runtime.

You could also use properties generated by code as well - you could connect the button’s field to an object’s property (aka an outlet) so that changing the code changed the UI.

The fact that you could drag and drop connections from UI to code, and from code to UI, as well as building a responsive UI, was really what stood out.

This still lives on in Xcode today; IB and PB begat Xcode and IB which begat Xcode. The “nib” format - Next Interface Builder - was a binary format file containing the descriptive state of the Ui and the wiring requirements, which was renamed “xib” when XML became all the rage is the same thing. The fact that IB has been subsumed into Xcode still hides the fact that is what’s happening under the covers.

I think it’s important to realise that this was in an age when Windows 3.1 was all the rage, and we had only just got out of 256 colour VGA while Next station had 16 million.

Nowadays with everyone doing MVC programming with the web, it doesn’t seem so important. But then there was a time when no one wrote unit tests because it was seen as pointless; but it is from these seeds that ideas become mainstream.

alblue··on What Went Wrong with the Libdispatch
There is very heavy integration between libdispatch and the kennel on macOS. In fact, when porting libdispatch to non macOS platforms for Swift on Linux, the developers were surprised that they couldn’t just unilaterally introduce changes into the Linux kernel in the same way that they had done on macOS itself.

As a result on Linux platforms, the libdispatch libraries are a software bolt on that doesn’t have the same level of tight integration (and therefore performance) than on macOS.

Given that libdispatch existed in macOS with kernel integration a long time before the Linux library port was added, your claim that it was cross platform doesn’t stand up. It was macOS first, with kernel integration, and then a separate compatibility layer afterwards for non-macOS platforms much later.

Source: I helped out with the porting of Swift to Linux when at Apple.

alblue··on Why is day of the month 1-indexed but the month is 0-indexed in C?
Which is one of the worst designed APIs in Java:

https://stackoverflow.com/a/1969651/130659

alblue··on What Went Wrong with the Libdispatch
Some really good observations in here about why libdispatch suffered from scalability issues (in that it created to many threads) and the dichotomy of having to sprinkle async everywhere even if it didn’t make sense because it needed to be used from an async function elsewhere.

Related; the difference between “red” and “blue” functions is worth a read:

https://journal.stuffwithstuff.com/2015/02/01/what-color-is-...

alblue··on The Secrets of Monkey Island’s Source Code
The video at the top of this page appears to be a five hour video, but it looks like it was a recording of the stream on the day, and the first 2.5h of the video stars just the “please wait for the stream to start” holding page.

Similarly there’s about an hour of that same landing page at the end of the video, so in reality there’s about an hour and a half of real video in the YouTube link.

I almost didn’t watch it in principle because I didn’t have 5h to watch it, but when I quickly scrubbed through I found out it wasn’t as bad as I feared (timing wise).

alblue··on Unbound DNS Blacklist
It’s just based on dnsmasqd which I’m fairly sure is on FreeBSD. You can configure it yourself.

https://github.com/alblue/dnsmasq-example

alblue··on Fleets: A new way to join the conversation
The major downside of these “fleets” is that they will be able to be used to harass others but subsequently hide the evidence of that automatically after 24h.
alblue··on Fleets: A new way to join the conversation
What users want: an edit button for Tweets and the ability to block Nazis.

What Twitter gives: self destructing tweets.

alblue··on Apple Silicon M1 Emulating x86 Is Still Faster Than Every Other Mac
The fact they are on the same package means that the electrical signals have a lot less far to travel from memory to cpu, and therefore you don’t have the signal losses or interference from the board having to route memory lines externally.

As a result you would be able to drive a higher bandwidth because you don’t need to be as limiting with the transfer time of signals.

alblue··on Why I teach vim
But anchovy is a fish ... how is that not eating animals?
alblue··on Zuckerberg defends not suspending ex-Trump aide Bannon from Facebook: recording
In this instance, Bannon gets away with it because he is white and shares political views of Zuckerberg.

If an (e.g.) Muslim had said the same thing about a high profile (far)-right candidate, many of the people who supported his post would be calling it a terrorist threat.

In this case Zuckerberg is defending the terrorist calls to arms of those who think, and look, like him.

alblue··on Eleven Years of Go
The argument seems to be that a,b=c<d,e>g could be misplaced based on whether this is a generic type or a pair of comparisons.

They then go on to say that they needed to revisit the design in the square brackets case to insert the keyword “type” whenever generics were used, which means this example would presumably become c<type d, type e> which resolves the ambiguity.

It seems more likely it was an issue discovered atbut not revisited when the issue was fixed, and now inertia is keeping it as is.

alblue··on Eleven Years of Go
It’s still possible to run Java programs that were compiled for 1.2 on modern day JVMs without change.
alblue··on On Apple's Piss-Poor Documentation
They actually have a department to write the documentation. The problem is that it’s a separate department from the people who design the libraries themselves, which means instead of having high quality documentation throughout, you only get the documentation that the doc team had time to write. It’s why most of the APIs are minimal at best in terms of documents.

While the level of documentation that exists is usually pretty good, the sad fact is that most documentation doesn’t exist, and it’s entirely due to the fact that they are handled by developers/documentors separately. If you had developers documenting in-situ in the code, instead of WWDC slides, then it would be a lot better.

alblue··on Toyota president: Tesla has 'not created a real business in the real world yet'
I’ve been driving Toyota cars exclusively over the past 30 years. I’ve been driving a Prius for the last 18.

I had really hoped that Toyota would come up with an electric only vehicle, but they’ve rolled out their hybrid drive train across their entire fleet now.

They have a fuel cell vehicle which runs on hydrogen only, but there’s a small handful of stations in the UK which means it’s pointless.

I now have an electric car in order which isn’t a Toyota and I don’t think I’m going back.

alblue··on LLVM Clang 12 Merges Support For x86_64 Microarchitecture Levels
I found the phoronix summary better than the sourceware email. The email proposed a feature and had “it could look like …” bikedshedding discussions back in July — the original phoronix page summaried the conclusion of adding the feature, including what the names are now called.

It’s useful to know where something started, but the original reference was better at explaining the current situation.

alblue··on Gron – Make JSON Greppable
Yup, and it’s been merged :-)
alblue··on Background Features in Google Meet, Powered by Web ML
Badly.
alblue··on Fast UTF-8 validation
I had a follow up thread with the author on Twitter, and one part of the talk ventured into if UTF-8 made sense for Eastern scripts. I looped in one of my ex Apple colleagues who worked on the transition of Swift from UTF-16 (the Mac default) to UTF-8 for the rationale why this made sense.

That led to a whole discussion of the benefits of self synchronising bytes in UTF-8 as well as a gratuitous self promotion of my “history of Unicode” talk at https://speakerdeck.com/alblue/a-brief-history-of-unicode

The end of the Twitter thread is here, if you’re interested:

https://twitter.com/alblue/status/1319017092004315138

alblue··on Proving that 1 and 1 = 2 in Rust
The linked article has 1+1=2; the title in HN is incorrect but may have prevented the use of the + symbol.
alblue··on 40th Anniversary of the Ethernet
IPv6 has been around for ages, but it has started picking up over the past couple of years.

https://www.google.com/intl/en/ipv6/statistics.html

← PreviousPage 4 of 14Next →