I think one reason why the autocorrect in iOS is so frustrating is that, not only is it aggressive in thinking that it knows the right word, but that it doesn’t take attributes like capitalisation as hints of the word I’m trying to use.
I’ve been trying to write a post with the word “blame”, but I’ve been misspelling it as “blaim”. The iPad, trying to be helpful, is automatically changing it to “Blair”. It knows that “blame” is a possible correction — if I were to undo the change and bring up the chip of suggested alternatives, “blame” is one of them — but I never get the opportunity to select it as it changes the word from under me.
When there’s no suggestion, the misspelt word is simply highlighted. Maybe that should be the way to go for all missspellings unless iOS is almost certain that it knows the correction. I know it’s a hard problem, but it would be appreciated if more work is spent on making this less frustrating.
It took an hour navigating various Telstra phone trees, chat apps, and the website, but I’ve now got a static IP address for my home internet. The reason for doing so relates to work, but it does open up other use-cases which may be fun to explore.
One aspect of software development that I like is the research side of things: learning something new and interesting that will hopefully be useful for the problem I’m working on. The downside of this, though, is that I cannot listen to podcasts while I work.
There are many people around where I work that like “loud cars” of some sort, but I most certainly do not. This is one more reason why I’m looking forward to electric cars being the norm.
There was a massive spiral wheel-shaped spider web in my backyard that I thought was abandoned. It was only after I took it down this morning that I realised it actually wasn’t. Now I feel kinda bad.
I wish more podcasters realise that there are other podcasting players than just Spotify and Apple Podcasts.
Thank goodness Micro.blog offers the ability to edit replies. It seems like I’m constantly making small spelling or grammatical errors in my replies, and it’s always after I post them when I see them.
Some photos of my time in Warburton yesterday, in the Yarra Valley. Went for a bike ride and a bit of a bush-walk. Lovely day for it, if a bit sunny.



