You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when I create a blank new flutter app through Android Studio (version 4.1.3) on my MAC and only add "camera: ^0.9.4+5" to "dependencies" in the pubspec.yaml-file I cannot get the app to build in XCode anymore. It fails with the message in the title "Module 'camera' not found".
This is what I do:
Open Android Studio and select "Create new Flutter Project".
Choose "Flutter Application" and set a name for the app
Open pubspec.yaml an add "camera: ^0.9.4+5":
Run "flutter pub get"
Edit Podfile in ios folder and set "platform :ios, '11.0'"
Open Terminal in Android Studio, navigate to ios folder and run "pod install"
Right click Runner.xcodeproj and open in XCode
Set deployment target to 11.0 in XCode project
Run the app from XCode project
Observe this error:
The weird thing is that sometimes, after a reboot it suddenly works one time. Then I open another project, go back to this one and it doesn't work anymore.
This is my flutter doctor:
[✓] Flutter (Channel stable, 2.8.1, on macOS 11.5 20G71 darwin-arm, locale de-CH)
• Flutter version 2.8.1 at /Users/andi/Development/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 77d935a (5 days ago), 2021-12-16 08:37:33 -0800
• Engine revision 890a5fca2e
• Dart version 2.15.1
[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at /Users/andi/Library/Android/sdk
✗ cmdline-tools component is missing
Run path/to/sdkmanager --install "cmdline-tools;latest"
See https://developer.android.com/studio/command-line for more details.
✗ Android license status unknown.
Run flutter doctor --android-licenses to accept the SDK licenses.
See https://flutter.dev/docs/get-started/install/macos#android-setup for more details.
[✓] Xcode - develop for iOS and macOS (Xcode 13.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• CocoaPods version 1.10.2
[✗] Chrome - develop for the web (Cannot find Chrome executable at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[✓] Connected device (1 available)
• iPhone von Andreas (mobile) • 2013ab25cd849c7cccfd61a0582aa6219ac9c93e • ios • iOS 14.7.1 18G82
! Doctor found issues in 2 categories.
When I run the ios build from Android Studio it works perfectly fine!
Does anyone have an idea why I get this error in XCode? How can I find the "real" issue or underlying cause?
Best regards and thanks in advance,
Andi
The text was updated successfully, but these errors were encountered:
Hi @Bongokarl, this is a fairly common issue and may have been caused because you opened Runner.xcodeproj instead of Runner.xcworkspace, and is not an issue with the camera plugin.
Please see the following links for more information
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.
Hi there,
when I create a blank new flutter app through Android Studio (version 4.1.3) on my MAC and only add "camera: ^0.9.4+5" to "dependencies" in the pubspec.yaml-file I cannot get the app to build in XCode anymore. It fails with the message in the title "Module 'camera' not found".
This is what I do:
The weird thing is that sometimes, after a reboot it suddenly works one time. Then I open another project, go back to this one and it doesn't work anymore.
This is my flutter doctor:
[✓] Flutter (Channel stable, 2.8.1, on macOS 11.5 20G71 darwin-arm, locale de-CH)
• Flutter version 2.8.1 at /Users/andi/Development/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 77d935a (5 days ago), 2021-12-16 08:37:33 -0800
• Engine revision 890a5fca2e
• Dart version 2.15.1
[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at /Users/andi/Library/Android/sdk
✗ cmdline-tools component is missing
Run
path/to/sdkmanager --install "cmdline-tools;latest"
See https://developer.android.com/studio/command-line for more details.
✗ Android license status unknown.
Run
flutter doctor --android-licenses
to accept the SDK licenses.See https://flutter.dev/docs/get-started/install/macos#android-setup for more details.
[✓] Xcode - develop for iOS and macOS (Xcode 13.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• CocoaPods version 1.10.2
[✗] Chrome - develop for the web (Cannot find Chrome executable at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[✓] Android Studio (version 4.1)
• 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 1.8.0_242-release-1644-b3-6915495)
[✓] Connected device (1 available)
• iPhone von Andreas (mobile) • 2013ab25cd849c7cccfd61a0582aa6219ac9c93e • ios • iOS 14.7.1 18G82
! Doctor found issues in 2 categories.
When I run the ios build from Android Studio it works perfectly fine!
Does anyone have an idea why I get this error in XCode? How can I find the "real" issue or underlying cause?
Best regards and thanks in advance,
Andi
The text was updated successfully, but these errors were encountered: