Blog

Will Faught

July 2017

Survey Of Rounding Implementations In Go

Rounding in Go is hard to do correctly. That is, given a float64, truncate the fractional part (anything right of the decimal point), and add one to the truncated value if the fractional part was >= 0.5. This problem doesn’t come up often, but it does enough that as of this writing, the second hit on Google for golang round is a closed issue from the Go project, which declined to add a Round function to the math package.

go programming

Will Faught

1 minute

Ingenious Paper Sizes

The U.S. uses its own own standard paper sizes: letter, legal, tabloid, and so on. Europe uses an ingenious system: The base A0 size of paper is defined as having an area of 1 m2 and a side ratio of 1 by √2 […] Successive paper sizes in the series A1, A2, A3, and so forth, are defined by halving the preceding paper size across the larger dimension. This also effectively halves the area of each sheet.

Will Faught

3 minutes

Endymion

From chapter 59 of Endymion by Dan Simmons: I once said to you that you were reading this for the wrong reason. What I should have said was that I was writing this for the wrong reason. I have filled these seamless days and nights and smooth pages of microvellum with memories of Aenea, of Aenea as a child, with not one word of her life as the messiah whom you must know and perhaps whom you mistakenly worship.

Will Faught

2 minutes

June 2017

Go 1.9 Doesn’t Match Vendor Packages With Path Wildcards

By popular request, ./… no longer matches packages in vendor directories in tools accepting package names, such as go test. To match vendor directories, write ./vendor/…. Finally! This removes the need for any kind of vendor-aware Makefile. I was worried when the suggestion of adding a -vendor flag was rejected.

go go1.9

Will Faught

1 minute

Go 1.9 Release Notes

My little suggestion: Viewing documentation on struct fields is now supported with go doc struct.field.

go go1.9

Will Faught

1 minute

“Swift Creator Chris Lattner Leaves Tesla After Only Six Months In The Job”

Chris Lattner: Turns out that Tesla isn’t a good fit for me after all. I’m interested to hear about interesting roles for a seasoned engineering leader! Him and everyone else. It’s a shame he gave up such a great job.

Will Faught

1 minute

May 2017

The End Of Representative Democracy

Scott Adams: That isn’t necessarily bad news. The Republic form of government doesn’t make sense in the modern world anyway. We already evolved into a form of direct democracy via social media and polling. Our politicians can’t risk going against a big majority – even for noble reasons – because social media will organize to drive that person out of office over the issue. In effect, we are already a direct democracy.

Will Faught

1 minute

April 2017

What You Watch With A Cold

Pretty cool footage of cilia moving mucus. I have a cold. 🤧

Will Faught

1 minute

JavaScript Doesn’t Need Class

Ian Elliot: JavaScript is the single most important programming language and yet, as it reaches its high point, everyone is complaining about it and there are significant efforts to replace it with something better - Go, Dart, Coffeescript. Even the people who love it seem to misunderstand it because they want to add “class”. JavaScript doesn’t need class! And if you think it does you need to look more carefully at JavaScript.

javascript programming

Will Faught

1 minute

JavaScript Garden

Ivo Wetzel: JavaScript Garden is a growing collection of documentation about the most quirky parts of the JavaScript programming language. It gives advice to avoid common mistakes and subtle bugs, as well as performance issues and bad practices, that non-expert JavaScript programmers may encounter on their endeavours into the depths of the language. Really good resource.

javascript programming

Will Faught

1 minute

The JavaScript Minefield

Jeff Walker: How is JavaScript a minefield? Well, JavaScript has all sorts of pitfalls lurking for the developer. Each pitfall is like a mine in the minefield, silently waiting for you to accidentally step on it. Just like the minefield, JavaScript’s mines are hidden in plain sight. Entire books have been written about all the mines present in JavaScript. Maybe I’ll get into what some of those are in future blog posts.

go javascript programming

Will Faught

1 minute

Vim Koans

The novice finished aligning two beams and had positioned a nail ready for beating into the wood, but found the hammer was out of reach. “Would you pass me the hammer, master?” Master Wq handed the novice a saw. At once, the novice was enlightened. So good.

programming vim

Will Faught

1 minute

Git Koans

“Master,” said the novice, “what is the nature of long and short options for commands? I thought they were equivalent, but when that developer used -h you said something different than when I said –help.” “Perspective is everything,” answered the Master. The novice was puzzled. She decided to experiment and said “git -h branch”. Master Git turned and threw himself off the railing, falling to his death on the rocks below.

git programming

Will Faught

1 minute

A Guide To Which Countries Drive On The Left

