mesh2325
Hands-on Rust: flappy does not compile due to outdates bytemuck
Hands on Rust: Effective Learning through 2D Game Development and Play
Page 48
Cargo.toml file in book:
[package]
name = "hello_bterm"
version = "0.1.0"
authors = ["Herbert Wolverson <herberticus@gmail.com>"]
edition = "2018"
[dependencies]
bracket-lib = "~0.8.1"
When calling cargo run, get the following error:
error: failed to download `bytemuck v1.12.1`
Caused by:
unable to get packages from source
Caused by:
failed to parse manifest at `C:\Users\Mike Chambers\.cargo\registry\src\github.com-1ecc6299db9ec823\bytemuck-1.12.1\Cargo.toml`
Caused by:
feature `resolver` is required
this Cargo does not support nightly features, but if you
switch to nightly channel you can add
`cargo-features = ["resolver"]` to enable this feature
rustup version 1.25.1 and rustc 1.50.0
Is there a specific version of rust we need to use to get this to work?
First Post!
herbert
Hi!
That’s a new one, haven’t run into that before! I’ll revisit this tomorrow when I have more time, but in the mean-time here’s two things to try:
Option 1: Lock the revision
Change the bracket-lib dependency to =0.8.1, and then run cargo update. That will force the package to the version that was live when the book released.
Option 2: Update Rust
At your command-line, issue rustup self update and then rustup update. I’m running rustup version 1.6.3 here, which definitely includes the new resolver system.
Hope that helps!
Popular Pragmatic Bookshelf topics
Other popular topics
Categories:
Sub Categories:
Popular Portals
- /elixir
- /rust
- /ruby
- /wasm
- /erlang
- /phoenix
- /keyboards
- /rails
- /python
- /js
- /security
- /go
- /swift
- /vim
- /clojure
- /emacs
- /haskell
- /java
- /svelte
- /onivim
- /typescript
- /kotlin
- /c-plus-plus
- /crystal
- /tailwind
- /react
- /gleam
- /ocaml
- /flutter
- /elm
- /vscode
- /ash
- /opensuse
- /html
- /centos
- /php
- /zig
- /deepseek
- /scala
- /lisp
- /textmate
- /sublime-text
- /react-native
- /nixos
- /debian
- /agda
- /kubuntu
- /arch-linux
- /django
- /deno
- /revery
- /ubuntu
- /spring
- /manjaro
- /nodejs
- /diversity
- /lua
- /julia
- /slackware
- /c






