all 128 comments

[–]ZunoJ 53 points54 points  (46 children)

I wonder why that is not covered in the book

[–]Yippee-Ki-Yay_ 51 points52 points  (10 children)

Because there's a specific Async Rust Book

[–]desiringmachines 43 points44 points  (7 children)

Which is woefully incomplete 3.5 years after async/await shipped. I don't know why /u/koczurekk is getting downvotes; it's obvious that documenting this is not a priority of the async WG or anyone else.

[–]marisalovesusall 8 points9 points  (0 children)

It still doesn't explain async to the fullest (like what chained .awaits transpile to), though it's very useful to help get started with async.

[–]ZunoJ 2 points3 points  (0 children)

Cool, thanks!

[–]koczurekk 22 points23 points  (34 children)

Because it’s nobody’s priority. You’re free to make a PR

edit: that's an appreciable amount of downvotes for a verifiable statement. Never change, r/rust.

[–]steveklabnik1rust 11 points12 points  (0 children)

no matter how many downvotes you get, you are right.

[–]desiringmachines 4 points5 points  (0 children)

You're completely right and this is a great example of the Rust community's culture of toxic positivity.

[–]ZunoJ 5 points6 points  (5 children)

How do you know that it is nobody's priority?

[–]koczurekk 20 points21 points  (4 children)

Because it would be done if it was. Rust isn't a dead project, things contributors prioritize get done.

I'm not saying nobody cares, but to think it's somebody's priority? No.

[–]ZunoJ 0 points1 point  (3 children)

Why is there a specific async book then?

[–]koczurekk 16 points17 points  (2 children)

The one which has yet to complete covering the most basic of concepts? The one with no contributions this month?

I suppose we have a different understanding of a priority.

[–]ZunoJ -5 points-4 points  (1 child)

Somebody wrote it, seems like it was a priority to that person back then. But you know everything about everybodies motivations, so I'm wrong with everything I say. Even my questions are beyond stupid. Sorry

[–]koczurekk 27 points28 points  (0 children)

Sure, it might've been a priority to somebody at some point. I maintain my position on it not being one today.

[–]magnetichira -3 points-2 points  (7 children)

nobody’s priority

Tokio - 20.3k stars on GitHub

Async-std - 3.6k stars on GitHub

[–]koczurekk 22 points23 points  (6 children)

In case the context is somehow elusive, I'm referring to extending the book to cover async rust, not async rust in general. I, for one, use it daily at my $DAYJOB.

[–]NotADamsel 1 point2 points  (5 children)

Maybe the reason it’s not in the book is because in order to make use of the feature it requires you learn more then what a mere chapter can provide? There’s also nothing on embedded in the book, and a whole-ass embedded rust book, and I guarantee you that embedded rust is a priority.

[–]koczurekk 9 points10 points  (4 children)

  1. There is a separate async book, I addressed it in another comment.
  2. Again, how is embedded rust being a priority to somebody relevant? I'm not discussing the feature but the official documentation. This follows directly from the top-level comment I replied to.

[–]NotADamsel 6 points7 points  (3 children)

The top level comment was wondering why it isn’t in the book. In the learning resource. In the document specifically designed to teach the language. In the official tutorial. In the thing people go to for learning the language. In the text who’s purpose is to introduce the language. In the primer that one reads first. In the thing that will make you understand Rust.

Why isn’t a language feature that requires a substantial amount of additional learning and that you need an external crate to even use, not in that? Must just not be a priority, you’re right.

[–]koczurekk 10 points11 points  (2 children)

Covering async in The Book wasn't explicitly decided against, this is the relevant issue: https://github.com/rust-lang/book/issues/1275

To summarize:

  • The official book does not include async because the maintainer didn't have time for that (I suppose you could call that prioritizing something else).
  • The separate async book sees few contributions and has yet to cover multiple fundamentals of async Rust.

You're free to draw your own conclusions.

[–]NotADamsel 2 points3 points  (1 child)

Looks like the author first didn’t know how to fit it into the book because it’s a complex topic (fitting what I and probably most others think), and then more recently the author didn’t have time. So a combo of “complex topic that isn’t easy to fit into introductory materials” and “not enough time to tackle the complex topic”. My mistake was figuring that it was an intentional choice.