Most countries which were British colonies still drive on the left hand side of the road including huge land masses such as India, Australia and Southern Africa as well as the Caribbean. Europe generally drives on the right hand side apart from the United Kingdom, Ireland, Malta and Cyprus. Guyana (formerly a British colony) is the only country in South America to drive on the left. The other two thirds of the countries in the world drive on the right including the USA, China and Russia.

Will Faught

1 minute

March 2017

Why I Left Language 1 For Language 2

Igor Horst: I am a big fan of [Language_1] and one of its early adopters, having been disappointed with the utter failures of [Language_0]. I have been an avid contributor to many open source projects such as [Obscure_Project_1], [Obscure_Project_2], and [Obscure_Project_3]. However, after using [Langauge_1] for over 5 years, I have been dealing with [Minor_Technical_Flaws]. At first, I ignored and even tolerated these flaws, but ultimately, I was forced to confront reality.

programming

Will Faught

1 minute

February 2017

Just Discovered Lobste.rs

Looks cool.

Will Faught

1 minute

December 2016

The Default GOPATH

The requirement of setting a GOPATH has been a major issue for Go users who installed the Go tools for the first time and got the “you have to set a GOPATH” error in their initial experience with the tools. Explaining the GOPATH is and instructing how to set this env variable were both distracting new users away from using Go. This was especially true for users who are not necessarily developing in Go but using go get to download commands.

go programming

Will Faught

1 minute

Why Does Calloc Exist?

Nathaniel J. Smith on the purpose of calloc: When the operating system hands out memory to a process, it always zeros it out first, because otherwise our process would be able to peek at whatever detritus was left in that memory by the last process to use it, which might include, like, crypto keys, or embarrassing fanfiction. So that’s the first way that calloc cheats: when you call malloc to allocate a large buffer, then probably the memory will come from the operating system and already be zeroed, so there’s no need to call memset.

c calloc programming

Will Faught

1 minute

November 2016

Fish Shell

I got a laugh learning about the fish shell on its main page.

fish shell unix zsh

Will Faught

1 minute

Ars Technica Reviews The New 13-Inch MacBook Pro

Andrew Cunningham, writing for Ars Technica: But when you dig down to find the root cause of most people’s angst, it’s less about the new MacBook Pros individually and more about the way Apple has been treating the Mac lineup in general for the last two or three years. Even if you consider the MacBook and MacBook Pros to be solid computers—and they are, in most respects for most users—these refreshes by themselves don’t really right the Good Ship Macintosh.

apple ars technica laptop mac macbook macbook pro notebook review

Will Faught

1 minute

October 2016

TextMate 2 Autocomplete Pop-Up Menu

It took me forever to figure this out, but if you want IDE-like autocomplete in TextMate 2, press Option-Escape.

autocomplete textmate

Will Faught

1 minute

458 Request Too Sexy

HTTP Status Codes

Will Faught

1 minute

Has The Garden Of Eden Been Located At Last?

A really compelling investigation of whether Eden existed and where. There’s a really good telling of it all (but with less detail) in a Myth Hunters episode (currently available on Netflix).

adam archeology bible eden garden

Will Faught

1 minute

No Reader For Bzip2

Apparently compress/bzip2 is the only Golang compression standard library that doesn’t have a Writer counterpart for its Reader. Lame.

go

Will Faught

1 minute

September 2016

SQL Injection Can Compromise The OS

TIL that if your server has even one SQL injection vulnerability, the entire operating system can be compromised. Eye-opening!

code coding engineering hacking programming software sql

Will Faught

1 minute

August 2016

Go Raised The Bar

