Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] When migrating using the migration tool, an error occurs when installing @tauri-apps/[email protected] on Windows. #10873

Closed
mikoto2000 opened this issue Sep 3, 2024 · 1 comment
Labels
status: needs triage This issue needs to triage, applied to new issues type: bug

Comments

@mikoto2000
Copy link

Describe the bug

I create #10500, I retry migration use newest version.

Error during installation of @tauri-apps/[email protected].

PS F:\project\scab-player> npm install @tauri-apps/cli@next @tauri-apps/api@next

removed 1 package, changed 3 packages, and audited 1396 packages in 6s

271 packages are looking for funding
  run `npm fund` for details

10 vulnerabilities (4 moderate, 6 high)

To address issues that do not require attention, run:
  npm audit fix

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.
PS F:\project\scab-player> npm run tauri migrate

> [email protected] tauri
> tauri migrate

    Info Installing Cargo dependency "tauri-plugin-shell"...
    Updating crates.io index
      Adding tauri-plugin-shell v2.0.0-rc to dependencies
    Updating crates.io index
     Locking 118 packages to latest compatible versions
    Updating atk v0.15.1 -> v0.18.0
    Updating atk-sys v0.15.1 -> v0.18.0
    Updating brotli v3.5.0 -> v6.0.0
    Updating brotli-decompressor v2.5.1 -> v4.0.1
    Updating cairo-rs v0.15.12 -> v0.18.5 (latest: v0.20.1)
    Updating cairo-sys-rs v0.15.1 -> v0.18.2 (latest: v0.20.0)
      Adding camino v1.1.9
      Adding cargo-platform v0.1.8
      Adding cargo_metadata v0.18.1
    Updating cargo_toml v0.15.3 -> v0.17.2 (latest: v0.20.4)
    Updating cfg_aliases v0.1.1 -> v0.2.1
    Updating cocoa v0.24.1 -> v0.26.0
    Updating cocoa-foundation v0.1.2 -> v0.2.0
      Adding core-foundation v0.10.0
    Updating core-foundation-sys v0.8.6 -> v0.8.7
    Updating core-graphics v0.22.3 -> v0.24.0
      Adding core-graphics-types v0.2.0
      Adding dirs v5.0.1
      Adding dirs-sys v0.4.1
      Adding dlopen2 v0.7.0
      Adding dlopen2_derive v0.4.0
      Adding dpi v0.1.1
      Adding dyn-clone v1.0.17
      Adding erased-serde v0.4.5
      Adding fluent-uri v0.1.4 (latest: v0.2.0)
    Updating gdk v0.15.4 -> v0.18.0
    Updating gdk-pixbuf v0.15.11 -> v0.18.5 (latest: v0.20.1)
    Updating gdk-pixbuf-sys v0.15.10 -> v0.18.0 (latest: v0.20.1)
    Updating gdk-sys v0.15.1 -> v0.18.0
    Updating gdkwayland-sys v0.15.3 -> v0.18.0
      Adding gdkx11 v0.18.0
    Updating gdkx11-sys v0.15.1 -> v0.18.0
    Updating gio v0.15.12 -> v0.18.4 (latest: v0.20.1)
    Updating gio-sys v0.15.10 -> v0.18.1 (latest: v0.20.1)
    Updating glib v0.15.12 -> v0.18.5 (latest: v0.20.2)
    Updating glib-macros v0.15.13 -> v0.18.5 (latest: v0.20.2)
    Updating glib-sys v0.15.10 -> v0.18.1 (latest: v0.20.2)
    Updating gobject-sys v0.15.10 -> v0.18.0 (latest: v0.20.1)
    Updating gtk v0.15.5 -> v0.18.1
    Updating gtk-sys v0.15.3 -> v0.18.0
    Updating gtk3-macros v0.15.6 -> v0.18.0
    Updating infer v0.13.0 -> v0.15.0 (latest: v0.16.0)
      Adding is-docker v0.2.0
      Adding is-wsl v0.4.0
    Updating javascriptcore-rs v0.16.0 -> v1.1.2
    Updating javascriptcore-rs-sys v0.4.0 -> v1.1.1
    Updating jni v0.20.0 -> v0.21.1
    Updating json-patch v1.4.0 -> v2.0.0
      Adding jsonptr v0.4.7 (latest: v0.6.0)
      Adding keyboard-types v0.7.0
      Adding libappindicator v0.9.0
      Adding libappindicator-sys v0.9.0
 Downgrading libloading v0.8.4 -> v0.7.4 (latest: v0.8.5)
      Adding muda v0.14.1
    Updating ndk v0.6.0 -> v0.9.0
    Updating ndk-sys v0.3.0 -> v0.6.0+11769913
    Updating num_enum v0.5.11 -> v0.7.3
    Updating num_enum_derive v0.5.11 -> v0.7.3
    Updating open v3.2.0 -> v5.3.0
      Adding option-ext v0.2.0
    Updating pango v0.15.10 -> v0.18.3 (latest: v0.20.1)
    Updating pango-sys v0.15.10 -> v0.18.0 (latest: v0.20.1)
 Downgrading proc-macro-crate v3.1.0 -> v2.0.2 (latest: v3.2.0)
    Updating raw-window-handle v0.5.2 -> v0.6.2
      Adding schemars v0.8.21
      Adding schemars_derive v0.8.21
      Adding serde-untagged v0.1.6
      Adding serde_derive_internals v0.29.1
      Adding softbuffer v0.4.5
      Adding soup3 v0.5.0 (latest: v0.7.0)
      Adding soup3-sys v0.5.0 (latest: v0.7.0)
    Updating state v0.5.3 -> v0.6.0
      Adding swift-rs v1.0.7
    Updating tao v0.16.9 -> v0.29.1 (latest: v0.30.0)
    Updating tauri v1.6.8 -> v2.0.0-rc.8
    Updating tauri-build v1.5.2 -> v2.0.0-rc.7
    Updating tauri-codegen v1.4.3 -> v2.0.0-rc.7
    Updating tauri-macros v1.4.4 -> v2.0.0-rc.6
      Adding tauri-plugin v2.0.0-rc.7
      Adding tauri-plugin-shell v2.0.0-rc.3
    Updating tauri-plugin-window-state v0.1.1 -> v2.0.0-rc.2
    Updating tauri-runtime v0.14.3 -> v2.0.0-rc.7
    Updating tauri-runtime-wry v0.14.8 -> v2.0.0-rc.7
    Updating tauri-utils v1.5.4 -> v2.0.0-rc.7
      Adding toml v0.8.2 (latest: v0.8.19)
 Downgrading toml_datetime v0.6.6 -> v0.6.3 (latest: v0.6.8)
      Adding toml_edit v0.20.2 (latest: v0.22.20)
      Adding tray-icon v0.16.0 (latest: v0.17.0)
      Adding typeid v1.0.2
      Adding unic-char-property v0.9.0
      Adding unic-char-range v0.9.0
      Adding unic-common v0.9.0
      Adding unic-ucd-ident v0.9.0
      Adding unic-ucd-version v0.9.0
      Adding urlpattern v0.2.0 (latest: v0.3.0)
    Updating webkit2gtk v0.18.2 -> v2.0.1
    Updating webkit2gtk-sys v0.18.0 -> v2.0.1
    Updating webview2-com v0.19.1 -> v0.33.0
    Updating webview2-com-macros v0.6.0 -> v0.8.0
    Updating webview2-com-sys v0.19.0 -> v0.33.0
      Adding window-vibrancy v0.5.1
      Adding windows v0.58.0
    Updating windows-core v0.56.0 -> v0.58.0
      Adding windows-implement v0.58.0
    Updating windows-interface v0.56.0 -> v0.58.0
    Updating windows-result v0.1.2 -> v0.2.0
      Adding windows-strings v0.1.0
    Updating windows-sys v0.42.0 -> v0.59.0
    Updating windows-targets v0.52.5 -> v0.52.6
    Updating windows_aarch64_gnullvm v0.52.5 -> v0.52.6
      Adding windows_aarch64_msvc v0.52.6
      Adding windows_i686_gnu v0.52.6
    Updating windows_i686_gnullvm v0.52.5 -> v0.52.6
      Adding windows_i686_msvc v0.52.6
      Adding windows_x86_64_gnu v0.52.6
    Updating windows_x86_64_gnullvm v0.52.5 -> v0.52.6
      Adding windows_x86_64_msvc v0.52.6
    Updating wry v0.24.10 -> v0.42.0 (latest: v0.43.0)
    Info Installing NPM dependency "@tauri-apps/plugin-shell@^2.0.0-rc"...