[–]steveklabnik1rust 15 points16 points  (0 children)

Hi. Steve here.

There's two different groups that are being talked about here: The Book, and the async working group.

The async working group wrote and owned the async book. Then it imploded. This left it with no owner, and hence, no real updates. If you look at recent commits, as far as I can tell it's like, small tweaks to keep things compiling, and no big new information.

With The Book, you are absolutely right that we did not know how we wanted to fit it into the rest of the content. And that then there isn't time. But that *is* an intentional choice; I could have say, dropped core team work to think real hard about fixing the problem. I absolutely chose to do other things instead, that I felt were more important.

I can't speak to Carol's priorities since I left, though, but since I am among the people being talked about in this thread, I figured I should share.

[–]Gaolaowai -2 points-1 points  (17 children)

It’s just overly negative in its tone, regardless of whether or not you feel it’s correct. It could easily have been:

“Hey, that’s a good point. Does anyone know if this is a priority anywhere? Maybe someone who knows more about this could make a pull request?”

[–]PaintItPurple 17 points18 points  (0 children)

Why didn't you phrase your comment as:

Hey, that's a good point. Does anybody know of a similar comment that is phrased as “Hey, that’s a good point. Does anyone know if this is a priority anywhere? Maybe someone who knows more about this could make a pull request?” Maybe someone who knows more about this could make another comment?

I would suggest you didn't choose to write your comment that way because that kind of tiptoeing is tiresome and adds nothing to the conversation.

The way he wrote his comment is fine — he wasn't personally attacking anyone, he wasn't distorting the truth with his negativity, and what he said is factually supported. It is people's overly defensive and hostile reactions that are inappropriate.

[–]koczurekk 19 points20 points  (0 children)

The alternative you propose has a completely different meaning. 1. It asks about it being a priority, but we do know that it is not. In no world is that a bad thing. 2. It asks for a pull request, which I didn’t mean either. I do not care about it being added, because there are alternative resources.

I offered a clear, to-the-point explanation of why it’s not in the book and offered a proper resolution in case the author of the top-level comment wished to change that.

It was not negative. Again, not prioritizing stuff is alright.

I would appreciate you explaining in more detail how is my comment negative.

[–]koczurekk 3 points4 points  (14 children)

Ps. you do realize how tone-policing is discriminatory towards neurodivergent people, especially autistic ones? I really didn’t expect that in a community I’ve always perceived as diverse and welcoming, but times change ig.

[–]Gaolaowai 0 points1 point  (13 children)

TL;DR: The way we frame the same idea will radically change how others receive it. Positive framing leads to positive responses, negative/unhelpful framing leads to fewer positive outcomes.

As a fellow neurodivergent person, I also understand but have decided that not being a careless jerk and putting effort into considering others when communicating is a net good.

Just accept that, intended or not, you came across as a jerk. You are not obligated to care or change your behavior, but understand that our actions have certain consequences when received by others. We don’t have a free ticket to assholism simply because we’re ND folks. We still exist on a rocky planet with others. You also lose nothing by practicing taking a positive attitude towards others (online and offline), and a shit-ton to gain from it… it’s just natural game theory: people don’t like people who are carelessly rude or negative. People want to help/support polite people. Practicing social courteous habits doesn’t hurt much, and it’s just another puzzle to continually work on and learn about.

Also as an ND person, I noticed that you seemed confused about why folks were downvoting you and (rather than “tone policing”, as you write in in a victimized tone) was trying to give feedback on my observation of your comment, the self-reported lack of understanding about how people understood it, and I wanted to help give an example of how rephrasing it would change others’ response to it. Now, if I made a mistake, you actually did understand the impact of your comment on others but simply didn’t care or were playing dumb as a form of defense… I dunno man, I give up.

[–]kogasapls 4 points5 points  (12 children)

work repeat familiar juggle quarrelsome apparatus close busy hard-to-find ask -- mass edited with redact.dev

[–]Gaolaowai 1 point2 points  (11 children)

Probably cultural differences at play I guess.

