Repository: tauri
Issue: [bug] failed overriding protocol method -[WKUIDelegate webView:requestMediaCapturePermissionForOrigin:initiatedByFrame:type:decisionHandler:]: method not found
Labels: type: bug,status: upstream,status: needs triage

### Describe the bug

npm run tauri dev

> tauri-app@0.1.0 tauri
> tauri dev

    Running BeforeDevCommand (`npm run dev`)

> tauri-app@0.1.0 dev
> vite

    Warn Waiting for your frontend dev server to start on http://localhost:1420/...
Re-optimizing dependencies because lockfile has changed

  VITE v5.4.10  ready in 3410 ms

  ➜  Local:   http://localhost:1420/
    Info Watching /Users/peipeng.yuan.o/workspace/tauri-app/src-tauri for changes...
   Compiling objc-sys v0.3.5
   Compiling objc2 v0.5.2
   Compiling block2 v0.5.1
   Compiling objc2-foundation v0.2.2
   Compiling objc2-app-kit v0.2.2
   Compiling objc2-web-kit v0.2.2
   Compiling window-vibrancy v0.5.2
   Compiling muda v0.15.1
   Compiling wry v0.46.3
   Compiling tauri-runtime-wry v2.1.2
   Compiling tauri v2.0.6
   Compiling tauri-plugin-shell v2.0.2
   Compiling tauri-app v0.1.0 (/Users/peipeng.yuan.o/workspace/tauri-app/src-tauri)
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 54.44s
thread 'main' panicked at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/objc2-0.5.2/src/__macro_helpers/declare_class.rs:339:21:
failed overriding protocol method -[WKUIDelegate webView:requestMediaCapturePermissionForOrigin:initiatedByFrame:type:decisionHandler:]: method not found
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread 'main' panicked at core/src/panicking.rs:221:5:
panic in a function that cannot unwind
stack backtrace:
   0:        0x1029e90b6 - std::backtrace_rs::backtrace::libunwind::trace::hae28e9d8ee6f0f1b
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/../../backtrace/src/backtrace/libunwind.rs:116:5
   1:        0x1029e90b6 - std::backtrace_rs::backtrace::trace_unsynchronized::h97ac52ce5b001ab9
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:        0x1029e90b6 - std::sys::backtrace::_print_fmt::h121f81f3e644bc1c
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/sys/backtrace.rs:66:9
   3:        0x1029e90b6 - <std::sys::backtrace::BacktraceLock::print::DisplayBacktrace as core::fmt::Display>::fmt::hcaf66bc4c0c453df
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/sys/backtrace.rs:39:26
   4:        0x102a0aedb - core::fmt::rt::Argument::fmt::hfeba5accca924a15
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/fmt/rt.rs:177:76
   5:        0x102a0aedb - core::fmt::write::hc9c5f1836b413410
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/fmt/mod.rs:1178:21
   6:        0x1029e5b92 - std::io::Write::write_fmt::h49df280499063c09
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/io/mod.rs:1823:15
   7:        0x1029ea3c8 - std::sys::backtrace::BacktraceLock::print::he68bab4b1e212a89
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/sys/backtrace.rs:42:9
   8:        0x1029ea3c8 - std::panicking::default_hook::{{closure}}::h52c0b2f44f6107c5
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:266:22
   9:        0x1029ea00e - std::panicking::default_hook::h5a6cf31501c161b2
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:293:9
  10:        0x1029eb0e3 - std::panicking::rust_panic_with_hook::hda4640ee332466e9
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:797:13
  11:        0x1029ea982 - std::panicking::begin_panic_handler::{{closure}}::haa3060694b34ea3d
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:664:13
  12:        0x1029e9599 - std::sys::backtrace::__rust_end_short_backtrace::h8eb44913cfe71457
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/sys/backtrace.rs:170:18
  13:        0x1029ea5fc - rust_begin_unwind
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:662:5
  14:        0x102a3d25c - core::panicking::panic_nounwind_fmt::runtime::h192b7a91100d1ba6
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/panicking.rs:112:18
  15:        0x102a3d25c - core::panicking::panic_nounwind_fmt::hfed0a2f12e4318b1
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/panicking.rs:122:5
  16:        0x102a3d30a - core::panicking::panic_nounwind::h659854746b9fc37d
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/panicking.rs:221:5
  17:        0x102a3d525 - core::panicking::panic_cannot_unwind::hd982c2e1ccbf0ef4
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/panicking.rs:310:5
  18:        0x10242e9ca - tao::platform_impl::platform::app_delegate::did_finish_launching::h1e4a275343ef8f00
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tao-0.30.3/src/platform_impl/macos/app_delegate.rs:103:1
  19:     0x7fff20495463 - <unknown>
  20:     0x7fff20530ed9 - <unknown>
  21:     0x7fff20530e54 - <unknown>
  22:     0x7fff204666ce - <unknown>
  23:     0x7fff211d9c18 - <unknown>
  24:     0x7fff22cb0d80 - <unknown>
  25:     0x7fff22cb0ad2 - <unknown>
  26:     0x7fff22cadc71 - <unknown>
  27:     0x7fff22cad8c7 - <unknown>
  28:     0x7fff21205366 - <unknown>
  29:     0x7fff212051d6 - <unknown>
  30:     0x7fff26282853 - <unknown>
  31:     0x7fff26281f6e - <unknown>
  32:     0x7fff2627acd3 - <unknown>
  33:     0x7fff286fa012 - <unknown>
  34:     0x7fff22ca7f70 - <unknown>
  35:     0x7fff22ca62a5 - <unknown>
  36:     0x7fff22c985c9 - <unknown>
  37:        0x10246aff1 - <() as objc::message::MessageArguments>::invoke::h99676cb39a047150
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/objc-0.2.7/src/message/mod.rs:128:17
  38:        0x102469bbd - objc::message::platform::send_unverified::h00753cbb8fff113e
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/objc-0.2.7/src/message/apple/mod.rs:27:9
  39:        0x1020f0295 - objc::message::send_message::h699c43327ef8383e
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/objc-0.2.7/src/message/mod.rs:178:5
  40:        0x1020f0295 - tao::platform_impl::platform::event_loop::EventLoop<T>::run_return::h9fc62e1d792f5527
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tao-0.30.3/src/platform_impl/macos/event_loop.rs:225:16
  41:        0x1020f1161 - tao::platform_impl::platform::event_loop::EventLoop<T>::run::hd25c501f4a144ef6
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tao-0.30.3/src/platform_impl/macos/event_loop.rs:192:21
  42:        0x102161a88 - tao::event_loop::EventLoop<T>::run::hb2375ddcff1fbe5c
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tao-0.30.3/src/event_loop.rs:215:5
  43:        0x101bb2c1b - <tauri_runtime_wry::Wry<T> as tauri_runtime::Runtime<T>>::run::hc6d4738815a0d29e
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-runtime-wry-2.1.2/src/lib.rs:2726:5
  44:        0x101bb931a - tauri::app::App<R>::run::h7d298a0e7089e2ef
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-2.0.6/src/app.rs:1129:5
  45:        0x101bb9df5 - tauri::app::Builder<R>::run::h3f745a7e6b0402fa
                               at /Users/peipeng.yuan.o/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tauri-2.0.6/src/app.rs:2052:5
  46:        0x10218d3f9 - tauri_app_lib::run::h53568fe4fe82bff6
                               at /Users/peipeng.yuan.o/workspace/tauri-app/src-tauri/src/lib.rs:9:5
  47:        0x10192cc89 - tauri_app::main::hf333b231e8f5fa62
                               at /Users/peipeng.yuan.o/workspace/tauri-app/src-tauri/src/main.rs:5:5
  48:        0x10192cd6e - core::ops::function::FnOnce::call_once::h36fa293f72247906
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/ops/function.rs:250:5
  49:        0x10192cc71 - std::sys::backtrace::__rust_begin_short_backtrace::h7639879eaae778c1
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/sys/backtrace.rs:154:18
  50:        0x10192cd24 - std::rt::lang_start::{{closure}}::h4cda7cd945a37f68
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/rt.rs:164:18
  51:        0x1029e141f - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::h57d1f2389e2919e9
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/core/src/ops/function.rs:284:13
  52:        0x1029e141f - std::panicking::try::do_call::h47b836309ad2925a
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:554:40
  53:        0x1029e141f - std::panicking::try::hcc79b4069713f450
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:518:19
  54:        0x1029e141f - std::panic::catch_unwind::h34090fdb34bc5e00
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panic.rs:345:14
  55:        0x1029e141f - std::rt::lang_start_internal::{{closure}}::hb9c7217a630c43c9
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/rt.rs:143:48
  56:        0x1029e141f - std::panicking::try::do_call::h43e7c27d402b50a4
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:554:40
  57:        0x1029e141f - std::panicking::try::h4d79f623873fbc60
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panicking.rs:518:19
  58:        0x1029e141f - std::panic::catch_unwind::hb32f8cfbf49d3dee
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/panic.rs:345:14
  59:        0x1029e141f - std::rt::lang_start_internal::hb1473645dbe40065
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/rt.rs:143:20
  60:        0x10192ccf7 - std::rt::lang_start::h74b59529f543ed2f
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14/library/std/src/rt.rs:163:17
  61:        0x10192cca8 - _main
thread caused non-unwinding panic. aborting.

### Reproduction

_No response_

### Expected behavior

_No response_

### Full `tauri info` output

```text
tauri info


[✔] Environment
    - OS: Mac OS 11.7.10 x86_64 (X64)
    ✔ Xcode Command Line Tools: installed
    ✔ rustc: 1.82.0 (f6e511eec 2024-10-15)
    ✔ cargo: 1.82.0 (8f40fc59f 2024-08-21)
    ✔ rustup: 1.27.1 (54dd3d00f 2024-04-24)
    ✔ Rust toolchain: stable-x86_64-apple-darwin (default)
    - node: 20.16.0
    - pnpm: 9.10.0
    - yarn: 1.22.19
    - npm: 10.8.1

[-] Packages
    - tauri 🦀: 2.0.6
    - tauri-build 🦀: 2.0.2
    - wry 🦀: 0.46.3
    - tao 🦀: 0.30.3
    - @tauri-apps/api : 2.0.3
    - @tauri-apps/cli : 2.0.5

[-] Plugins
    - tauri-plugin-shell 🦀: 2.0.2
    - @tauri-apps/plugin-shell : 2.0.1

[-] App
    - build-type: bundle
    - CSP: unset
    - frontendDist: ../dist
    - devUrl: http://localhost:1420/
    - framework: Vue.js
    - bundler: Vite
```


### Stack trace

_No response_

### Additional context

_No response_