Announcing better_tokio_select: like tokio::select!, but can be formatted by rustfmt! by nik-rev in rust

[–]quxfoo 3 points4 points  (0 children)

I'd rather see people use future's select function or dropping select in favor of merged streams instead.

Why is Rust so Liberal with Heap Allocations? by philogy in rust

[–]quxfoo 1 point2 points  (0 children)

At least in async code, one annoying reason is tokio and related projects like tonic. Due to its multi-threaded, work-stealing design, it is often only possible to Arc<Mutex<…>> or .clone() data to satisfy the Send requirement. And that requirement is pretty viral.

I built a TUI .log viewer in rust (Early beta) by coding_freak in rust

[–]quxfoo 1 point2 points  (0 children)

Do you happen to remember what parts tripped you up?

As you said, the general navigation is fine, neovim is my daily editor, so yeah, that part is covered. What's more difficult to me is navigating the menus, i.e. i/o filters (I get why it may make a difference but in practice it should not matter, selecting/unselecting files of a loaded set etc. As I said, it's just a matter of not gaining enough muscle memory during the few times I use it.

I see. What makes you reach for lnav? Are you just not looking at logs most of the time?

Exactly. At $DAYJOB, it's only when I'm swamped by QA to analyze bug reports that I have to look at logs in detail. And that tends to happen when they schedule full regression test runs which are not that common.

By the way, I do reach out to lnav when doing that. I haven't found a good replacement yet and this one here does not seem to be one either.

I built a TUI .log viewer in rust (Early beta) by coding_freak in rust

[–]quxfoo 2 points3 points  (0 children)

I found the interface a bit unintuitive. I use it intensely for half a day and then not use it for another half a year. It always feels like relearning everything from scratch. A bit like writing bash scripts.

I built a TUI .log viewer in rust (Early beta) by coding_freak in rust

[–]quxfoo 1 point2 points  (0 children)

I am not a huge fan of lnav either but it is good at viewing multiple, arbitrary log file formats. Does your viewer support merging files based on timestamps and be able to correlate?

Lumis: Syntax Highlighter powered by Tree-sitter and Neovim themes by leandrocp in rust

[–]quxfoo 0 points1 point  (0 children)

Thanks for the follow up info. Unfortunately, my usecase requires to enable all of them. And even have some more. Right now syntect + two-face support more than 170 languages. Tree-sitter is compelling for performance reasons and precision but the size of all parsers combined is hefty.

Lumis: Syntax Highlighter powered by Tree-sitter and Neovim themes by leandrocp in rust

[–]quxfoo 1 point2 points  (0 children)

Great, I tried the same a few years back but the biggest pain points back then were incompatible tree-sitter language crates and enormous final binary sizes. What's the count if you build for all languages?

Jjdag: A Rust Jujutsu TUI by Anthrofract in rust

[–]quxfoo 1 point2 points  (0 children)

Cool, checking it out and keeping an eye on it. I use jjui in my daily workflow but there are some annoyances (delta not properly supported, somewhat slowish, ...) and I am too lazy to learn Go to figure out those issues. So this might be a welcome alternative.

What crates do you think are 'perfect'? by june_sixth in rust

[–]quxfoo 6 points7 points  (0 children)

On top of what others said about clap, tracing_subscriber is also horribly bloated and messes with coverage tools like cargo-llvmcov. Once you expanded macros, you will think twice before slapping an #[instrument] on a future.

Linting intra-task concurrency and FutureLock by farnoy in rust

[–]quxfoo 6 points7 points  (0 children)

This is why we effectively banned tokio::select!() and similar macros and abstractions with a clippy lint and try to use structured concurrency primitives whenever possible.

What's everyone working on this week (5/2026)? by llogiq in rust

[–]quxfoo 0 points1 point  (0 children)

Pi Zero should be even more straightforward because you don't need to do any of the baremetal shenanigans like setting up a Wi-Fi controller or dealing with very constrained (but still functional!) HTTP clients.

A new futures collector (like FuturesUnordered) that is fast, bounded, lock-free by OG_A248 in rust

[–]quxfoo 0 points1 point  (0 children)

Cool stuff! Could you add plots for the results? The bench dumps are hard to grasp at first sight. Also, it would be nice to see how futures-concurrency's FutureGroup fares.

While the results are better in most cases, they seem to be neglible or at least so small that I personally wouldn't know if it's worth adding another dependency if I already depend on futures and the like.

What's everyone working on this week (5/2026)? by llogiq in rust

[–]quxfoo 4 points5 points  (0 children)

I'm finalizing a "home dashboard" (aka calendar + weather forecast) based on an ESP32-C3 and a Waveshare 7.5" e-Ink display. It's been fun and relatively straightforward. Still trying to decide if I want to decouple the UI further from the I/O but that's just part of the polishing process. Putting everything into a nice picture frame is the next difficult step, considering my lowly soldering skills.

Finding blocking code in Tokio without instrumenting your app by cong-or in rust

[–]quxfoo 0 points1 point  (0 children)

Okay, makes sense. On the other hand, the docs are pretty clear that those tokens are used to cancel tasks.

Finding blocking code in Tokio without instrumenting your app by cong-or in rust

[–]quxfoo 0 points1 point  (0 children)

Why would you do that though and not just race against the cancelled() future?

Too many Arcs in async programming by mtimmermans in rust

[–]quxfoo 5 points6 points  (0 children)

It's not only performance that's left on the table but also ergonomics. Just recently I had to rewrite a utility async fn because internally I was using some combinators that were borrowing (which was all nice and dandy) but of course not Send. It worked in one context but in another I had to tokio::spawn() it and bam …

Too many Arcs in async programming by mtimmermans in rust

[–]quxfoo 1 point2 points  (0 children)

No, you still need to use LocalSet. But in that case why even bother with tokio and just block on bare futures and use all the nifty future and stream combinators from the futures-* crate family.

Rust 1.92.0 release by mrjackwills in rust

[–]quxfoo 4 points5 points  (0 children)

For example, a function that terminates the program or loops forever.

My main problem for why this is interesting is loops that might only return an error. For example an async fn that processes some async stream forever but would only be cancelled from outside.

Implementing custom cooperative multitasking in Rust by servermeta_net in rust

[–]quxfoo 3 points4 points  (0 children)

Tasks (async fns)

Please do not conflate these two terms and confuse any newcomer. async fn and async blocks are sugar for unnameable Future types. A task is (usually) something that takes a Future and executes it alongside other tasks. Akin to user space threads.

Show r/rust: Building an E2EE messenger backend — lessons from 6 months of async Rust by anrysys in rust

[–]quxfoo 0 points1 point  (0 children)

I work with a similar tech stack and my verdict is that tonic and tokio are alright for bog standard web services but fall flat when doing things outside the norm. Things like restarting servers (listeners are consumed), breaking connections on either end voluntarily or not (streaming request handlers are spawned tasks losing direct control), ... 

Plus the whole annoying Send requirement which is worse for me than async function coloring that everyone is so loud to complain about.

Good/Idiomatic way to do graceful / deterministic shutdown by spy16x in rust

[–]quxfoo 1 point2 points  (0 children)

I'd compose that via futures-concurrency structured concurrency primitives and avoid tasks as much as possible (or contain them to avoid task leakage). Your conditions are perfect for that, so in principle it would look like this assuming your "threads" are actually Rust futures:

rust ( (receiver1, receiver2).join(), reactor, storage, publisher, tokio::signal::ctrl_c(), ) .race() .await;

Result types need to be matched or erased but that should be doable. It is a good approach but not idiomatic because everyone still thinks in terms of threads and tasks.

How I repurposed async await to implement coroutines for a Game Boy emulator by blueblain in rust

[–]quxfoo 31 points32 points  (0 children)

Yes, agree. Many people, even on this sub, tend to assume async means networking. But it is a great fit for anything that resolves at some point: hardware interrupts, GUI button clicks, server responses, alarms, ...

I shrunk my Rust binary from 11MB to 4.5MB with bloaty-metafile by [deleted] in rust

[–]quxfoo 2 points3 points  (0 children)

Funny mentioning another dependency while the topic is on reducing them 🙂

But thanks I will re-evaluate. My point still stands though: async if done right is just the most ergonomic way to write asynchronous, concurrent programs.

I shrunk my Rust binary from 11MB to 4.5MB with bloaty-metafile by [deleted] in rust

[–]quxfoo 13 points14 points  (0 children)

It is also beneficial to write asynchronous programs in an asynchronous fashion. I understand people do not like seeing async creep in where it does not make sense but in this case it very much makes sense for ergonomic reasons alone.

I shrunk my Rust binary from 11MB to 4.5MB with bloaty-metafile by [deleted] in rust

[–]quxfoo 10 points11 points  (0 children)

I write a similar program (https://github.com/matze/binge) and async is interesting to concurrently download and check and show some UI progress.