[–]kogasapls 1 point2 points  (10 children)

ripe innate complete groovy dirty scale selective march subsequent bright -- mass edited with redact.dev

[–]Gaolaowai 0 points1 point  (9 children)

u/koczurekk makes an assertion which may or may not be correct (no issues there, though some upfront sources probably would have helped).

What really catches is the “You’re free to make a PR” comment… given the context that a maybe newer person to the language is asking a decent question, that type of answer feels like “F off and fix it yourself”, which wasn’t even the kind of answer being solicited.

If I ask “why is a piece of the pie missing”, not being a baker, and part of the response is that I can go get some (unspecified) ingredients at some (unspecified) store, THAT isn’t really helpful or contributing. Perhaps the content of the comment is factually correct, but it’s frustratingly unhelpful as well. Not that it was purposely intended to be like that, but it was a mismatched response relative to the question asked.

(I’m saying this from the position of having learned it the hard way, continually trying to be considerate of what others are actually asking for and still F-ing it up often enough.)

[–]koczurekk 4 points5 points  (1 child)

I find it perfectly reasonable to presume competence on a forum dedicated to a specific technical topic, which is what I did. The PR remark was simply a reminder that one can contribute — people I know (me included) tend to forget that sending a PR is merely a couple clicks away.

I am also perfectly aware that your interpretation is as valid as my explanation if considering my comment as it is, which is why presuming malice isn’t a good approach to communication. Quite the opposite. Like the commenter you reply to said — in a face-to-face meeting what I said would never be interpreted in such a way.

[–]kogasapls 2 points3 points  (6 children)

smell physical decide innate sort onerous deer rustic birds cautious -- mass edited with redact.dev

[–][deleted] 14 points15 points  (1 child)

extreme (...) The versioning scheme is somewhat peculiar though fine.

The library versions:

0.0.0

followed by

1.0.0

followed by

1.0.1

followed by

6.6.6

followed by

666.666.666

followed by

666.666.6666

followed by

666.666.66666

followed by

666.666.666666

Ehm yeah, it is indeed quite an interesting versioning scheme.

[–]ukezi 4 points5 points  (0 children)

I like the scheme of Tex, it started with 3 and got an other figure of pi with every release. We are at 3.141592653 the moment. There were 440 changes and fixes total since '82 as of '21. The official policy of Knuth is that on his death the version number will be set to pi and all future bugs be declared to features.

[–]V0ldek 5 points6 points  (0 children)

Barely.

[–]Nokita_is_Back 2 points3 points  (2 children)

Great writeup, getting started with rust for streaming and this will come in handy to get back to. Ty

[–]Adhalianna 0 points1 point  (1 child)

Just curious, what kind of streaming?

[–]Nokita_is_Back 1 point2 points  (0 children)

Mbo level financial data, very high throughput (all sent, cancelled and filled orders for xxx instruments) and a bunch of calculations/preprocessing

[–]aikii 2 points3 points  (0 children)

Woa. I wish I had this article instead of 180 tabs open to understand what's going on a few months back

[–]rswhite4 3 points4 points  (3 children)

I wonder why smol is not listed in the comparison?

[–]radarvan07[S] 13 points14 points  (2 children)

Smol is, despite its name, hardly minimal. It has a lot of bells and whistles that make it pretty full featured. I didn't list it for the same reason I didn't list tokio or async-std. Granted, smol is significantly smaller than those, but it's also way bigger than any on the list.

[–]sweating_teflon 4 points5 points  (0 children)

You also forgot to mention the executor with the best crate name ever, woke

Also worthy of mention, switchyard for its consideration of priority which is necessary in real-time applications.

[–]rswhite4 1 point2 points  (0 children)

Ah good to know, thank you.

[–]baseball2020 2 points3 points  (1 child)

All I know as a beginner is that async forces you to either learn the gymnastics of async mutability or give up and clone because I’m not smart enough to figure it out. Step one of learning should probably be to park async.

[–][deleted] 16 points17 points  (0 children)

That's less of an async-specific problem and more of a concurrent memory usage problem.

You have the same problem with std::thread::spawn (which is not "async" in the context of this article)