Bumps the minor group with 2 updates: [tokio](https://github.com/tokio-rs/tokio) and [tempfile](https://github.com/Stebalien/tempfile). Updates `tokio` from 1.44.2 to 1.45.1 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/tokio-rs/tokio/releases">tokio's releases</a>.</em></p> <blockquote> <h2>Tokio v1.45.1</h2> <h1>1.45.1 (May 24th, 2025)</h1> <p>This fixes a regression on the wasm32-unknown-unknown target, where code that previously did not panic due to calls to <code>Instant::now()</code> started failing. This is due to the stabilization of the first time-based metric.</p> <h3>Fixed</h3> <ul> <li>Disable time-based metrics on wasm32-unknown-unknown (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7322">#7322</a>)</li> </ul> <p><a href="https://redirect.github.com/tokio-rs/tokio/issues/7322">#7322</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7322">tokio-rs/tokio#7322</a></p> <h2>Tokio v1.45.0</h2> <h3>Added</h3> <ul> <li>metrics: stabilize <code>worker_total_busy_duration</code>, <code>worker_park_count</code>, and <code>worker_unpark_count</code> (<a href="https://redirect.github.com/tokio-rs/tokio/issues/6899">#6899</a>, <a href="https://redirect.github.com/tokio-rs/tokio/issues/7276">#7276</a>)</li> <li>process: add <code>Command::spawn_with</code> (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7249">#7249</a>)</li> </ul> <h3>Changed</h3> <ul> <li>io: do not require <code>Unpin</code> for some trait impls (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7204">#7204</a>)</li> <li>rt: mark <code>runtime::Handle</code> as unwind safe (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7230">#7230</a>)</li> <li>time: revert internal sharding implementation (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7226">#7226</a>)</li> </ul> <h3>Unstable</h3> <ul> <li>rt: remove alt multi-threaded runtime (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7275">#7275</a>)</li> </ul> <p><a href="https://redirect.github.com/tokio-rs/tokio/issues/6899">#6899</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/6899">tokio-rs/tokio#6899</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7276">#7276</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7276">tokio-rs/tokio#7276</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7249">#7249</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7249">tokio-rs/tokio#7249</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7204">#7204</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7204">tokio-rs/tokio#7204</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7230">#7230</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7230">tokio-rs/tokio#7230</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7226">#7226</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7226">tokio-rs/tokio#7226</a> <a href="https://redirect.github.com/tokio-rs/tokio/issues/7275">#7275</a>: <a href="https://redirect.github.com/tokio-rs/tokio/pull/7275">tokio-rs/tokio#7275</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="3768696d92
"><code>3768696</code></a> chore: prepare Tokio v1.45.1 (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7359">#7359</a>)</li> <li><a href="421a7b001c
"><code>421a7b0</code></a> rt: do not track time-based metrics on wasm32-unknown-unknown (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7322">#7322</a>)</li> <li><a href="b1bdb3c57b
"><code>b1bdb3c</code></a> ci: update macros_type_mismatch for Rust 1.87.0 (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7339">#7339</a>)</li> <li><a href="00754c8f9c
"><code>00754c8</code></a> chore: prepare Tokio v1.45.0 (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7308">#7308</a>)</li> <li><a href="1ae9434e8e
"><code>1ae9434</code></a> time: revert "use sharding for timer implementation" related changes (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7226">#7226</a>)</li> <li><a href="8895bba448
"><code>8895bba</code></a> ci: Test AArch64 Windows (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7288">#7288</a>)</li> <li><a href="48ca254d92
"><code>48ca254</code></a> time: update <code>sleep</code> documentation to reflect maximum allowed duration (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7302">#7302</a>)</li> <li><a href="a0af02a396
"><code>a0af02a</code></a> compat: add more documentation to <code>tokio_util::compat</code> (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7279">#7279</a>)</li> <li><a href="0ce3a1188a
"><code>0ce3a11</code></a> metrics: stabilize <code>worker_park_count</code> and <code>worker_unpark_count</code> (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7276">#7276</a>)</li> <li><a href="1ea9ce11d4
"><code>1ea9ce1</code></a> ci: fix cfg!(miri) declarations in tests (<a href="https://redirect.github.com/tokio-rs/tokio/issues/7286">#7286</a>)</li> <li>Additional commits viewable in <a href="https://github.com/tokio-rs/tokio/compare/tokio-1.44.2...tokio-1.45.1">compare view</a></li> </ul> </details> <br /> Updates `tempfile` from 3.19.1 to 3.20.0 <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md">tempfile's changelog</a>.</em></p> <blockquote> <h2>3.20.0</h2> <p>This release mostly unifies the behavior/capabilities around "keeping" temporary files:</p> <ul> <li>Rename <code>Builder::keep(bool)</code> (via deprecation) to <code>Builder::disable_cleanup(bool)</code> to make it clear that behaves differently from <code>NamedTempFile::keep()</code>. The former disables automatic cleanup while the latter <em>consumes</em> the <code>NamedTempFile</code> object entirely and unsets the "temporary file" attribute (on Windows).</li> <li>Rename <code>TempDir::into_path</code> (via deprecation) to <code>TempDir::keep</code> to mirror <code>NamedTempFile::keep</code>.</li> <li>Add <code>TempDir::disable_cleanup</code>, <code>NamedTempFile::disable_cleanup</code>, and <code>TempPath::disable_cleanup</code> making it possible to disable automatic cleanup in-place <em>after</em> creating a temporary file/directory (equivalent to calling <code>Builder::disable_cleanup</code> before creating the file/directory).</li> </ul> <p>Additionally, it adds a few spooled temporary file features:</p> <ul> <li>Add <code>SpooledTempFile::into_file</code> for turning a <code>SpooledTempFile</code> into a regular unnamed temporary file, writing it to the backing storage ("rolling" it) if it was still stored in-memory.</li> <li>Add <code>spooled_tempfile_in</code> and <code>SpooledTempFile::new_in</code> methods for creating spooled temporary files in a specific directory. This makes it possible to choose the backing device for your spooled temporary file which is rather important on Linux where the default temporary directory is likely backed by memory (defeating the entire point of having a spooled temporary file).</li> </ul> <p>Finally, this release improves documentation, especially the top-level documentation explaining which temporary file type to use.</p> <p><strong>BREAKING</strong> for those with <code>deny(warnings)</code>:</p> <ul> <li><code>Builder::keep</code> deprecated in favor of <code>Builder::disable_cleanup</code>.</li> <li><code>TempDir::into_path</code> is deprecated in favor of <code>TempDir::keep</code>.</li> </ul> <p><strong>BREAKING</strong>:</p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="99ffea61ad
"><code>99ffea6</code></a> chore: release v3.20.0 (<a href="https://redirect.github.com/Stebalien/tempfile/issues/358">#358</a>)</li> <li><a href="bd2b267442
"><code>bd2b267</code></a> feat: make it possible to disable cleanup in-place after creation (<a href="https://redirect.github.com/Stebalien/tempfile/issues/355">#355</a>)</li> <li><a href="3b30099abd
"><code>3b30099</code></a> ci: really check docs for warnings (<a href="https://redirect.github.com/Stebalien/tempfile/issues/357">#357</a>)</li> <li><a href="f701f52456
"><code>f701f52</code></a> ci: check docs (<a href="https://redirect.github.com/Stebalien/tempfile/issues/356">#356</a>)</li> <li><a href="d34afe99fd
"><code>d34afe9</code></a> doc: improve SpooledData documentation</li> <li><a href="6deb42e04c
"><code>6deb42e</code></a> doc: make it easier to pick the correct tempfile constructor/type</li> <li><a href="e284782c6c
"><code>e284782</code></a> feat: allow creating spooled temporary files in a specific directory (<a href="https://redirect.github.com/Stebalien/tempfile/issues/353">#353</a>)</li> <li><a href="07edc310a5
"><code>07edc31</code></a> feat: implement <code>SpooledTempFile::into_file</code> (<a href="https://redirect.github.com/Stebalien/tempfile/issues/352">#352</a>)</li> <li><a href="b1223553bb
"><code>b122355</code></a> fix: add must_use attribute to TempDir::keep (<a href="https://redirect.github.com/Stebalien/tempfile/issues/351">#351</a>)</li> <li><a href="cbd1e976e1
"><code>cbd1e97</code></a> feat: rename <code>TempDir::into_path</code> to <code>TempDir::keep</code> (<a href="https://redirect.github.com/Stebalien/tempfile/issues/349">#349</a>)</li> <li>Additional commits viewable in <a href="https://github.com/Stebalien/tempfile/compare/v3.19.1...v3.20.0">compare view</a></li> </ul> </details> <br /> Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore <dependency name> major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself) - `@dependabot ignore <dependency name> minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself) - `@dependabot ignore <dependency name>` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself) - `@dependabot unignore <dependency name>` will remove all of the ignore conditions of the specified dependency - `@dependabot unignore <dependency name> <ignore condition>` will remove the ignore condition of the specified dependency and ignore conditions </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Comprehensive Rust 🦀
This repository has the source code for Comprehensive Rust 🦀, a multi-day Rust course developed by the Android team. The course covers all aspects of Rust, from basic syntax to generics and error handling. It also includes deep dives on Android, Chromium, bare-metal, and concurrency.
Read the course at https://google.github.io/comprehensive-rust/.
Course Format and Target Audience
The course is used internally at Google when teaching Rust to experienced software engineers. They typically have a background in C++ or Java.
The course is taught in a classroom setting and we hope it will be useful for others who want to teach Rust to their team. The course will be less useful for self-study since you miss out on the discussions happening in the classroom. You don't see the questions and answers and you don't see the compiler errors we trigger when going through the code samples. We hope to improve on this via speaker notes and by publishing videos.
Press
Articles and blog posts from around the web which cover Comprehensive Rust:
- 2023-09-08: Teaching Rust in 5 days. Comprehensive Rust was used as a base for a 5-day university class on Rust.
- 2023-09-21: Scaling Rust Adoption Through Training. We published a blog post with details on the development of the course.
- 2023-10-02: In Search of Rust Developers, Companies Turn to In-House Training. About how Microsoft, Google, and others are training people in Rust.
- 2024-10-18: Rust Training at Scale | Rust Global @ RustConf 2024. What Google learnt from teaching Comprehensive Rust for more than two years.
Setup
The course is built using a few tools:
- mdbook
- mdbook-svgbob
- mdbook-i18n-helpers and i18n-report
- mdbook-exerciser
- mdbook-course
- mdbook-linkcheck2
First install Rust by following the instructions on https://rustup.rs/. Then clone this repository:
git clone https://github.com/google/comprehensive-rust/
cd comprehensive-rust
Then install these tools with:
cargo xtask install-tools
Commands
Here is a summary of the various commands you can run in the project.
Command | Description |
---|---|
cargo xtask install-tools |
Install all the tools the project depends on. |
cargo xtask serve |
Start a web server with the course. You'll find the content on http://localhost:3000. |
cargo xtask rust-tests |
Test the included Rust snippets. |
cargo xtask web-tests |
Run the web driver tests in the tests directory. |
cargo xtask build |
Create a static version of the course in the book/ directory. Note that you have to separately build and zip exercises and add them to book/html. To build any of the translated versions of the course, run MDBOOK_BOOK__LANGUAGE=xx mdbook build -d book/xx where xx is the ISO 639 language code (e.g. da for the Danish translation). TRANSLATIONS.md contains further instructions. |
Note
On Windows, you need to enable symlinks (
git config --global core.symlinks true
) and Developer Mode.
Contributing
We would like to receive your contributions. Please see CONTRIBUTING.md for details.
Contact
For questions or comments, please contact Martin Geisler or start a discussion on GitHub. We would love to hear from you.