Tempest Status Update (March 2023)

08 Mar 2023

It’s been a month since my last Tempest status update, so it’s time for another. Since last month:


A month ago, Tempest did not understand the permission bits in a a package definition, and would always connect to grains with minimal permissions. Now, permissions are tracked.

On its own this is a small thing, but while working on it I built out a bunch of the plumbing needed for sturdyRefs. I’m finding each feature I reach to build results in me filling out the codebase with things that will mean less and less yak shaving for future features; it’s a nice thing to watch.

Creating Grains

Up until now, I’ve been developing and testing sandbox functionality using grains imported from Sandstorm, as there was no way to create new grains. This is no longer the case; Tempest can now create new grains from installed apps. At time of writing there are some limitations, which will be addressed soon:

Tempest still doesn’t provide a way to install apps, so importing data from Sandstorm is still necessary.

UI Improvements

There have been a few improvements to the UI. Specifically:

Bundle Size

One of the drawbacks of using Go in the browser is that bundle size will not take care of itself; Go has a tendency to generate very large binaries, and while this isn’t a huge deal for the type of server-side code that Go is most typically used for, in the browser it’s a problem. I dismissed some other possible tools because of unacceptably large frontend payloads.

Before committing to use Go for the frontend at all, I did enough research to be sure I could at least keep bundle size under control, but knew going in that acceptable results would require some care.

Since very early on the build has been using TinyGo; the reference Go compiler generates an executable just shy of 4 MiB, which is a complete non-starter. Around the time of last month’s update, TinyGo was generating outputs close to 900 KiB, which is still not good, but close enough that I knew with some tuning the results could be acceptable.

Over the past month I’ve made some improvements go-capnp resulting in smaller binaries: things like trying to avoid the large fmt package, and making dead code elimination work better. As a result the binary is down to 440 KiB, which is starting to get competitive with Sandstorm’s own bundle size (377 KiB).

There’s still more work to do on this front; 440 KiB is in the acceptable range, but I’d love it if Tempest could be even leaner, and there is still some low-hanging fruit that should have a big impact.