npm ERR! code ETARGET
npm ERR! notarget No matching version found for @tauri-apps/[email protected].
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in: C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_23_47_753Z-debug-0.log
    Error failed to migrate from v1: Could not migrate plugin 'shell': Failed to install NPM dependency

Reproduction

git clone -b tauri2.0-3 --depth 1 https://github.com/mikoto2000/scab-player
cd scab-player
npm install @tauri-apps/cli@next
npm run tauri migrate

Expected behavior

no error occurred.

Full tauri info output

PS F:\project\sp3> npm run tauri info

> [email protected] tauri
> tauri info


[✘] Environment
    - OS: Windows 10.0.22631 X64
    ✔ WebView2: 128.0.2739.54
    ✘ Couldn't detect any Visual Studio or VS Build Tools instance with MSVC and SDK components. Download from https://aka.ms/vs/17/release/vs_Build
o
ols.exe
    ✔ rustc: 1.79.0 (129f3b996 2024-06-10)
    ✔ cargo: 1.79.0 (ffa9cf99a 2024-06-03)
    ✔ rustup: 1.27.1 (54dd3d00f 2024-04-24)
    ✔ Rust toolchain: stable-x86_64-pc-windows-msvc (default)
    - node: 20.11.1
    - npm: 10.2.4

[-] Packages
    - tauri [RUST]: 1.6.8
    - tauri-build [RUST]: 1.5.2
    - wry [RUST]: 0.24.10
    - tao [RUST]: 0.16.9
    - @tauri-apps/api [NPM]: 1.5.6 (outdated, latest: 1.6.0)
    - @tauri-apps/cli [NPM]: 1.5.14 (outdated, latest: 1.6.1)

