Skip to content

Fix mdBook install failing on cached cargo bin - #5

Merged
r007 merged 1 commit into
mainfrom
fix/rust-training-upstream-links
Oct 10, 2026
Merged

r007 merged 1 commit into
mainfrom
fix/rust-training-upstream-links

Conversation

@r007

@r007 r007 commented Oct 10, 2026

Copy link
Copy Markdown
Owner

The cargo cache restored ~/.cargo/bin without cargo's install records (.crates.toml and .crates2.json). cargo install then found mdbook in the destination it did not track and failed with "binary mdbook already exists in destination".

Cache the records together with the binaries, and bump the cache key to books-v2: GitHub caches are not overwritten once saved, so the old entry without the records would keep being restored under the same key.

Что изменено и зачем

Проверка

  • cargo xtask build собирает все книги без ошибок
  • python3 scripts/check_links.py site не находит битых ссылок
  • Новые ссылки на книги ведут в этот репозиторий, а не на английские оригиналы
  • Термины соответствуют глоссарию из CONTRIBUTING.md

The cargo cache restored ~/.cargo/bin without cargo's install records
(.crates.toml and .crates2.json). cargo install then found mdbook in
the destination it did not track and failed with "binary `mdbook`
already exists in destination".

Cache the records together with the binaries, and bump the cache key
to books-v2: GitHub caches are not overwritten once saved, so the old
entry without the records would keep being restored under the same key.

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
@r007
r007 merged commit 1e09cbd into main Oct 10, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant