londonappbrewery / mi_card_flutter

Starter code for the Mi Card Project from the Complete Flutter Development Bootcamp
https://www.appbrewery.co
433 stars 1.13k forks source link

IPHONEOS_DEPLOYMENT_TARGET #32

Closed welfvh closed 2 years ago

welfvh commented 4 years ago

What you'd expect if these materials aren't updated in face of changes like iOS 14. IPHONEOS_DEPLOYMENT_TARGET is set to 8.0, which leads xcode to throw errors when trying to build.

welfvh commented 4 years ago

and even after updating:

Xcode's output: ↳ Invalid depfile: /Users/welf/dev/mi_card_flutter/.dart_tool/flutter_build/92ff8c4b43966ee98d4d943d2aaadb7b/kernel_snapshot.d Invalid depfile: /Users/welf/dev/mi_card_flutter/.dart_tool/flutter_build/92ff8c4b43966ee98d4d943d2aaadb7b/kernel_snapshot.d Invalid depfile: /Users/welf/dev/mi_card_flutter/.dart_tool/flutter_build/92ff8c4b43966ee98d4d943d2aaadb7b/kernel_snapshot.d Invalid depfile: /Users/welf/dev/mi_card_flutter/.dart_tool/flutter_build/92ff8c4b43966ee98d4d943d2aaadb7b/kernel_snapshot.d lib/main.dart:1:8: Error: Not found: 'dart:html' import 'dart:html'; ^ Unhandled exception: FileSystemException(uri=org-dartlang-untranslatable-uri:dart%3Ahtml; message=StandardFileSystem only supports file: and data: URIs)

0 StandardFileSystem.entityForUri (package:front_end/src/api_prototype/standard_file_system.dart:33:7)

#1      asFileUri (package:vm/kernel_front_end.dart:657:37)
#2      writeDepfile (package:vm/kernel_front_end.dart:825:21)
<asynchronous suspension>
#3      FrontendCompiler.compile (package:frontend_server/frontend_server.dart:572:15)
<asynchronous suspension>
#4      _FlutterFrontendCompiler.compile (package:flutter_frontend_server/server.dart:43:22)
#5      starter (package:flutter_frontend_server/server.dart:182:27)
#6      main (file:///opt/s/w/ir/cache/builder/src/flutter/flutter_frontend_server/bin/starter.dart:13:30)
#7      _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:299:32)
#8      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)

Command PhaseScriptExecution failed with a nonzero exit code
note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description

Could not build the application for the simulator. Error launching application on iPhone 11 Pro.

josiahtmorgan commented 2 years ago

Removing… const ({Key? key}) : super(key: key); from the StatelessWidget class allowed the app to build for me — macOS Monterey.