#mismatched types in tauri utils

7 messages · Page 1 of 1 (latest)

leaden vector
#

after installing the single instance plugin it seems like my tauri updated itself from about 2.2.5 to 2.9.3 and now when i compile i get this error:

error[E0308]: mismatched types
   --> C:\Users\cyan\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\tauri-plugin-2.0.4\src\build\mod.rs:140:58
    |
140 |       tauri_utils::plugin::define_global_api_script_path(path);
    |       -------------------------------------------------- ^^^^ expected `&Path`, found `PathBuf`
    |       |
    |       arguments to this function are incorrect
    |
note: function defined here
   --> C:\Users\cyan\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\tauri-utils-2.8.0\src\plugin.rs:22:10
    |
22  |   pub fn define_global_api_script_path(path: &Path) {
    |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
help: consider borrowing here
    |
140 |       tauri_utils::plugin::define_global_api_script_path(&path);
    |                                                          +

since i don't think i should be modifying this file, how would i fix this?

#

before the update, my tauri utils was 2.1.1

ruby crypt
#

if you must keep using old versions you'll have downgrade the plugin. If you're fine with updating running cargo update tauri tauri-utils tauri-plugin (or just cargo update) should do the trick.
this is something i really really want to improve in v3 but in v2 we kinda have to keep breaking shit there :/

leaden vector
#

ohh yeah that fixed it

#

i didn't mean to use old versions i just assumed everything got updated at once

#

but it seems like it was just an issue where some crates got updated and some didn't

ruby crypt
#

yeah it's supposed to update the inner dependencies as well, at least i think the versions are all declared correctly but very often that just doesn't happen for some reason