mattermoran / map_launcher

Flutter plugin for launching maps
MIT License
265 stars 125 forks source link

IOS installed maps crash #127

Closed av131996 closed 1 year ago

av131996 commented 2 years ago

Short description

Trying to list installed maps on ios gives me those errors

Code sample:

Future<List<AvailableMap>> showInstalledMapss() async { return await MapLauncher.installedMaps; }

IOS version: 15.6.1 Flutter version: 3.3.0

Stack trace

-canOpenURL: failed for URL: "iosamap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "baidumap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "yandexnavi://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "yandexmaps://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "citymapper://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "mapswithme://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "osmandmaps://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "dgis://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "qqmap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "here-location://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" canOpenURL: failed for URL: "here-location://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "tomtomgo://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "iosamap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "baidumap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "yandexnavi://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "yandexmaps://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "citymapper://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "mapswithme://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "osmandmaps://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "dgis://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "qqmap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "here-location://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" canOpenURL: failed for URL: "dgis://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "qqmap://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "here-location://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" -canOpenURL: failed for URL: "tomtomgo://" - error: "The operation couldn’t be completed. (OSStatus error -10814.)" 2 [quic] quic_crypto_session_state_serialize [C12.2.1:2] [-6ab732817ee11b71] TLS ticket does not fit (6839 > 6144)

pubspec.yaml

description: A new Flutter project.

# The following line prevents the package from being accidentally published to
# pub.dev using `flutter pub publish`. This is preferred for private packages.
publish_to: "none" # Remove this line if you wish to publish to pub.dev

# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
# followed by an optional build number separated by a +.
# Both the version and the builder number may be overridden in flutter
# build by specifying --build-name and --build-number, respectively.
# In Android, build-name is used as versionName while build-number used as versionCode.
# Read more about Android versioning at https://developer.android.com/studio/publish/versioning
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 1.0.2+1

environment:
  sdk: ">=2.11.1 <3.0.0"

# Dependencies specify other packages that your package needs in order to work.
# To automatically upgrade your package dependencies to the latest versions
# consider running `flutter pub upgrade --major-versions`. Alternatively,
# dependencies can be manually updated by changing the version numbers below to
# the latest version available on pub.dev. To see which dependencies have newer
# versions available, run `flutter pub outdated`.
dependencies:
  flutter:
    sdk: flutter
  flutter_polyline_points: ^1.0.0
  duration: ^3.0.11
  map_launcher: ^2.3.0
  google_maps_flutter: ^2.1.1
  firebase_storage: ^10.3.1
  location: ^4.4.0
  latlong2: ^0.8.1
  url_launcher: ^6.0.17
  firebase_image: ^1.1.1
  state_notifier: ^0.7.2+1
  firebase_core: ^1.20.1
  firebase_auth: ^3.6.3
  firebase_analytics: ^9.3.1
  cloud_firestore: ^3.4.4
  google_sign_in: ^5.4.1
  provider: ^6.0.2
  flutter_riverpod: ^1.0.3
  material_floating_search_bar: ^0.3.6
  flutter_svg: ^1.0.3
  # The following adds the Cupertino Icons font to your application.
  # Use with the CupertinoIcons class for iOS style icons.
  cupertino_icons: ^1.0.2
  package_info_plus: ^1.4.3
  get_it: ^7.2.0

dev_dependencies:
  flutter_test:
    sdk: flutter
  scrollable_positioned_list: ^0.1.7
  carousel_slider: ^2.2.1
  font_awesome_flutter: ^8.8.1
  flutter_launcher_icons: ^0.9.2

  # The "flutter_lints" package below contains a set of recommended lints to
  # encourage good coding practices. The lint set provided by the package is
  # activated in the `analysis_options.yaml` file located at the root of your
  # package. See that file for information about deactivating specific lint
  # rules and activating additional ones.
  flutter_lints: ^1.0.0

# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec

# The following section is specific to Flutter.
flutter_icons:
  android: true
  ios: true
  image_path: "assets/icon/play_store_512.png"
  image_path_android: "assets/icon/play_store_512.png"
  adaptive_icon_background: "assets/icon/ic_launcher_background.png"
  adaptive_icon_foreground: "assets/icon/ic_launcher_foreground.png"

flutter:
  # The following line ensures that the Material Icons font is
  # included with your application, so that you can use the icons in
  # the material Icons class.
  uses-material-design: true

  # To add assets to your application, add an assets section, like this:
  assets:
    - assets/img/chat-avatar.jpeg
    - assets/img/onboard-background.jpg
    - assets/img/logo-android.png
    - assets/img/logo-ios.png
    - assets/img/logo-white.png
    - assets/img/logo-black.png
    - assets/img/dummy-map.png
    - assets/img/default_voucher.png
    - assets/icon/ic_launcher.png

  # An image asset can refer to one or more resolution-specific "variants", see
  # https://flutter.dev/assets-and-images/#resolution-aware.

  # For details regarding adding assets from package dependencies, see
  # https://flutter.dev/assets-and-images/#from-packages

  # To add custom fonts to your application, add a fonts section here,
  # in this "flutter" section. Each entry in this list should have a
  # "family" key with the font family name, and a "fonts" key with a
  # list giving the asset and other descriptors for the font. For
  # example:
  fonts:
    - family: Comfortaa
      fonts:
        - asset: assets/fonts/Comfortaa-Bold.ttf
          weight: 600
        - asset: assets/fonts/Comfortaa-Light.ttf
          weight: 100
        - asset: assets/fonts/Comfortaa-Medium.ttf
          weight: 400
        - asset: assets/fonts/Comfortaa-Regular.ttf
          weight: 300
  #   - family: Trajan Pro
  #     fonts:
  #       - asset: fonts/TrajanPro.ttf
  #       - asset: fonts/TrajanPro_Bold.ttf
  #         weight: 700
  #
  # For details regarding fonts from package dependencies,
  # see https://flutter.dev/custom-fonts/#from-packages
mattermoran commented 2 years ago

Did you add url schemes to info.plist? image

adrianAzoitei commented 2 years ago

Hi, second collaborator here. Yes, we did.

mattermoran commented 2 years ago

Do you get the same error when trying to run the example app? I will also check if there's something changed with flutter 3.3 or iOS 16

mattermoran commented 1 year ago

Did you try to run the example app from this project? Btw the error you posted are not fatal and should not crash the app. It's just saying that those maps are not found on the device. There must be something else

mattermoran commented 1 year ago

Closing as there's no reply