keyviz icon indicating copy to clipboard operation
keyviz copied to clipboard

Cannot run with macOS

Open htsuruo opened this issue 2 years ago • 13 comments

Describe the bug

Run this command for running with macos

flutter run -d macos

And then, output is here.

flutter: couldn't register mouse listener
flutter: cannot register keyboard listener!

Version: v2.0.0a

To Reproduce Steps to reproduce the behavior:

  1. Changed minimun target version 10.14 to 10.15 because following error occurs.
/keyviz/macos/Flutter/GeneratedPluginRegistrant.swift:9:8: error: compiling for macOS 10.14, but module 'macos_window_utils' has a minimum deployment target of macOS 10.14.6: /keyviz/build/macos/Build/Products/Debug/macos_window_utils/macos_window_utils.framework/Modules/macos_window_utils.swiftmodule/arm64-apple-macos.swiftmodule
import macos_window_utils
  1. flutter run -d macos

Expected behavior Works fine this application with macOS.

Screenshots image

Desktop (please complete the following information):

  • MacBook Pro M1(Apple Silicon)
  • macOS: Ventura 13.4.1

htsuruo avatar Jul 22 '23 07:07 htsuruo

Have you given permissions for input monitoring and accessibility Settings > Privacy & Security > Input Monitoring/Accessibility to keyviz (debug) and the terminal/vs code (where running flutter run command)?

mulaRahul avatar Jul 22 '23 13:07 mulaRahul

@mulaRahul

Thanks for your reply.

Have you given permissions for input monitoring and accessibility Settings > Privacy & Security > Input Monitoring/Accessibility to keyviz (debug)

Yes. I added Input Monitoring/Accessibility permission to keyvz > build > macos > Build > Products > Debug > keyviz.app. But it does not work.

SCR-20230723-bcpg-2

I tried flutter run with VS Code.

htsuruo avatar Jul 22 '23 15:07 htsuruo

You need to provide the permissions to VS Code as well, because technically where the app is running.

mulaRahul avatar Sep 28 '23 09:09 mulaRahul

Can you see any changes with v2.0.0a2?

mulaRahul avatar Apr 21 '24 15:04 mulaRahul

@mulaRahul

Thank you for great work.

I just tried running with tag v2.0.0a2 as your comment. Unfortunately, the issue still occurred.

htsuruo avatar Apr 30 '24 14:04 htsuruo

Can you share logs/output like above?

mulaRahul avatar Apr 30 '24 14:04 mulaRahul

@mulaRahul

Apologize for late response. Here is all of logs.

Launching lib/main.dart on macOS in debug mode... --- xcodebuild: WARNING: Using the first of multiple matching destinations: { platform:macOS, arch:arm64, id:00006001-001271510A41801E } { platform:macOS, arch:x86_64, id:00006001-001271510A41801E } 2024-05-03 22:18:12.367 keyviz[29568:56797777] WARNING: Secure coding is automatically enabled for restorable state! However, not on all supported macOS versions of this application. Opt-in to secure coding explicitly by implementing NSApplicationDelegate.applicationSupportsSecureRestorableState:. Connecting to VM Service at ws://127.0.0.1:62701/2f-3bCO3MLA=/ws flutter: Failed to initialize listener backend flutter: couldn't register mouse listener flutter: cannot register keyboard listener!

htsuruo avatar May 03 '24 13:05 htsuruo

Have given the above permissions?

mulaRahul avatar May 03 '24 14:05 mulaRahul

Same stuff here. I was on a previous version (dunno which one, unfortunately) that was running just fine. But now, even giving the permissions on accessibility and input, the error keeps showing.

I don't have flutter installed, and never had. So, I don't know if that's the problem, once the old version was running just fine.

dnet5 avatar May 04 '24 15:05 dnet5

same issue with me Im on M3 Sonoma

foong avatar May 10 '24 13:05 foong