#Upgrade from v1 to v2 causes errors with wry

4 messages · Page 1 of 1 (latest)

fiery gust
#

I tried to upgrade my v1 project to v2 via the cli. The action completed successfully however when compiling i now receive errors from wry:

error[E0046]: not all trait items implemented, missing: `hide`, `show`, `clear_all_browsing_data`
    --> /Users/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.0.0-rc.2/src/lib.rs:1298:1
     |
1298 | impl<T: UserEvent> WebviewDispatch<T> for WryWebviewDispatcher<T> {
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `hide`, `show`, `clear_all_browsing_data` in implementation
     |
     = help: implement the missing item: `fn hide(&self) -> Result<(), tauri_runtime::Error> { todo!() }`
     = help: implement the missing item: `fn show(&self) -> Result<(), tauri_runtime::Error> { todo!() }`
     = help: implement the missing item: `fn clear_all_browsing_data(&self) -> Result<(), tauri_runtime::Error> { todo!() }`

error[E0046]: not all trait items implemented, missing: `is_enabled`, `set_enabled`, `set_theme`
    --> /Users/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.0.0-rc.2/src/lib.rs:1538:1
     |
1538 | impl<T: UserEvent> WindowDispatch<T> for WryWindowDispatcher<T> {
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `is_enabled`, `set_enabled`, `set_theme` in implementation
     |
     = help: implement the missing item: `fn is_enabled(&self) -> Result<bool, tauri_runtime::Error> { todo!() }`
     = help: implement the missing item: `fn set_enabled(&self, _: bool) -> Result<(), tauri_runtime::Error> { todo!() }`
     = help: implement the missing item: `fn set_theme(&self, _: Option<tauri_utils::Theme>) -> Result<(), tauri_runtime::Error> { todo!() }`

error[E0046]: not all trait items implemented, missing: `set_theme`
    --> /Users/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.0.0-rc.2/src/lib.rs:2174:1
     |
2174 | impl<T: UserEvent> RuntimeHandle<T> for WryHandle<T> {
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `set_theme` in implementation
     |
     = help: implement the missing item: `fn set_theme(&self, _: Option<tauri_utils::Theme>) { todo!() }`

error[E0046]: not all trait items implemented, missing: `set_theme`
    --> /Users/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.0.0-rc.2/src/lib.rs:2358:1
     |
2358 | impl<T: UserEvent> Runtime<T> for Wry<T> {
     | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `set_theme` in implementation
     |
     = help: implement the missing item: `fn set_theme(&self, _: Option<tauri_utils::Theme>) { todo!() }`

steps followed:

cargo install tauri-cli --version "^2.0.0-rc" --locked
cargo tauri migrate
cargo tauri dev
dire monolith
#

Disclaimer : I am not expert in Tauri and is user like you have no knowledge about inner working of tauri.
latest tauri have name = "tauri-runtime-wry" at version = "2.0.0-rc.14" but your looks rc2 ````/Users/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.0.0-rc.2/src/lib.rs try to run again see if it will updatecargo install tauri-cli --version "^2.0.0-rc" --locked```

#

I hope you have backup or using git.

fiery gust
#

ah this didnt work but i got it working after doing a cargo clean, cargo update and then force rebuilding it