Go raised the bar for new language distributions: UTF-8 code Testing, benchmarking, and profiling built in Single command line tool Build tool that leaves code directories clean Package manager Package doc browser Standard code style and formatter Fast builds Language spec with grammar and thorough library documentation Uniform, batteries-included standard library Concurrency support and automatic parallelism, sync and atomic libs, race detector Interfaces, not inheritance Vendoring support Cross compilation Static linking only for simple deployments Tabs, not spaces No semicolon line terminators Trailing commas in lists to minimize diffs Static types Default values for uninitialized variables Built-in comparisons and hashing Safety (e.

code coding engineer engineering go program programming raise the bar software swift technology

Will Faught

1 minute

Million Container Challenge

Cluster schedulers promise us ease of deployment with ultimate scalability. We designed an ambitious challenge to test these promises: schedule one million containers. We call this the Million Container Challenge (C1M). HashiCorp prides itself on creating technically excellent software, and the C1M is a test to showcase this. We tested Nomad against the C1M to ensure that we meet the needs of our users at any scale. A cluster of five Nomad servers scheduled one million containers in less than five minutes, a rate of 3,750 containers per second.

cluster container deploy deployment docker hashicorp manage management nomad

Will Faught

1 minute

FizzBuzzEnterpriseEdition

FizzBuzz Enterprise Edition is a no-nonsense implementation of FizzBuzz made by serious businessmen for serious business purposes. So funny.

coding enterprise funny java programming satire

Will Faught

1 minute

Why Some Diversity Thinkers Aren’t Buying Tech Industry’s ‘Pipeline’ Excuses

“Diversity thinkers”? Who comes up with that terminology? The pipeline is a valid argument because that’s exactly what’s happening. Anyone who disagrees ought to first take a look in the mirror: have you ever bought your kid a gender-specific toy? A doll for a girl? An action figure for a boy? Because if so, that’s the problem right there. The problem is you. The problem is social. The problem is parents holding their girls back by only giving them “girly” things.

coding computation computer science computers computing feminism npr planet money programming tech technology

Will Faught

1 minute

The Republicans Waged A 3-Decade War On Government. They Got Trump.

Great bird’s-eye view of politics from a few decades ago through to the presidential election after this coming one. The Republican Party needs to get its shit together.

democrats donald trump hillary clinton politics republicans

Will Faught

1 minute

CEO Marissa Mayer Treated Yahoo Like A Think Tank, Not A Sinking Ship

I can’t decide who comes out of this looking worse: Mayer, who did nothing substantial, or the board that paid her a bonus for it.

marissa mayer technology yahoo

Will Faught

1 minute

July 2016

Aphyr Tests Redis With Jepsen

Aphyr on Redis correctness: So you’re running a distributed Redis install, and have realized that the design of Redis Sentinel (or, for that matter, any other failover system on top of an asynchronously replicated primary-secondary design) means you can lose a lot of data when a partition occurs. What can you do? From an operations perspective, I recommend you try to understand the Sentinel consensus algorithm. I don’t, and I’ve read it a dozen times.

aphyr coding database jepsen programming redis

Will Faught

1 minute

Switching To Apple’s Two-Factor Authentication

Dan Moren, writing for Six Colors: Apple has, for a while now, offered two separate additional security measures to protect your Macs, iOS devices, and iCloud account, but thanks to some inexpert nomenclature, it can be a little difficult to tell them apart. I had no idea Apple added this. It’s easy to switch.

2fa apple icloud security verification

Will Faught

1 minute

Check Sudoku Solutions

My Golang program to check whether Sudoku solutions are correct. It works for any valid Sudoku board size (1x1, 2x2, 4x4, 9x9, 16x16, etc.)

coding engineering go programming software software engineering sudoku

Will Faught

1 minute

June 2016

Io Language

Io looks like a nifty language.

coding io language programming software

Will Faught

1 minute

For Nintendo, It’s Not About Specs

Alex Osborn, writing for IGN: When asked how Nintendo NX will stack up against Sony and Microsoft’s forthcoming hardware revisions—namely PlayStation 4 NEO and Xbox One Scorpio—Fils-Aime told Bloomberg (via Nibel): “For us, it’s not about specs, it’s not about teraflops, it’s not about the horsepower of a particular system. For us, it’s about the content.” In other words, not good. I stopped expecting good hardware from Nintendo a long time ago.

games gaming ign microsoft nintendo nx teraflops virtual reality vr xbox xbox one

Will Faught

1 minute

Long Names Are Long

Bob Nystrom: What I want to talk about is something I see in a lot of code that drives me up the wall: identifiers that are too damn long. Yes, names can be too short. Back when C only required external identifiers to be unique up to the first six characters; auto-complete hadn’t been invented; and every keypress had to be made uphill, in the snow, both ways; it was a problem.

naming programming variables

Will Faught

1 minute

May 2016

It’s Been Over A Decade Since Valve First Promised Half-Life 2: Episode 3

Ars reader Bad Monkey in a comment on an Ars post about it being 10 years since Valve announced Half-Life 2 Episode 3 and then left us hanging: A day at “work” for a Valve staffer: 9am: Arrive at work. Socialize in corridors for half an hour with coworkers, then head to the company cafeteria for breakfast. Free trade coffee and greek yogurt. Socialize with coworkers in cafeteria for 45 minutes.

games gaming half life valve video games

Will Faught

2 minutes

April 2016

Frighteningly Ambitious Programming Language Ideas

Jon Purdy: Furthermore, 1D languages require jumps for flow control, but since any graph can be embedded in three dimensions, languages of three or more dimensions can be written jump-free. An easy way to do this is to allow changing the direction of the instruction pointer rather than its position. Blew my mind.

future ideas instruction languages pointer programming

Will Faught

1 minute

Programming Language Naming Patterns

On the classification of programming language names: Artificially shortened names: Scheme (from “Schemer”, following on from “Planner” and “Conniver”; shortened to fit in 6 characters because ofa limitation of the ITS operating system) Perl (from “Pearl”, the precious stone; shortened to avoid a clash with “some obscure graphics language called Pearl”) Forth (from “Fourth”, because its creator considered Forth a “fourth-generation language”; shortened to fit into 5 characters because of a limitation on the IBM 1130) The origins of some programming language names are fascinating.

forth names perl programming scheme

Will Faught

1 minute

What’s Awful About Being A Software Engineer IC, Tech Lead & Manager

Brett Slatner on the trials and tribulations of being a software engineering individual contributor, tech lead, and manager: I’ve been building software professionally for over 10 years now. I love what I do and I hope to be an old programmer someday. But along the way, I’ve encountered many terrible things that have made me hate my job. I wish that someone had given me a roadmap of what to expect earlier in my career, so when some new and unfortunate awfulness occurred that I wouldn’t have felt so alone and frustrated.

management programming

Will Faught

1 minute

Smartphones Are Boring: Here’s What Happens Next

Joanna Stern, writing for the Wall Street Journal: These days it’s hard to decide which is more thrilling: watching a new phone announcement or doing laundry while listening to hold music. A slightly better camera! A slightly brighter screen! Rose gold! I don’t mean to sound ungrateful. How powerful and accessible smartphones have become over the last decade is one of the greatest technological feats ever. But smartphone design has become as predictable as an Adam Sandler movie.

camera hardware modular smartphone

Will Faught

1 minute

6 Die From Brain-Eating Amoeba

It sounds like science fiction but it’s true: A killer amoeba living in lakes enters the body through the nose and attacks the brain where it feeds until you die. Thanks a lot, brain-eating amoebas, now I can’t submerge my head anywhere. Terrifying.

amoeba brain death

Will Faught

1 minute

WhatsApp Adds End-To-End Encryption

WhatsApp: WhatsApp has always prioritized making your data and communication as secure as possible. And today, we’re proud to announce that we’ve completed a technological development that makes WhatsApp a leader in protecting your private communication: full end-to-end encryption. From now on when you and your contacts use the latest version of the app, every call you make, and every message, photo, video, file, and voice message you send, is end-to-end encrypted by default, including group chats.

encryption whatsapp

Will Faught

1 minute

This Will Crush The Insane San Francisco & Silicon Valley Housing Bubble | Wolf Street

Venture capital is getting nervous. And the flood of new money has become a trickle. As money dries up, startups have to tighten their belts and lower their burn rates in order to live another day. In the process, big hiring plans are shelved. The formerly rosy scenario has turned grim. Companies like Twitter fell all over each other to lure tech gurus with blue-sky compensation packages that then allowed these folks to rent or buy whatever they wanted to, and drive up prices in the process.

bubble investing san francisco tech

Will Faught

1 minute

March 2016

“CockroachDB Skitters Into Beta”

I’ve been looking forward to this. NewSQL seems like the future. NoSQL has impressive strengths, but managing denormalization is a pain in the ass. One of the most notable features of CockroachDB is just how simple it is to deploy. CockroachDB is a single binary which requires only the location of one or more storage devices to manage. Starting a multi-node cluster is as simple as starting the first node on its own and then pointing each additional node at the first node or any other node which has already joined the cluster.

beta cockroach cockroachdb newsql sql

Will Faught

1 minute

MacOS: It’s Time To Take The Next Step

Andrew Ambrosino hits the nail on the head: With the release of macOS should come innovation that positions the OS for the next decade of innovation, and it’s all about common threads that run through the ecosystem. Specifically, macOS 11 should introduce a common framework for presentation, a brand new model for content, and a common thread for people. […] When these three new developments materialize– UIKit, a new Filesystem, and a new model for people– there will be an explosion in next-generation apps across the ecosystem.

appkit apple apps filesystems os x uikit

Will Faught

1 minute

Programming Etiquette

Don’t name your count variables cnt for obvious reasons.

cnt programming

Will Faught

1 minute

“I Took A Pill In Ibiza”

Mike Posner on the popularity of the remix of his song I Took a Pill in Ibiza: If they want to party and do all the things I say brought me sadness in my song, with my song as the soundtrack…so be it. Then maybe they can get some ironies going in their life as I have in mine. When did God or whatever divinity orchestrating my life and career become such a prankster?

ibiza lyrics mike posner

Will Faught

1 minute

Wearing A Suit Makes You Think Differently

There’s a fun little Steve Jobs reference at the end: Meanwhile, no formal research exists—just anecdotal observations—on how the world appears different when wearing a black turtleneck and jeans.

steve jobs

Will Faught

1 minute

π