Anton Zhiyanov
antonz.org
Anton Zhiyanov
@antonz.org
Open source maintainer. Writing interactive technical books at https://antonz.org
Fun fact: there is no standard way to compare or sort IP subnets up to Go 1.25.

When the Go team initially designed the IP subnet type (netip.Prefix), they chose not to add a Compare method.

Over time, they changed their minds.

antonz.org/accepted/net...
Go proposal: Compare IP subnets
The same way IANA and Python do.
antonz.org
October 20, 2025 at 9:13 AM
Reposted by Anton Zhiyanov
I enjoyed reading the first few chapters in antonz.org/go-concurren... so much that I ended up purchasing the eBook 😁 It's just $10 which is a small token of appreciation for all that @antonz.org gives to the #go community for free! Plus now I get to solve all the exercises in the book. 😋
Gist of Go: Concurrency
Interactive book on concurrent programming with many exercises.
antonz.org
October 15, 2025 at 2:34 AM
I ported the core parts of Go's time package to C.

The resulting library offers a rich set of functions, from working with Unix time to time comparison and arithmetic to truncation and rounding.

With nanosecond precision.

github.com/nalgeon/vaqt
GitHub - nalgeon/vaqt: High-precision date/time in C
High-precision date/time in C. Contribute to nalgeon/vaqt development by creating an account on GitHub.
github.com
October 15, 2025 at 11:12 AM
The new chapter of my interactive Go Concurrency book covers atomics.

They provide concurrent-safe operations without explicit synchronization, but there are several pitfalls to watch out for.

antonz.org/go-concurren...
Gist of Go: Atomics
Concurrent-safe operations without explicit synchronization.
antonz.org
September 30, 2025 at 12:13 PM
Accepted! Go 1.26 will introduce Hashers — a standard approach to hashing and equality checks in custom collections.

I've made a summary of the proposal, and even managed to squeeze in some interactive examples.

antonz.org/accepted/map...
Go proposal: Hashers
Consistent approach to hashing and equality checks in custom collections.
antonz.org
September 28, 2025 at 12:42 PM
You are a software engineer. Don't become a prompt refiner.

antonz.org/write-code
Write the damn code
You are a software engineer. Don't become a prompt refiner.
antonz.org
September 26, 2025 at 10:30 AM
I'm launching a new Go-related series named Accepted.

For each accepted proposal, I'll write a one-page summary that explains the change in simple terms.

This should (hopefully) be the easiest way to keep up with upcoming changes.

The first issue is already out!
September 24, 2025 at 12:21 PM
The only way to run tasks concurrently in Go is by using goroutines.

But what if we bypass the runtime and run tasks directly on OS threads or even processes?

Let's find out!

antonz.org/multi
Native threading and multiprocessing in Go
Exploring unconventional ways to handle concurrency.
antonz.org
September 22, 2025 at 6:02 PM
xxhash is the best non-cryptographic hash algorithm I know. It's really fast, high quality (rare collisions and strong avalanche effect), and comes in three flavors: 32, 64, and 128-bit.

So I figured now's a good time to add it to my SQLite extensions!

github.com/nalgeon/sqle...
September 1, 2025 at 10:09 AM
I've made a public changelog for my projects. 35 major updates over the past 5 years — I guess I'm building in public after all!

antonz.org/tags/projects
August 24, 2025 at 11:06 AM
WaitGroup.Go is a small change, but wait groups are so common in concurrent programming that switching from Add+Done to Go in my Go Concurrency book took me a while :)

Anyway, it's done now, so a lot of examples are easier to read!

antonz.org/go-concurrency
Gist of Go: Concurrency
Interactive book on concurrent programming with many exercises.
antonz.org
August 23, 2025 at 9:43 AM
Two new SQLite extensions by Walter Wanderley!

➀ HTTP requests
➁ MQTT publish/subscribe

sqlpkg.org?q=litesql
August 16, 2025 at 2:31 PM
Go 1.25 is out, and the announcement says:

"Over the next few weeks, follow-up blog posts will cover some of the topics in more detail. Check back in later."