[-] App
    - build-type: bundle
    - CSP: unset
    - distDir: ../build
    - devPath: http://localhost:3000/
    - framework: React

Stack trace

0 verbose cli C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js
1 info using [email protected]
2 info using [email protected]
3 timing npm:load:whichnode Completed in 1ms
4 timing config:load:defaults Completed in 1ms
5 timing config:load:file:C:\Program Files\nodejs\node_modules\npm\npmrc Completed in 2ms
6 timing config:load:builtin Completed in 2ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 1ms
9 timing config:load:file:F:\project\sp3\.npmrc Completed in 0ms
10 timing config:load:project Completed in 0ms
11 timing config:load:file:C:\Users\mikoto\.npmrc Completed in 1ms
12 timing config:load:user Completed in 1ms
13 timing config:load:file:C:\Users\mikoto\AppData\Roaming\npm\etc\npmrc Completed in 0ms
14 timing config:load:global Completed in 0ms
15 timing config:load:setEnvs Completed in 1ms
16 timing config:load Completed in 7ms
17 timing npm:load:configload Completed in 7ms
18 timing config:load:flatten Completed in 1ms
19 timing npm:load:mkdirpcache Completed in 0ms
20 timing npm:load:mkdirplogs Completed in 1ms
21 verbose title npm add @tauri-apps/[email protected]
22 verbose argv "add" "@tauri-apps/[email protected]"
23 timing npm:load:setTitle Completed in 0ms
24 timing npm:load:display Completed in 0ms
25 verbose logfile logs-max:10 dir:C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_31_11_694Z-
26 verbose logfile C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_31_11_694Z-debug-0.log
27 timing npm:load:logFile Completed in 5ms
28 timing npm:load:timers Completed in 0ms
29 timing npm:load:configScope Completed in 0ms
30 timing npm:load Completed in 31ms
31 timing arborist:ctor Completed in 0ms
32 silly logfile start cleaning logs, removing 3 files
33 silly logfile error removing log file C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_30_51_609Z-debug-0.log [Error: EPERM: operation not permitted, lstat 'C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_30_51_609Z-debug-0.log'] {
33 silly logfile   errno: -4048,
33 silly logfile   code: 'EPERM',
33 silly logfile   syscall: 'lstat',
33 silly logfile   path: 'C:\\Users\\mikoto\\AppData\\Local\\npm-cache\\_logs\\2024-09-03T04_30_51_609Z-debug-0.log'
33 silly logfile }
34 silly logfile done cleaning log files
35 timing idealTree:init Completed in 340ms
36 timing idealTree:userRequests Completed in 0ms
37 silly idealTree buildDeps
38 silly fetch manifest @tauri-apps/[email protected]
39 timing arborist:ctor Completed in 0ms
40 http fetch GET 200 https://registry.npmjs.org/@tauri-apps%2fplugin-fs 1692ms (cache revalidated)
41 silly placeDep ROOT @tauri-apps/plugin-fs@ OK for: [email protected] want: 2.0.0-rc
42 timing idealTree:#root Completed in 1698ms
43 timing idealTree:node_modules/@tauri-apps/plugin-fs Completed in 0ms
44 timing idealTree:buildDeps Completed in 1699ms
45 timing idealTree:fixDepFlags Completed in 5ms
46 timing idealTree Completed in 2046ms
47 timing command:add Completed in 2052ms
48 verbose type version
49 verbose stack @tauri-apps/plugin-fs: No matching version found for @tauri-apps/[email protected].
49 verbose stack     at module.exports (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-pick-manifest\lib\index.js:209:23)
49 verbose stack     at RegistryFetcher.manifest (C:\Program Files\nodejs\node_modules\npm\node_modules\pacote\lib\registry.js:119:22)
49 verbose stack     at async #nodeFromEdge (C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\arborist\lib\arborist\build-ideal-tree.js:1049:19)
49 verbose stack     at async #buildDepStep (C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\arborist\lib\arborist\build-ideal-tree.js:917:11)
49 verbose stack     at async Arborist.buildIdealTree (C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\arborist\lib\arborist\build-ideal-tree.js:196:7)
49 verbose stack     at async Promise.all (index 1)
49 verbose stack     at async Arborist.reify (C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\arborist\lib\arborist\reify.js:159:5)
49 verbose stack     at async Install.exec (C:\Program Files\nodejs\node_modules\npm\lib\commands\install.js:152:5)
49 verbose stack     at async module.exports (C:\Program Files\nodejs\node_modules\npm\lib\cli-entry.js:61:5)
50 verbose cwd F:\project\sp3\src-tauri
51 verbose Windows_NT 10.0.22631
52 verbose node v20.11.1
53 verbose npm  v10.2.4
54 error code ETARGET
55 error notarget No matching version found for @tauri-apps/[email protected].
56 error notarget In most cases you or one of your dependencies are requesting
56 error notarget a package version that doesn't exist.
57 verbose exit 1
58 timing npm Completed in 2252ms
59 verbose unfinished npm timer reify 1725337871893
60 verbose unfinished npm timer reify:loadTrees 1725337871896
61 verbose code 1
62 error A complete log of this run can be found in: C:\Users\mikoto\AppData\Local\npm-cache\_logs\2024-09-03T04_31_11_694Z-debug-0.log

