tauri-apps / tauri

Build smaller, faster, and more secure desktop applications with a web frontend.
https://tauri.app
Apache License 2.0
78.1k stars 2.31k forks source link

[bug] Failed to install tauri v2.0 #9675

Closed jafioti closed 1 week ago

jafioti commented 1 week ago

Describe the bug

When I run cargo install tauri-cli --version "=2.0.0-beta.15", I recieve an error:

error[E0425]: cannot find function `apply_metadata` in module `schemars::_private`
   --> /Users/jafioti/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-utils-2.0.0-beta.13/src/config.rs:216:27
    |
216 |       schemars::_private::apply_metadata(
    |                           ^^^^^^^^^^^^^^ not found in `schemars::_private`

error[E0425]: cannot find function `apply_metadata` in module `schemars::_private`
   --> /Users/jafioti/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-utils-2.0.0-beta.13/src/config.rs:223:27
    |
223 |       schemars::_private::apply_metadata(
    |                           ^^^^^^^^^^^^^^ not found in `schemars::_private`

For more information about this error, try `rustc --explain E0425`.
error: could not compile `tauri-utils` (lib) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `tauri-cli v2.0.0-beta.15`, intermediate artifacts can be found at `/var/folders/23/6hcsrljj2wgdf6mj8r4f0m580000gn/T/cargo-installx7eM5o`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.

Reproduction

Run cargo install tauri-cli --version "=2.0.0-beta.15"

Expected behavior

I would expect this to correctly install the tauri cli.

Full tauri info output

N/A. Tauri isn't installed

Stack trace

No response

Additional context

No response

brainless commented 1 week ago

I just updated dependencies with cargo update and have the same error:

error[E0425]: cannot find function `apply_metadata` in module `schemars::_private`
   --> /home/brainless/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-utils-2.0.0-beta.13/src/config.rs:216:27
    |
216 |       schemars::_private::apply_metadata(
    |                           ^^^^^^^^^^^^^^ not found in `schemars::_private`

error[E0425]: cannot find function `apply_metadata` in module `schemars::_private`
   --> /home/brainless/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-utils-2.0.0-beta.13/src/config.rs:223:27
    |
223 |       schemars::_private::apply_metadata(
    |                           ^^^^^^^^^^^^^^ not found in `schemars::_private`

I am using Tauri v2 (2.0.0-beta.17).

I tried creating a new project with pnpm create tauri-app --beta and I get the same error after running pnpm install and pnpm tauri dev.

tebeco commented 1 week ago

can confirm, just got hit by that approximately at the same time as you. Though I'm new to Tauri so I though it was a me issue

pnpm install @tauri-apps/cli@next @tauri-apps/api@next
pnpm create tauri-app --beta

# because Android Studio and other crap
$env:NDK_HOME="C:\Users\user\AppData\Local\Android\Sdk\ndk\27.0.11718014"

pnpm tauri android init
pnpm tauri android dev
m1cl commented 1 week ago

Got the same error.