A Year Under The Pandemic
This was originally a journal entry but I thought I’d share it here as well. Today is the end of week 52, almost a year to the day that the pandemic became all to real for me. I’ve taken today day off to spend some time in Warburton. It was in Warburton last year, almost to the day (13th of March), that things began to get serious. The news coming out of China and Italy was grave: hundreds of deaths, thousands of new cases, hospitals filling up, lack of ventilators and staff to operate them, PPE shortages, scenes of people locked down in their home. The outbreak in New York was becoming serious as well, and the US government announced closure of their borders to Europe.
There were also a number of new cases here as well, it may have been 100 or so around the country. That Friday a number public events were cancelled, like the AFL and Grand Prix, and the borders were closed off to the rest of the world — nobody was allowed in or out. There was a run on things at the shops as officials advised people to be stocked for two weeks should you need to isolate. Toilet paper was in short supply, along with some other staples like pasta and tuna. There was a general sense of unease around the place.
It was also the time when I started working from home. I returned one last time to the office of my old job on Tuesday the following week. The city was quite quiet. A lot more people were wearing marks and half the cafes were closed for the afternoon. I haven’t been back to that office since. I think the weekend following I stopped meeting my parents for dinner, and only went out for groceries.
I guess it’s hard to describe how scary the situation was at the time. The testing and tracing infrastructure was not yet setup, so nobody really knew where the virus was. The government ensured us that there was no local transmission, but it was difficult to believe them, especially as case numbers were rising rapidly. The reported death rate was also terrifying — up to 3% at the time but higher in certain places. I was fearful of everyone I loved, as well as myself, catching the disease and ending up on a ventilator, or worse, dying. Taiwan was the only country at the time to have curbed the virus: most Western countries were struggling with outbreaks, so at the time I had little faith that Australia would be able to manage the virus as well.
I was also afraid that the lock downs would last until a vaccine is available. At the time medical experts were tempering expectations of a speedy delivery of a vaccine. Turnaround times were usually 1 to 1.5 years. The fact that they were ready the same year was considered a bit of a breakthrough (I guess these things really do happen).
A lot has happened this past 52 weeks. The nation has managed to keep the virus more or less under control. There were setbacks though: the second Melbourne lock down was regrettable. But we have managed to setup a somewhat decent testing and contact tracing regime, along with hotel quarantine, and new local cases have been at or close to zero for most of the past 5 months. Vaccinations of the border workers, front line workers, and people at risk are currently in progress.
A sense of normalcy has returned, in what is generally called “Covid normal”. The borders are still closed to everyone except New Zealanders, and no one is generally permitted to leave the country. Since November, things have pretty much remained more-or-less opened. Events like the AFL are back on with small crowds that are socially distanced.
But the threat remains. Every day I’m looking on Twitter to see what the latest number of new cases is. There’s a constant trickle of positive cases coming in from overseas, where the virus is still raging. There have been new, more contagious and deadly, variants popping up, and it’s a constant struggle to keep them out: we have had to go through a 5 day snap lock-down to stop local transmission of one.
So there’s little to do but wait. I appreciate that we’ve managed to gain some semblance of normalcy back, something that I’m aware others around the world have been denied so far. Eventually this will pass as well, but I’m hoping it doesn’t take another 52 weeks.
I love the idea of HEY World, that you can publish a blog post simply by sending an email. They’ve also put a lot of care into the styling of the posts as well, and each one looks great. It almost makes me want to sign up to try it.
I’ve been writing a bit more on my development related blog recently so I’ve added the feed to this Micro.blog account. This means there may be some more software development related posts showing up in the timeline. I’ll see how this goes.
It’s a public holiday today, meaning that instead of writing software for work, I could do almost anything else. But of course I chose to spent the whole day writing software for myself.
It’s funny how somtimes you make a mistake, then you make another mistake that relates to that first mistake, and they somehow cancel each other out.
Request to all cafe owners: please ask the customer if they would like coriander in their sandwich before putting it in. I know many people who love coriander, but I most definitely do not! And it’s always an unpleasant shock when I take a bite of a sandwich that has it.
It’s the middle of week 2 back in the office, and I’ve found myself falling back on most of the old routines that were put in stasis for a year. I’m a little shocked at how quickly that can happen.
I had a Blot.im account that I was paying for but not using, so I’ve started a digital garden on software development. It’s mainly links and techniques that I’ve found helpful, but also a place to voice an opinion, and occasional rant, on the goings on in the industry.
The interesting thing about technology breakthroughs is how quickly the shift from the impossible to the banal actually is. An example of this is machine learning. This was something that was being researched on since the 1950s, with very little to show for it in terms of practical applications. This changed very recently, thanks to the growth of computing power. Now, many of these same techniques are used in many things that are taken for granted, like language translation, image recognition, and surfacing content in algorithmic timelines of social networks (not all utilisation of this technology is good).
This was one of the first thoughts I had when I heard about the announcement of a potential vaccine for malaria, which uses very similar technology to the mRNA Covid-19 vaccines.
I’ll have to go clothes shopping today to get a new jumper. It’s hard to find them during summer, but autumn’s just a few days away, so I’m hoping that they are in stock again. I didn’t have a chance to buy one last year because of the winter lock-down.
Setting Package Variable When Building Go Project
Here’s a technique for setting a variable in a Go project when building it.
Say you have a global variable like the following:
// Package www.example.com/pkg/sample
package sample
var ServerVersion = “”
The server version is determined during build time based on the Git tag. This is available from the environment, but you don’t want to hard code this yourself. Doing so will mean that you’ll need to update it when it changes, and you know that you’ll forget to do that (I constantly do).
Previously what I tended to do is write a source code generator to set this, and just try to remember to run it when it changes. However, that is unnecessary:
What you can do is run go build
with the linker flag -X
:
$ go build -ldflags “-X www.example.com/pkg/sample.ServerVersion=1.2.0”
The variable needs to be of type string, and must be either uninitialised or initialised to a constant string expression.
Supporting HTTP/2 Without A tls.Conn In Go
Go has support for both HTTP/1.x and HTTP/2 in the web server available in net/http. Unfortunately, in order support HTTP/2, the net.Conn
returned by the net.Listener
must be of type *tls.Conn
. If it is not, the web server will refuse to upgrade the connection.
This makes it impossible to use HTTP/2 if you’re using a listener that may be returning different net.Conn
implementations.
One could argue that this appropriate, given that HTTP/2 must be performed over a TLS connection. I’m not so sure I agree on this front. Is it up to the standard library to enforce this, or should there be enough room available to the developer to choose how this should be enforced? What if TLS is being terminated at a load balancer?
Anyway, this article provides a way to enable HTTP/2 without requiring a *tls.Conn
. The basic mechanism of doing so involves the following:
- Use h2c.NewHandler(). This function takes a normal HTTP handler — which will most likely be the one you wrote for your HTTP/1.x service — and a HTTP/2 server configuration; and will return a new HTTP handler.
- Use the returned HTTP handler with a standard
http.Server
.
This new HTTP handler will hijack the original HTTP/1.x connection and upgrade it to a HTTP/2 connection.