Additional context

On Linux, it succeeds after some choices are requested.

node@ff1322d8ca00:~/sp3$ npm install @tauri-apps/cli@next

added 1 package, removed 1 package, changed 1 package, and audited 1398 packages in 1s

272 packages are looking for funding
  run `npm fund` for details

10 vulnerabilities (4 moderate, 6 high)

To address issues that do not require attention, run:
  npm audit fix

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.
node@ff1322d8ca00:~/sp3$ npm run tauri migrate

> [email protected] tauri
> tauri migrate

    Info Installing NPM dependency "@tauri-apps/api@^2.0.0-rc.0"...
    Info Installing Cargo dependency "tauri-plugin-http"...
    Info Installing NPM dependency "@tauri-apps/plugin-http@^2.0.0-rc"...
    Added permission `http:default` to `migrated` at /home/node/sp3/src-tauri/capabilities/migrated.json
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-process"...
    Info Installing NPM dependency "@tauri-apps/plugin-process@^2.0.0-rc"...
    Added permission `process:default` to `migrated` at /home/node/sp3/src-tauri/capabilities/migrated.json
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-dialog"...
    Info Installing NPM dependency "@tauri-apps/plugin-dialog@^2.0.0-rc"...
    Added permission `dialog:default` to `migrated` at /home/node/sp3/src-tauri/capabilities/migrated.json
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-clipboard-manager"...
    Info Installing NPM dependency "@tauri-apps/plugin-clipboard-manager"...
    Added permission `clipboard-manager:default` to `migrated` at /home/node/sp3/src-tauri/capabilities/migrated.json
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-global-shortcut"...
    Info Installing NPM dependency "@tauri-apps/plugin-global-shortcut@^2.0.0-rc"...
    Info Capability matching platforms ["macOS", "windows", "linux"] not found, creating /home/node/sp3/src-tauri/capabilities/desktop.json
    Added permission `global-shortcut:default` to `desktop-capability` at /home/node/sp3/src-tauri/capabilities/desktop.json
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-os"...
    Info Installing NPM dependency "@tauri-apps/plugin-os@^2.0.0-rc"...
✔  Choose which capabilities to add the permission `os:default` to: ·-
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-fs"...
    Info Installing NPM dependency "@tauri-apps/plugin-fs@^2.0.0-rc"...
✔  Choose which capabilities to add the permission `fs:default` to: ·-
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-shell"...
    Info Installing NPM dependency "@tauri-apps/plugin-shell@^2.0.0-rc"...
✔  Choose which capabilities to add the permission `shell:default` to: ·-
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
    Info Installing Cargo dependency "tauri-plugin-notification"...
    Info Installing NPM dependency "@tauri-apps/plugin-notification@^2.0.0-rc"...
✔  Choose which capabilities to add the permission `notification:default` to: ·-
    Info Adding plugin to /home/node/sp3/src-tauri/src/lib.rs
    Info Running `cargo fmt`...
node@ff1322d8ca00:~/sp3$ echo $?
0
@mikoto2000 mikoto2000 added status: needs triage This issue needs to triage, applied to new issues type: bug labels Sep 3, 2024
@FabianLars FabianLars moved this to Backlog in 2.0 Stable Sep 3, 2024
@amrbashir
Copy link
Member

Fixed by #11064

@github-project-automation github-project-automation bot moved this from Backlog to Done in 2.0 Stable Sep 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: needs triage This issue needs to triage, applied to new issues type: bug
Projects
Status: Done
Development

No branches or pull requests

2 participants