So you can wait a few weeks OR you can read my interactive Go 1.25 tour right away:

antonz.org/go-1-25
Go 1.25 interactive tour
Fake clock, new GC, flight recorder and more.
antonz.org
August 13, 2025 at 9:52 AM
I think third-party Go concurrency packages are often too opinionated and try to hide too much complexity.

That's why I created `chans`: a package with generic channel operations that's unopinionated, composable, and doesn't take control away from the developer.

antonz.org/chans
Building blocks for idiomatic Go pipelines
Unopinionated and composable channel operations.
antonz.org
August 11, 2025 at 12:46 PM
All jokes aside, I've implemented promises and async/await in Go. Just make sure you NEVER use them.

github.com/nalgeon/azor
GitHub - nalgeon/azor: Promises and async/await in Go
Promises and async/await in Go. Contribute to nalgeon/azor development by creating an account on GitHub.
github.com
July 27, 2025 at 3:30 PM
The new chapter of my interactive Go Concurrency book covers signaling, one-time execution, and object pools.

If you think channels are the only way for goroutines to communicate, check it out!

antonz.org/go-concurren...
Gist of Go: Signaling
Sending events between goroutines.
antonz.org
July 21, 2025 at 10:27 AM
I've updated the list of Go features by version.

Now, each feature has ➀ a link to the documentation, ➁ a link to the proposal, and ➂ a link to the commits.

It's fascinating to see how Go has changed over the years.

antonz.org/which-go
Go features by version
Which major features appeared in which versions of Go.
antonz.org
July 19, 2025 at 11:11 AM
Make smaller interfaces. Stay deep. antonz.org/deep-modules
On deep modules
Make smaller interfaces. Seriously.
antonz.org
July 17, 2025 at 12:46 PM
You don't need testify/assert to write clear and expressive Go tests.

antonz.org/do-not-testify
You don't need testify/assert
To have expressive test assertions.
antonz.org
July 16, 2025 at 10:32 AM
Okay, I did it again. I reimplemented Redis using Postgres.

Key/value, expiration, maps, lists, sets, and sorted sets — everything in your favorite database. With a Redis-compatible API and wire protocol.

github.com/nalgeon/redka
GitHub - nalgeon/redka: Redis re-implemented with SQL
Redis re-implemented with SQL. Contribute to nalgeon/redka development by creating an account on GitHub.
github.com
July 14, 2025 at 10:02 AM
How about a micro test assertions Go package with flexible error checking?

Only 100 loc. I've named it "be" :)

github.com/nalgeon/be
GitHub - nalgeon/be: Minimal test assertions in Go
Minimal test assertions in Go. Contribute to nalgeon/be development by creating an account on GitHub.
github.com
July 7, 2025 at 5:29 PM
The new chapter in my interactive Go Concurrency book is about Semaphores.

You'll have a Rendezvous with some helpful synchronization tools and even overcome a few Barriers.

If you know what I mean 😉

antonz.org/go-concurren...
Gist of Go: Semaphores
Limiting the concurrency and waiting for the peers.
antonz.org
July 1, 2025 at 4:16 PM
Given how much I love Redis, it's strange that I haven't made a playground for it — until today.

Now I (and everyone else) can finally write interactive Redis docs!

codapi.org/redis
Redis playground
Embeddable Redis playground for education, documentation, and fun.
codapi.org
June 29, 2025 at 10:14 AM
Go 1.25 is coming soon, and the official release notes are pretty dry.

So I prepared an interactive version with lots of examples.

antonz.org/go-1-25
Go 1.25 interactive tour
Fake clock, new GC, flight recorder and more.
antonz.org
June 26, 2025 at 12:18 PM
I'm working on an interactive Go 1.25 tour, but there are so many changes in json/v2 that I decided to cover them in a separate blog post.

Plenty of interactive examples ahead!

antonz.org/go-json-v2
JSON evolution in Go: from v1 to v2
Reviewing the key changes in json/v2.
antonz.org
June 22, 2025 at 1:54 PM