AngeloAvv / flutter_flavorizr

A flutter utility to easily create flavors in your flutter application
https://pub.dev/packages/flutter_flavorizr
MIT License
469 stars 85 forks source link

iOS app getting crashed on specific Flavor #260

Closed vaibhavaroraneo closed 6 months ago

vaibhavaroraneo commented 6 months ago

I am facing a strange issue of app crashes on iOS for staging and preprod. Only prod is getting run for simulators and devices. the error received is

Terminating app due to uncaught exception 'com.firebase.core', reason: 'App name can only contain alphanumeric, hyphen (-), and underscore (_) characters'

The firebase files are updated with the names. but somehow its getting crashed stating the same error.

The flavor code

flavorizr:
  app:
    android:
      flavorDimensions: "app_flavor"

  flavors:
    staging:
      app:
        name: " Staging"
      android:
        applicationId: "com.app.staging"
        firebase:
          config: "android/app/src/staging/google-services.json"
      ios:
        bundleId: "com.app.staging"
        firebase:
          config: "ios/config/staging/GoogleService-Info.plist"

    preprod:
      app:
        name: "PreProd"
      android:
        applicationId: "com.app.preprod"
        firebase:
          config: "android/app/src/preprod/google-services.json"
      ios:
        bundleId: "com.app.preprod"
        firebase:
          config: "ios/config/preprod/GoogleService-Info.plist"

    prod:
      app:
        name: "Prod"
      android:
        applicationId: "com.app.live"
        firebase:
          config: "android/app/src/prod/google-services.json"
      ios:
        bundleId: "com.app.live"
        firebase:
          config: "ios/config/prod/GoogleService-Info.plist"

@AngeloAvv can you please help?

akbar607 commented 6 months ago

I have issue while run iOS, did you got any hint

AngeloAvv commented 6 months ago

Please take a look at https://github.com/flutter/flutter/issues/13518#issuecomment-351910058 This is not related with flutter_flavorizr, you put a an app name with a space in it. As mentioned in the error, spaces are not allowed