Rust live-coder and OSS tinkerer who loves teaching. I try to keep a high SNR. Wrote Rust for Rustaceans. At @HelsingAI. Ex AWS. Co-founded @readysetio. he/him
As the year is about to close, it's about time to say good-bye to Twitter. I'm not deleting the account or old tweets, I'll still monitor for mentions and DMs, and if something has _only_ been posted to Twitter I may retweet here. But all announcements will go elsewhere.
Big announcement time 📢 For a while now, I've been working on a book that covers the next steps of @rustlang after "the book" — everything from API design to error handling to concurrency to async to FFI. And the early access was just released over at nostarch.com/rust-rustaceans! 🎉
Big news time 📢 After I finish my thesis, I'll be joining Amazon AWS, specifically to drive adoption of Rust internally at Amazon! The role will include plenty of interaction with the Rust ecosystem and community, so if all goes to plan you'll only see more of me going forward!
In January, @anishathalye, @jjgort, and I ran a short class at @MIT_CSAIL on topics we think are missing in most CS programs — tools we use every day that everyone should know, like bash, git, vim, and tmux. And now the lecture notes and videos are online! missing.csail.mit.edu/
Exciting news — I'm going to start doing Rust streams as part of my job at AWS! Nothing will change about the format or content, but it'll allow me to do more regular Crust of Rust and Unsafe Chronicles streams since I won't just do them on my spare time \o/
I... wrote a book. Like an actual, real, physical book. It's such a strange feeling finally holding it in my hands. I hope it teaches some people some things, and maybe even elicits some laughs along the way! ❤️
Amazon's (wild) new return-to-office policy is making it … more difficult to come to an agreement about me moving to Norway in June. Which means that come summer I may be looking for a Rust job in Europe! If you have an opportunity that may be relevant (🧵), reach out!
This week I've used GCC 7 on a GCC 4 platform to build Python to build GCC 11 to build GCC 11 to build Clang 14 to build Clang 14 to build Rust's LLVM all so I could get rid of some paths that had snuck their way into librustc_driver's debug symbols. This is fine 🐕☕🏠🔥🔥🔥.
The full digital version of Rust for Rustaceans is now up on nostarch.com/rust-rustaceans! I don't have a final schedule for the print version yet, but you can at least start reading it in pixel form 🎉 I hope you end up finding it useful ❤️
PSA: Before copy-pasting a GitHub source code link, especially one that links to a line or line range, hit `y` to make the URL include the current commit hash. That way the link will keep working even if the file is later changed or moved/deleted.
The "decrusting tokio" stream is up! We explored the runtime, blocking, I/O, select, cancellation, mutexes, and also covered several common pitfalls and less-known subtleties. I *think* I covered all I want people to know in "only" 3.5 hours 😅 Enjoy‽
piped.video/o2ob8zkeq2s
Making it possible to turn source code into executables was a mistake. I keep coming to the inevitable conclusion that source code is best left uncompiled. Once you make it runnable, that's when the trouble starts...
I got the receipt from the department — my thesis is now (finally) fully done, and I am officially a PhD graduate 🤓🎉 You can read it here if you are so inclined: jon.thesquareplanet.com/pape…. Also, my girlfriend is awesome and got me a mug for the occasion 😅
ALT Virtual thesis receipt presented to Jon Ferdinand Ronge Gjengset recognizing a thesis submitted to the EECS Department on November 10, 2020 for the degree of Doctor of Philosophy as part of the February 2021 MIT degree list. Congratulations, Jon!
ALT Black mug that says Dr. Gjengset
ALT Other side of same mug says "Ph.D.", but with scribbled-on text such that it says "Phuckin' Done".
Hi friends! I recently gave a talk aimed at companies that are considering adding @rustlang to their tech stack. In it, I presented the upsides and downsides of Rust, and how it differs from C/C++, Java, Python, and Go. And it's now on YouTube 🍿📽️ piped.video/DnT-LUQgc7s
It's finally time for a "decrusting tokio" stream! We'll talk about blocking, cancellation, spawning, mechanisms for synchronization, and some relevant under-the-hood things. Will happen 12:00pm UTC on Friday (everytimezone.com/?t=660f3f0…) on YouTube:
piped.video/live/YlTyZvpaywQ…
In Rust-unrelated news, I have a cat now! Meet Chai (because I love tea and she looks like black tea with a swirl of milk) ❤️ Picked her up from a shelter the morning of Christmas Eve. What a present! Will try to resist the urge to post pictures constantly 😅
Good news everyone! I passed my thesis defense yesterday, and now only have some minor revisions to the thesis itself left before I am completely done 🎉 You can find a recording of the thesis presentation here: piped.video/GctxvSPIfr8
For a while, I've been saying that you need to *make* time for things, as you won't *find* time. Time to follow through. Starting this week, I'm going to do a @rustlang stream every 4th Friday at 6pm UTC. Sometimes long, sometimes short, sometimes Q&A, but always something! 📺
Now that the move to Norway is finally reaching a stable state, I'm excited to announce that come August I'll be joining @HelsingAI; a European company that develops next generation defense software and AI for European democracies.
I'm so excited for this change. Sparse HTTP registry support for cargo is going to completely get rid of that slow "Updating crates.io index" … "resolving deltas" step you sometimes get, and is going to make a huge difference for CI builds!
blog.rust-lang.org/2022/06/2…
Just submitted the first draft of the last chapter of Rust for Rustaceans 📕 There's still a bunch of editing to do, and many passes the text must go through before it's done, but it's a big milestone nonetheless! And just in time for vacation too 🎉
I've mused about the next live-coding stream for long enough. On Saturday we're going to implement the concurrency algorithm from the academic paper "A Practical Wait-Free Simulation for Lock-Free Data Structures" by @petrank and Shahar Timnat in @rustlang. Details in thread 👇
I'm making a "Why Rust" presentation for companies that are curious about what @rustlang offers compared to their current language of choice (usually C++/Java/Python). What, to you, is the #1 reason to consider Rust over each of the languages above in a _commercial_ setting?
The "axum decrusted" video is up! We talk about tower::Service, the Handler trait, Router, and the State extractor, and just generally peel back the crust of the delicious axum pie to expose its gooey center. Turns out dark trait magic is one ingredient 👀
piped.video/Wnb_n5YktO8
I've gotten a *lot* of questions over the years about the future of Noria, my PhD thesis database, along the lines of "when can I use it for real"? Well, back when I graduated I co-founded a company to make that a reality, @readysetio, and it's now public! blog.readyset.io/posts/intro…
Our journey through @rustlang's std::collections clocked in at 2½ hours, with about 30m per data structure, which I'm pretty happy with! We went through them all in a decent amount of detail, including implementation outline and trade-offs.
piped.video/EF3Z4jdD1EQ
Just submitted the last round of edits (in theory) for the last chapter of Rust of Rustaceans. What remains now is mostly procedural stuff, like indexing the book, and then it'll go to print! Such a weird feeling — my evenings will be my own again 😮
Wow, looks like a more beginner-friendly @rustlang stream is something *a lot* of you want to see. So, let's do one! Wednesday @ 8:30p UTC, I'll do a shorter, code-driven stream that covers multiple lifetimes, strings, and some generics. If it goes well, there may be more 👀 1/3
I'm getting closer to graduating (hoping by Nov 1), and it's time to figure out what's next! I'd like to continue working on @rustlang and its ecosystem, ideally on open-source libraries and tools, so if you know of a good fit that supports remote work from LA, please reach out!
I haven't disappeared; moving is just swallowing 100% of my time. The hope is I'll be more settled end of this coming week, and then I'll announce my new job, a Q&A stream, and start working down my 234 GitHub notifications and the longest inbox backlog I've had in a few years 😅
A little while ago, I gave a talk about the many (current and future) meanings of impl Trait at the @rustlang meetup in Copenhagen. The talk was about 30 minutes, followed by almost 45 minutes of (good) Q&A 😅 🙋 And it's now up on YouTube!
piped.video/CWiz_RtA1Hw?si=x0tb…
Michael's blog post "Common Newbie Mistakes and Bad Practices in Rust: Bad Habits" is a good read if you're coming to @rustlang from other languages! adventures.michaelfbryan.com…
Recording of the stream where we implement (part of) a BitTorrent client in @rustlang is now up. We followed a set of challenges from @codecraftersio, and got nearly all the way through even with a power outage! I do love implementing protocols… 😅
piped.video/watch?v=jf_ddGnu…
Woah, I'm almost at 10k followers — that's crazy! I suppose that means my signal-to-noise ratio is acceptable 😅 You're all awesome, and none of my content would exist without your continued excitement and desire to learn with me ❤️
After doing the BitTorrent challenge in @rustlang, I had an urge to do some re-organization to better fit what a real implementation would look like when it has to handle files, concurrency, etc. So, let's do a stream on exactly that Friday at 08:30 UTC (everytimezone.com/s/71fe0592)!
Oh fun, I found a bug in Android's eSIM handling! Which means none of my SIM cards now work, and trying to erase them re-triggers the bug. Any Android Googlers want to take a look? A com.google.android.flib.log.WhatATerribleException exception is involved (yes really).
Okay, this Friday we're going to try for a new @rustlang series — "Decrusted" — where we'll dig into a particular crate in the ecosystem and figure out how it does what it does. First up: serde, decrusted! Friday at 6pm UTC: everytimezone.com/s/1fdd4275
I think it's about time we do a Crust of Rust on atomics and memory ordering! So, this *Friday* at 5pm UTC (everytimezone.com/s/c738e4d2), let's dive into @rustlang's std::sync::atomic and try to figure out what's going on in there and what it's all for 🔬 Come one, come all!👩💻🧑🏽💻👨🏿💻
I know, I know, I've been bad at doing regular streams. What can I say — life got in the way. But it's time for another Crust of @rustlang! This time, build scripts and FFI 🧱 We'll pick a C library and write a -sys for some of it on Saturday at 5pm UTC (everytimezone.com/s/5aa8fa16)!
Wooo — my team, which owns the @rustlang infrastructure and developer tooling internally at @awscloud, is expanding 🎉 If you like building tools and resources for devs, and contributing back to the community where possible, apply (incl. remote) here: amazon.jobs/en/jobs/1938968/…
I'm very happy with how today's stream on atomics and memory ordering in @rustlang turned out. Hopefully this'll help clear up the confusion and mystery that surrounds the std::sync::atomic module, and allow more people to write good concurrent code! 🧮
piped.video/rMGWeSjctlY
A bit of a delayed announcement, but this week's scheduled stream will be on Saturday at 0930 UTC (everytimezone.com/s/953b9846). This time, we'll implement the git version control system core bits from scratch! Will be live at piped.video/live/U8HeVjY9cig…
We got through a few of the @flydotio distributed systems challenges (fly.io/dist-sys/), and it was a fun (and hopefully educational) process! Might do a part 2 one day to go through more of them now that we have a rough framework in place. 📺 at piped.video/gboGyccRVXI.
Our experiment implementing the @3blue1brown Wordle algorithm (or at least, an approximation of it) in @rustlang went pretty well, and we managed to get some pretty impressive speedups (~13500x from the first to the last version)! Video is up now at piped.video/doFowk4xj7Q
I hacked together a little website for Rust for Rustaceans over at rust-for-rustaceans.com/. Nothing fancy, just some quotes from reviews, updates since the book's release, known errata (which I'm sure will grow with time), and some interviews. Let me know what you think!
Recording of today's stream implementing some core git plumbing commands in @rustlang is now up! We got all the way to a working `git commit` 🎉
piped.video/u0VotuGzD_w
For quite some time, I've been hearing that it's hard to find @rustlang jobs that aren't in the cryptocurrency space or in very early-stage startups. Well, @HelsingAI is hiring almost exclusively Rust folks, and we're neither of those things [1/10]
The real news of the @StackOverflow Developer Survey isn't that @rustlang is most loved yet again, or that it's now also most wanted, it's that for the second year in a row the most loved editor is @Neovim: survey.stackoverflow.co/2022…
The @rustlang 2019 survey: "People are [..] asking for more learning material[,] mainly beginner and intermediate level[.] A lot of these requests also asked for video content specifically." — If I were to do a more beginner-friendly Rust stream, what would you want to see?
Recording of today's stream decrusting the tracing crate is now up! We went over both "sides" of tracing. First spans and events, then subscribers, layers, and filters. And apart from a brief ramble on per-level filters, I think it turned out quite good!
piped.video/21rtHinFA40
I regularly have people ask me to do a Noria stream (my @rustlang research database). So far, I've hesitated, as I worry it'll be hard to follow given that you'd be dropped into a big code base. But now is a good time to try! Who would be interested in watching me do research? 🔬
Just had a recruiter cold email me with the subject line "Rust on your GitHub". No wonder people feel like there are only cryptocurrency jobs in Rust these days when the recruiters seemingly email *anyone with a Rust repo*. I dislike this style of batch recruiting so much...
ALT Email that reads: Hey Jon!
Ran across your Github profile and noticed your work with Rust. A number of our clients in the crypto/blockchain space are looking for engineers with Rust experience, and I'm quite confident most of these would be interested in speaking with you.
Do you have a few minutes sometime next week for a quick chat?
I'm thinking of doing a new (infrequent) Crust of Rust "sub-series" on the many pitfalls of unsafe in @rustlang, where each episode looks at a particular trickiness or gotcha. The first one would likely follow my journey with github.com/jonhoo/rust-evmap…. Does that sound interesting?
The recording of the stream where we implemented a lexer and parser for the Lox language from Crafting Interpreters in Rust is now up, and I think it turned out really good! Clocked in at 8h, but it's split into chapters to not be so daunting to follow :)
piped.video/mNOLaw-_Buc
I'm quite excited to have a surprise slot at Rust Nation! I'll be diving into some of the techniques and tools needed to write dependable, misuse-resistant Rust in high-stakes sectors where errors can have serious consequences (healthcare, aerospace, defense, finance, etc.).
Weird(?) stream idea: "But Why?" — take a simple @rustlang example, pick some syntax, and ask "why?" repeatedly. Think println! -> stdout+write! -> ! -> format_args! -> Display/Debug. Not sure who it would be for though. Folks coming from other languages? Would it be interesting?
Recording of today's Crust of Rust on build scripts and foreign-function interfaces (FFI) is now up! We went over the build scripts of several popular *-sys crates, and also wrote our own (basic) binding against libsodium.
piped.video/pePqWoTnSmQ
My favorite thing about being paid partially in stocks? Probably the part where the biannual vesting happens as the stock is down by 1/3, so you're paid tens of thousands of $ less than originally expected. Probably that. Or maybe the part where it's entirely out of your control.
I wonder — is there interest in a shorter stream where I walk through some of my thesis evaluation work so far? Relatively informal, just chatting about what the thesis work focuses on, how I'm evaluating it, what the figures show, how I got to these particular figures, etc.?
Hot(?) take: Rust crates, incl. libraries, should check in Cargo.lock and have 3 CI jobs: -Zminimal-versions, --locked, and rm Cargo.lock. All 3 run tests. Only --locked should be marked as required to minimize friction for new contributors' PRs, which should be 1st priority.
It's finally time to do a decrusted stream about tracing — the so-much-more-than-logging crate that gets requested pretty much every video! We'll do it Friday at 4pm UTC (everytimezone.com/s/3485afaf) just like the stream calendar promised for once 😅
The Crust of @rustlang stream on async/await is now up! My hope is that it's a bit more approachable than the deep-dive video I did a while ago, and that it provides some of the intuition and mental model that comes in handy when _using_ async/await. piped.video/ThjvMReOXYM
Crust of Rust video on Send, Sync, and their implementors (and non-implementors) is now up! Short (for me anyway) and sweet this time⏱️
piped.video/yOezcP-XaIw
I'm back from vacation, so it's time for another Crust of Rust! This time, I'll try for a more concise async/await video, focusing on what most users see (async/await) more so than the underlying mechanisms (Future/Pin/Waker). Let's do Friday @ 5p UTC (everytimezone.com/s/0c146a38) 🦀
Did... did my hotel just include an @MSN burn in their Wi-Fi connection instructions?
ALT Connection tips from a hotel info sheet. One entry reads "Try to access web pages in your browser that you normally don't visit, such as www.msn.com."
The recording of our 3-hour deep-dive into the Why, What, and How of Pinning in @rustlang is now up! Thanks all for watching and for all the questions — the stream is better because of you ❤️ Next video in ~3 weeks. piped.video/watch?v=DkMwYxfS…
Okay, finally time to get back on schedule! This Friday at 4pm UTC (everytimezone.com/s/f917eb5b) we'll do another "decrusted" stream, this time on the axum web framework. It'll be live on YouTube and Twitch at the usual locations, and recording on YouTube afterwards as always!
The Crust of Rust mini session on lifetimes seems to have been helpful, so let's do more! I'll cover declarative macros (macro_rules!) on Wed at 8:30p UTC (everytimezone.com/s/2761f055). As before, it'll assume you have some @rustlang experience already, but anyone is welcome ♥️🥧
Earlier this week I gave a guest lecture on supply chain security as part of MIT's computer security class (6.5660, formerly 6.858) . That lecture is now up on YouTube for any of you who may be interested in that sort of stuff!
piped.video/kCj4YBZ0Og8
I have a crate I really want to reduce the compile time of, and figured I might as well stream my attempt! So, this Friday at 10pm UTC (everytimezone.com/s/7157f142), let's explore some ways to do that. And yes, I'll be stealing some things from the excellent
This was a really fun watch. Makes me want to implement a solver myself in Rust. Mostly to see how fast I can make it while retaining accuracy 😅 Mayne that'd make for a fun performance oriented stream 🤔
New video!
⬜⬜⬜⬜⬜
🟩🟨🟩⬜⬜
🟩🟩🟩🟩🟩
It's an exploration for writing a Wordle solver, with the challenge of not using the official list of Wordle answers (except as a test set), which is really just an excuse for an information theory lesson.
piped.video/v68zYyaEmEA
Woah, four weeks flew by! Late to post, but tomorrow's scheduled stream is still happening at 5pm UTC (everytimezone.com/s/a78a50c2). We'll take on the @flydotio distributed systems challenges in Rust: fly.io/dist-sys/. Won't do all of them, but it'll be fun to try a few!
Ready to take the next step to professional-level programming in #Rust? Rust for Rustaceans by @jonhoo will help you do more and learn the underlying mechanisms of @rustlang. Now shipping: nostarch.com/rust-rustaceans
I want to do another port-it-to-@rustlang live-coding stream — any suggestions? I'm specifically looking for useful data structures (like HdrHistogram) or developer tools (like flamegraph) where having them in Rust might provide value to the ecosystem.
First video in the "decrusted" series where we peel back the crust of the serde crate is now up: piped.video/BI_bHCGRgMY. I quite like the format, so expect to see more of these!
About time we did a Crust of Rust again! This *Saturday* at 5pm UTC (everytimezone.com/s/b4cd63f8) we'll look at the various collection types in @rustlang's std; their advantages, drawbacks, and common uses, as well as a bit about each of their implementations. Come one come all! 🦀📺
Today's stream on dispatch, trait objects, and dynamically sized types in @rustlang was quite the journey — I think we managed to get through at least most of the sticky bits in the ~2 hours 🎉 piped.video/xcygqF5LVmM
Just wrote the foreword to Rust for Rustaceans, and re-realized that this post from 2018 is one of the reasons why I started doing my videos, and in turn one of the reasons why I wrote the book. So thank you @QuietMisdreavus :)
We didn't actually make the cargo crate compile faster, but we did explore pretty much every tool that might help you reduce your @rustlang crate build time. And found that the tools still have some ways to go to produce actionable information 😅
piped.video/pMiqRM5ooNw
The video of our first steps into implementing "A Practical Wait-Free Simulation for Lock-Free Data Structures" in @rustlang is up! I miss these longer streams — they're a lot of fun. Still some way to go, but we made good progress! piped.video/Bw8-vvtA-E8
Perhaps unsurprisingly, I have a bunch of Opinions™ on work-life balance and time management. Lately, I've been particularly bugged by the common belief that employer incentives don't align with employee well-being. So, I wrote a thing (with graphs!): thesquareplanet.com/blog/abo…
Oh cool, Rust for Rustaceans is in the latest "Learn You Some Code" @humble Bundle! That means you can get it discounted together with a bunch of other tech books from @nostarch *and* support the Python Software Foundation in the process!
humblebundle.com/books/learn…
It'd be really fun to port Facebook's hazard pointer implementation in Folly to Rust. Would potentially be great for implementing concurrent algorithms in Rust going forward, since concurrent memory reclamation is hard. Maybe that's a good topic for the next stream?
Oh, right, I have a stream scheduled for tomorrow, don't I? 😅 Well, my streaming desk currently looks like this in preparation for my move to Norway (getting on the plane on Friday!), so no stream this week I'm afraid. But definitely Q&A soon!
I'm so excited that Helsing (where I now work if you missed the announcement) have become a Foundation sponsor! I think it's one of the key ways in which companies can help support the Rust ecosystem beyond purely technical contributions. And I got to ramble in the blog post 😅
Please join us in welcoming @helsingai to the Rust Foundation as our newest Silver Member!
Learn how Helsing is using #rustlang & why they joined the Foundation in this interview with Dr. Robert Fink (CTO) & @jonhoo (Principal Software Engineer).
foundation.rust-lang.org/new…
Stream time! On Friday (5p UTC: everytimezone.com/?t=608b488…), I'll cover ?Sized, fat pointers, dynamic vs. static dispatch, vtables, and trait objects in @rustlang. Maybe even coherence if we have time. I get a lot of questions about those, so figured let's do them all at once! 🥧🦀
The Crust of Rust episode on Rc/RefCell/Cell and Arc/RwLock/Mutex is now up — get it while it's hot! We covered @rustlang smart pointers and interior mutability, and even did a quick-dive into UnsafeCell and the Drop Check 😮 piped.video/watch?v=8O0Nt9qY…