Replies: 4 comments 2 replies
-
What version of cargo-leptos are you running? There were breaking changes
in an internal rust crate that created a need to patch cargo-leptos. I
believe the working version is 0.1.11.
…On Thu, Jul 13, 2023, 5:33 AM Vladimir Pesterev ***@***.***> wrote:
*Describe the bug*
I followed this guide <https://github.com/leptos-rs/leptos#cargo-leptos>
and tried to compile the starter template (cargo leptos new --git
https://github.com/leptos-rs/start) but encountered some issues.
$ cargo leptos watch
Compiling quote v1.0.29
Compiling proc-macro2 v1.0.64
Compiling unicode-ident v1.0.10
Compiling version_check v0.9.4
Compiling autocfg v1.1.0
Compiling once_cell v1.18.0
Compiling thiserror v1.0.43
Compiling serde v1.0.171
Compiling syn v1.0.109
Compiling wasm-bindgen-shared v0.2.87
Compiling cfg-if v1.0.0
Compiling log v0.4.19
error[E0463]: can't find crate for `core`
|
= note: the `wasm32-unknown-unknown` target may not be installed
= help: consider downloading the target with `rustup target add wasm32-unknown-unknown`
error[E0463]: can't find crate for `compiler_builtins`
For more information about this error, try `rustc --explain E0463`.error: could not compile `cfg-if` (lib) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
Notify watching folders assets, style, src
*Leptos Dependencies*
The Leptos dependencies and features from my Cargo.toml:
leptos = { version = "0.4", features = ["nightly"] }leptos_meta = { version = "0.4", features = ["nightly"] }leptos_actix = { version = "0.4", optional = true }leptos_router = { version = "0.4", features = ["nightly"] }
*To Reproduce*
Steps to reproduce the behavior:
1. rustup toolchain install nightly
2. rustup default nightly
3. rustup target add wasm32-unknown-unknown
4. cargo install cargo-leptos
5. cargo leptos new --git https://github.com/leptos-rs/start (specify
any name for the project)
6. cd <project_name>
7. cargo leptos watch
*Expected behavior*
I want the starter template to be compilelable.
*Screenshots*
[image: image]
<https://user-images.githubusercontent.com/8786922/253230920-26ba9cf1-810f-409e-b616-e2ae45449984.png>
*Additional context*
Add any other context about the problem here.
My active toolchain:
installed targets for active toolchain
--------------------------------------
aarch64-apple-darwin
wasm32-unknown-unknown
active toolchain
----------------
nightly-aarch64-apple-darwin
rustc 1.73.0-nightly (33a2c2487 2023-07-12)
1. Yes, I tried to reinstall my nightly toolchain (currently, it is
1.73.0-nightly).
2. Yes, I tried to run rustup target add wasm32-unknown-unknown (it's
installed).
3. I tried to use Trunk and got the same errors.
—
Reply to this email directly, view it on GitHub
<#1336>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AOO63SYL7NEEVGTD7KVKYQ3XP66E3ANCNFSM6AAAAAA2IVEXIQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
The compiler error is pretty straightforward
What's not straightforward is why this is happening. I've seen people have similar issues once or twice before, in cases in which they had two separate Rust toolchains installed (for example, I think one of them had Rust installed both via Homebrew and via the Rust installer) and so they were adding the WASM target for one of them and not the other somehow. Not sure what the exact case is for you. I guess you can always try |
Beta Was this translation helpful? Give feedback.
-
cargo-leptos 0.1.11 |
Beta Was this translation helpful? Give feedback.
-
@pesterev What happens when you run |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Describe the bug
I followed this guide and tried to compile the starter template (
cargo leptos new --git https://github.com/leptos-rs/start
) but encountered some issues.Leptos Dependencies
The Leptos dependencies and features from my
Cargo.toml
:To Reproduce
Steps to reproduce the behavior:
Expected behavior
I want the starter template to be compilelable.
Screenshots

Additional context
Add any other context about the problem here.
My active toolchain:
1.73.0-nightly
).rustup target add wasm32-unknown-unknown
(it's installed).csr
feature and build usingTrunk
, but got the same errors. I feel this issue is related to my toolchain or my local configuration.cargo leptos --version
=>cargo-leptos 0.1.11
Beta Was this translation helpful? Give feedback.
All reactions