Skip to content

MacOS Permission problem in VSCode  #114352

@berkobob

Description

@berkobob

I am writing a simple plugin to read, write, edit & delete Apple Reminders. The first thing I do is request access to reminders:

eventStore.requestAccess(to: EKEntityType.reminder, completion: {(granted, error) in 
            if let error = error { print(error) }
            self.hasAccess = granted ? true : false
            })

When I run my app from the terminal (iTerm) using flutter run -d macOS a window popped up to allow me to grant access to my Reminders. If I build the app and run the executable it also works. When I run my app from within VSCode, either using Debug or the VSCode terminal, the permission window does not appear and my app fails to get permission. I'm thinking this is a VSCode issue as it works everywhere else.

I have the same problem on my M1 MacStudio and my Intel MacBook Pro.

How do I grant access to my Reminders to VSCode?

flutter doctor -v [✓] Flutter (Channel stable, 3.3.6, on macOS 13.0 22A380 darwin-arm, locale en-GB) • Flutter version 3.3.6 on channel stable at /Users/antoine/library/flutter • Upstream repository https://github.com/flutter/flutter.git • Framework revision 6928314 (6 days ago), 2022-10-25 16:34:41 -0400 • Engine revision 3ad69d7be3 • Dart version 2.18.2 • DevTools version 2.15.0

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
• Android SDK at /Users/antoine/Library/Android/sdk
• Platform android-33, build-tools 33.0.0
• Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.12+0-b1504.28-7817840)
• All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.0.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 14A400
• CocoaPods version 1.11.3

[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2021.2)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 11.0.12+0-b1504.28-7817840)

[✓] VS Code (version 1.72.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.50.0

[✓] Connected device (2 available)
• macOS (desktop) • macos • darwin-arm64 • macOS 13.0 22A380 darwin-arm
• Chrome (web) • chrome • web-javascript • Google Chrome 107.0.5304.87

[✓] HTTP Host Availability
• All required HTTP hosts are available

• No issues found!

VSCode Version

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work liste: device-specificOnly manifests on certain devicesengineflutter/engine related. See also e: labels.found in release: 3.3Found to occur in 3.3found in release: 3.4Found to occur in 3.4platform-macBuilding on or for macOS specificallyteam-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions