react-native icon indicating copy to clipboard operation
react-native copied to clipboard

App crashes on start on Android.

Open alexkrav opened this issue 2 years ago • 4 comments

Description

After migration to 0.71.3 (manual changes with Upgrade Helper from RN 0.70.5) I got the following screen for Debug build on Android:

image

React Native Version

0.71.3

Output of npx react-native info

System: OS: macOS 13.2.1 CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz Memory: 43.66 MB / 16.00 GB Shell: 5.8.1 - /bin/zsh Binaries: Node: 16.15.0 - ~/.nvm/versions/node/v16.15.0/bin/node Yarn: 1.22.19 - /usr/local/bin/yarn npm: 8.5.5 - ~/.nvm/versions/node/v16.15.0/bin/npm Watchman: 2022.05.30.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.3 - /Users/alexkrav/.rbenv/shims/pod SDKs: iOS SDK: Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1 Android SDK: API Levels: 23, 28, 29, 30, 31, 33 Build Tools: 27.0.3, 28.0.3, 29.0.2, 29.0.3, 30.0.2, 30.0.3, 31.0.0, 31.0.0, 33.0.0 System Images: android-27 | Google Play Intel x86 Atom, android-28 | Google APIs Intel x86 Atom, android-29 | Google APIs Intel x86 Atom, android-29 | Google Play Intel x86 Atom, android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom, android-31 | Google APIs Intel x86 Atom_64, android-33 | Google APIs Intel x86 Atom_64 Android NDK: 21.4.7075529 IDEs: Android Studio: 2021.3 AI-213.7172.25.2113.9123335 Xcode: 14.2/14C18 - /usr/bin/xcodebuild Languages: Java: 11.0.15 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 18.2.0 => 18.2.0 react-native: 0.71.3 => 0.71.3 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found

Steps to reproduce

yarn install yarn run android

Snack, code example, screenshot, or link to a repository

gradle.properties:

release.versionName=10.49
AsyncStorage_db_size_in_MB=100000000
android.useAndroidX=true
android.enableJetifier=true
org.gradle.jvmargs=-Xmx4096m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
FLIPPER_VERSION=0.125.0
reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64
newArchEnabled=false
hermesEnabled=true

android/build.gradle:

buildscript {
    ext.kotlinVersion = '1.6.20'
    ext.kotlin_version = '1.6.20'
    ext.kotlin_rx_version = '2.4.0'
    ext.internal_artifact_version = '1.6.5.2'
    ext.internal_artifact_version_legacy = '1.6.5.3'
    ext.androidKtxVersion = "1.6.0-beta01"
    // Note that this may need other checks as we add flavors.
    ext.hasReleaseKeyStore = project.hasProperty('release_key_store_password') && project.hasProperty('release_key_alias') && project.hasProperty('release_key_password')

    ext {

        minSdkVersionProd = 29
        minSdkVersionInternal = 24

        def Properties props = new Properties()
        def propFile = file('features.properties')
        if (propFile.canRead()){
            props.load(new FileInputStream(propFile))
            if (props!=null && props.containsKey('FEATURE_LOWER_BOUND_SDK') && props['FEATURE_LOWER_BOUND_SDK'] == 'true') {
                println('Lower bound sdk build. Bypassing production SDK')
                minSdkVersionProd = minSdkVersionInternal
            }
        }

        getTargetSDKVersion = {
            def variantName = getGradle().getStartParameter().getTaskRequests().toString().toLowerCase()
            if (variantName.contains("prerelease") ||
               variantName.contains("automation") ||
               variantName.contains("debug")){
                println("Development or internal build. using "+rootProject.ext.minSdkVersionInternal+" version")
                return ext.minSdkVersionInternal
            } else {
                println("Production build. using "+rootProject.ext.minSdkVersionProd+" version")
                return ext.minSdkVersionProd
            }
        }

        buildToolsVersion = "33.0.0"
        minSdkVersion = ext.getTargetSDKVersion()
        compileSdkVersion = 33
        targetSdkVersion = 33

        // We use NDK 23 which has both M1 support and is the side-by-side NDK version from AGP.
        ndkVersion = "23.1.7779620"

        androidXVersion = "1.0.0"
        googlePlayServicesAuthVersion = "16.0.1"
        supportLibVersion = "28.0.0"
        androidXAnnotation = "1.2.0"
        androidXBrowser = "1.3.0"
        playServicesLocationVersion = "17.0.0"
        androidMapsUtilsVersion = "0.5+"

        env = [
            hasReleaseKeyStore        : ext.hasReleaseKeyStore
        ]
    }

    repositories {
        mavenCentral()
        google()
        gradlePluginPortal()
        jcenter {
            content {
                includeModule("org.springframework", "spring-context")
            }
        }
    }
    dependencies {
        classpath("com.android.tools.build:gradle:7.3.1")
        classpath("com.facebook.react:react-native-gradle-plugin")
        classpath("de.undercouch:gradle-download-task:5.0.1")
        // classpath("com.android.tools.build:gradle:4.2.2")
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
        classpath 'com.google.gms:google-services:4.3.2'
        classpath 'digital.wup:android-maven-publish:3.6.2'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

file("features.properties").withReader {
   Properties props = new Properties()
   props.load(it)
   project.ext.features = props
}

allprojects {

    repositories {

        google()
        mavenCentral()
        // mavenLocal()

        maven {
            url "https://s3-us-west-2.amazonaws.com/si-mobile-sdks/android/"
        }
        maven {
            url "https://maven.vpn.etonreve.com/repo"
            metadataSources {
                mavenPom()
                artifact()
            }
        }
        maven{
            url 'https://maven.vpn.etonreve.com/evernote-artifacts'
        }
        jcenter {
            content {
                includeModule("org.springframework", "spring-context")
            }
        }
        maven {
            url "$rootDir/../src/base/3rd-party/react-native-background-fetch/android/libs"
        }

    }
    if (plugins.hasPlugin("java")) {
        task jvmSourcesJar(type: Jar) {
            archiveClassifier.set("sources")
            from sourceSets.main.allSource
        }
    }
    if (plugins.hasPlugin("android-library")) {
        task androidSourcesJar(type: Jar) {
            archiveClassifier.set("sources")
            from android.sourceSets.main.java.srcDirs
        }
    }
}

subprojects {
    afterEvaluate {project ->

        if(project.name == 'react-native-community_cookies' || 
           project.name == 'react-native-reanimated') {
            project.configurations { compile { } }
        }

        if (it.hasProperty('android')) {
            android {
                externalNativeBuild {
                    cmake {
                        version "3.18.1"
                    }
                }
            }
        }

        if (project.name.contains( 'react-native-blur')) {
            android {
                compileSdkVersion rootProject.ext.compileSdkVersion
                buildToolsVersion rootProject.ext.buildToolsVersion
            }
        }

        project.configurations.all {
            resolutionStrategy.eachDependency { DependencyResolveDetails details ->
                // if (details.requested.group == 'com.facebook.react' && details.requested.name.equals('react-native')){
                //     details.useVersion '0.70.5'
                // }
                if ((details.requested.group == 'com.evernote.native' ||
                        details.requested.group == 'com.evernote.conduit' ||
                        details.requested.group == 'com.evernote.neutron') && details.requested.name != 'legacy') {
                    details.useVersion rootProject.ext.internal_artifact_version
                }
                if (details.requested.group == 'com.evernote.conduit' && details.requested.name == 'legacy') {
                    details.useVersion rootProject.ext.internal_artifact_version_legacy
                }
                if (details.requested.group == 'org.jetbrains.kotlin' && details.requested.name.contains('kotlin-stdlib')){
                    details.useVersion rootProject.ext.kotlin_version
                }
                if (details.requested.group == 'androidx.core' && details.requested.name.contains('core-ktx')){
                    details.useVersion rootProject.ext.androidKtxVersion
                }
                if (details.requested.group == 'com.evernote' && details.requested.name.contains('evernote-api')){
                    details.useVersion '244.0-SNAPSHOT'
                }
                // Timber 5.0.0 is not found and required by pagecam-android. Use a private 5.0.0.1 copy of the library.
                if (details.requested.group == 'com.jakewharton.timber' && details.requested.name == 'timber-common') {
                    details.useVersion '5.0.0.1'
                }
                // com.squareup.okhttp3:okhttp-urlconnection
                if (details.requested.group == 'com.squareup.okhttp3' && details.requested.name == 'okhttp-urlconnection') {
                    details.useVersion '4.9.1.2-EN'
                }
                if (details.requested.group == 'org.jetbrains' && details.requested.name == 'annotations') {
                    details.useVersion '13.0'
                }
            }
        }
    }
}

app/build.gradle:

apply plugin: 'com.android.application'
apply plugin: "com.facebook.react"
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply from: "$rootDir/gradle/ktlint.gradle"
apply from: "$rootDir/gradle/version.gradle"
import java.util.regex.Matcher
import java.util.regex.Pattern

import com.android.build.OutputFile
import com.android.build.gradle.internal.dsl.SigningConfig

/**
 * This is the configuration block to customize your React Native Android app.
 * By default you don't need to apply any configuration, just uncomment the lines you need.
 */
react {
    /* Folders */
    //   The root of your project, i.e. where "package.json" lives. Default is '..'
    // root = file("../")
    //   The folder where the react-native NPM package is. Default is ../node_modules/react-native
    // reactNativeDir = file("../node_modules/react-native")
    //   The folder where the react-native Codegen package is. Default is ../node_modules/react-native-codegen
    // codegenDir = file("../node_modules/react-native-codegen")
    //   The cli.js file which is the React Native CLI entrypoint. Default is ../node_modules/react-native/cli.js
    // cliFile = file("../node_modules/react-native/cli.js")
    /* Variants */
    //   The list of variants to that are debuggable. For those we're going to
    //   skip the bundling of the JS bundle and the assets. By default is just 'debug'.
    //   If you add flavors like lite, prod, etc. you'll have to list your debuggableVariants.
    debuggableVariants = ["regularDebug"]
    /* Bundling */
    //   A list containing the node command and its flags. Default is just 'node'.
    // nodeExecutableAndArgs = ["node"]
    //
    //   The command to run when bundling. By default is 'bundle'
    // bundleCommand = "ram-bundle"
    //
    //   The path to the CLI configuration file. Default is empty.
    // bundleConfig = file(../rn-cli.config.js)
    //
    //   The name of the generated asset file containing your JS bundle
    // bundleAssetName = "MyApplication.android.bundle"
    //
    //   The entry file for bundle generation. Default is 'index.android.js' or 'index.js'
    // entryFile = file("../js/MyApplication.android.js")
    //
    //   A list of extra flags to pass to the 'bundle' commands.
    //   See https://github.com/react-native-community/cli/blob/main/docs/commands.md#bundle
    // extraPackagerArgs = []
    /* Hermes Commands */
    //   The hermes compiler command to run. By default it is 'hermesc'
    // hermesCommand = "$rootDir/my-custom-hermesc/bin/hermesc"
    //
    //   The list of flags to passinitialConstants to the Hermes compiler. By default is "-O", "-output-source-map"
    // hermesFlags = ["-O", "-output-source-map"]
    // hermesFlags = ["-O"]
}

/**
 * Set this to true to create four separate APKs instead of one,
 * one for each native architecture. This is useful if you don't
 * use App Bundles (https://developer.android.com/guide/app-bundle/)
 * and want to have separate APKs to upload to the Play Store.
 */

def enableSeparateBuildPerCPUArchitecture = false
String ANDROID_SPLIT_ARCHES = System.getenv('ANDROID_SPLIT_ARCHES')
if (ANDROID_SPLIT_ARCHES == true) {
    enableSeparateBuildPerCPUArchitecture = true
}

/**
 * Set this to true to Run Proguard on Release builds to minify the Java bytecode.
 */
def enableProguardInReleaseBuilds = true

/**
 * The preferred build flavor of JavaScriptCore (JSC)
 *
 * For example, to use the international variant, you can use:
 * `def jscFlavor = 'org.webkit:android-jsc-intl:+'`
 *
 * The international variant includes ICU i18n library and necessary data
 * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that
 * give correct results when using with locales other than en-US. Note that
 * this variant is about 6MiB larger per architecture than default.
 */
def jscFlavor = 'org.webkit:android-jsc-intl:+'

/**
 * Private function to get the list of Native Architectures you want to build.
 * This reads the value from reactNativeArchitectures in your gradle.properties
 * file and works together with the --active-arch-only flag of react-native run-android.
 */
def reactNativeArchitectures() {
    def value = project.getProperties().get("reactNativeArchitectures")
    return value ? value.split(",") : ["armeabi-v7a", "x86", "x86_64", "arm64-v8a"]
}

android {
    // ndkVersion rootProject.ext.ndkVersion

    compileSdkVersion rootProject.ext.compileSdkVersion
    buildToolsVersion rootProject.ext.buildToolsVersion

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_11
        targetCompatibility JavaVersion.VERSION_11
    }

    kotlinOptions {
        jvmTarget=11
    }

    aaptOptions {
        noCompress "html"
    }

    namespace "com.evernote"

    defaultConfig {
        applicationId 'com.evernote'
        minSdkVersion rootProject.ext.minSdkVersion
        compileSdkVersion rootProject.ext.compileSdkVersion
        targetSdkVersion rootProject.ext.targetSdkVersion
        vectorDrawables.useSupportLibrary = true


        // abifilters cannot be active with split architectures
        if (enableSeparateBuildPerCPUArchitecture != true) {
            ndk {
                abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
            }
        }

        renderscriptTargetApi 23
        renderscriptSupportModeEnabled true

        buildConfigField 'boolean', 'TEST_ENVIRONMENT', 'false'

        println "Features: $rootProject.properties.features"
        rootProject.properties.features.each { featureName, enabled ->
            buildConfigField 'boolean', featureName, enabled ?: "false"
        }

        missingDimensionStrategy 'react-native-camera', 'general'
        // react-native-iap: we only use the Google Play flavor
        missingDimensionStrategy 'store', 'play'
        multiDexEnabled true

        manifestPlaceholders = [
                requestLegacyExternalStorage: "true",
                profileFromShell: "false",
                profileEnabled: "false"
        ]
    }

    flavorDimensions 'internalBuildType'

    signingConfigs {
        debug {
            println("Using debug keystore");
            def props = new Properties()
            file("../keystores/debug.keystore.properties").withInputStream { props.load(it) }

            keyAlias  props.getProperty("key.alias")
            storeFile  file(props.getProperty("key.store"))
            storePassword props.getProperty("key.store.password")
            keyPassword  props.getProperty("key.alias.password")
        }

        release {
            println("Using local release keystore");
            def props = new Properties()
            file("../keystores/release.keystore.properties").withInputStream { props.load(it) }

            keyAlias  props.getProperty("key.release.alias")
            storeFile  file(props.getProperty("key.release.store"))
            storePassword props.getProperty("key.release.store.password")
            keyPassword  props.getProperty("key.release.alias.password")
        }

        production {
            println("Using build environment's release keystore:regularRelease");
//            keyAlias  release_key_alias
//            storeFile  file("${System.env.ANDROID_HOME}/keys/AndroidKeystore.keystore")
//            storePassword release_key_store_password
//            keyPassword  release_key_password
        }


    }

    buildTypes {
        release {
            buildConfigField 'String', 'CEC_HOST', '"https://cec.svc.evernote.com"'
            buildConfigField 'String', 'CEC_API_KEY', '"neutron"'
            buildConfigField 'String', 'CEC_SECRET', '"A75B7C90-AA91-4567-93A4-A843F776E411"'
            // enable code shrinking
            // minifyEnabled true
            // enable resource shrinking
            // shrinkResources true
            minifyEnabled enableProguardInReleaseBuilds
            proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
        }
        debug {
            buildConfigField 'String', 'CEC_HOST', '"https://cec.svc-stage.evernote.com"'
            buildConfigField 'String', 'CEC_API_KEY', '"neutron"'
            buildConfigField 'String', 'CEC_SECRET', '"9E31F2FC-ECD7-4809-8044-15B6363E6C25"'

            signingConfig signingConfigs.debug

            manifestPlaceholders = [
                    requestLegacyExternalStorage: "false",
                    profileFromShell: "true",
                    profileEnabled: "true"
            ]
        }
    }

    productFlavors {
        regular {
            ext {
                useProductionKeystore = true
            }
        }

        pre {
            applicationIdSuffix '.pre'
            ext {
                useProductionKeystore = false
            }
        }

        automation {
            applicationIdSuffix '.automation'
            buildConfigField 'boolean', 'TEST_ENVIRONMENT', 'true'
            ext {
                useProductionKeystore = false
            }

            manifestPlaceholders = [
                    requestLegacyExternalStorage: "true",
                    profileFromShell: "true",
                    profileEnabled: "true"
            ]
        }

        preview {
            buildConfigField 'boolean', 'PRIVATE_PREVIEW', 'true'
            ext {
                useProductionKeystore = false
            }
        }
    }

    android.productFlavors.each { flavor ->
        if (flavor.ext.useProductionKeystore) {
            println("Building flavor [${flavor.name}] - use production keystore if available")
//            flavor.signingConfig = getSigninConfigProduction()
            if (env.hasReleaseKeyStore) {
                flavor.signingConfig = signingConfigs.production
            } else if (!isDebug()) {
                flavor.signingConfig = signingConfigs.release
            } else {
                flavor.signingConfig = signingConfigs.debug
            }
        } else {
            println("Building flavor [${flavor.name}] - use local keystore")
//            flavor.signingConfig = getSigninConfigLocal()
            if (!isDebug()) {
                flavor.signingConfig = signingConfigs.release
            } else {
                flavor.signingConfig = signingConfigs.debug
            }
        }
    }

    splits {
        abi {
            reset()
            enable enableSeparateBuildPerCPUArchitecture
            universalApk false  // If true, also generate a universal APK
            include (*reactNativeArchitectures())
        }
    }
    // applicationVariants are e.g. debug, release
    applicationVariants.all { variant ->
        variant.outputs.each { output ->
            // For each separate APK per architecture, set a unique version code as described here:
            // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
            def versionCodes = ['armeabi-v7a': 1, 'x86': 2, 'arm64-v8a': 3, 'x86_64': 4]
            def abi = output.getFilter(OutputFile.ABI)
            if (abi != null) {  // null for the universal-debug, universal-release variants
                output.versionCodeOverride =
                defaultConfig.versionCode * 1000 + versionCodes.get(abi)
            }
        }
    }

    packagingOptions {
        
        pickFirst '**/arm64-v8a/libc++_shared.so'
        pickFirst '**/arm64-v8a/libjsc.so'
        pickFirst '**/armeabi-v7a/libc++_shared.so'
        pickFirst '**/armeabi-v7a/libjsc.so'
        pickFirst '**/x86/libc++_shared.so'
        pickFirst '**/x86/libjsc.so'
        pickFirst '**/x86_64/libc++_shared.so'
        pickFirst '**/x86_64/libjsc.so'

        /**
         * https://developer.android.com/ndk/guides/abis.html?hl=en#sa
         * Note: Historically the NDK supported ARMv5 (armeabi), and 32-bit and 64-bit MIPS,
         * but support for these ABIs was removed in NDK r17.
         */
        exclude 'lib/armeabi/**'
        exclude 'lib/mips/**'
        exclude 'lib/mips64/**'

        exclude 'META-INF/DEPENDENCIES'
        exclude 'META-INF/gradle/incremental.annotation.processors'
        exclude 'META-INF/*.kotlin_module'
    }

    aaptOptions {
        noCompress 'png', 'js', 'json'
    }

    subprojects {
        beforeEvaluate { project ->
            if (project.hasProperty('android')) {
                android {
                    compileSdkVersion rootProject.ext.compileSdkVersion
                    buildToolsVersion rootProject.ext.buildToolsVersion
                }
            }
        }
    }

    testOptions {
        unitTests {
            returnDefaultValues = true
        }
    }
}

dependencies {

    // The version of react-native is set by the React Native Gradle Plugin
    implementation("com.facebook.react:react-android")

    implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.0.0'
    implementation project(':react-native-iap')
    implementation 'com.facebook.fresco:animated-base-support:1.3.0'
    implementation 'com.facebook.fresco:fresco:2.0.0'
    implementation 'com.facebook.soloader:soloader:0.10.4'
    implementation 'com.facebook.fresco:animated-gif:2.6.0'
    implementation 'com.iterable:iterableapi:3.4.9'
    implementation 'com.android.support:support-core-utils:28.0.0'
    implementation project(':react-native-image-crop-picker')
    implementation project(':@react-native-community_async-storage')
    implementation project(':react-native-webview')
    implementation project(':react-native-safe-area-context')
    implementation project(':en-react-native-workers')
    implementation project(':appcenter-crashes')
    implementation project(':appcenter')
    implementation project(':react-native-sqlite-storage')
    implementation project(':react-native-trait-collection')
    implementation project(':en-react-native-local-notifications')
    implementation project(':react-native-remote-notifications')
    implementation project(':en-react-native-eventsource')
    implementation project(':react-native-device-performance')
    implementation project(':react-native-modal-translucent')
    implementation project(':react-native-web-server')
    implementation project(':en-react-native-resource-cache')
    implementation project(':external-intents')
    implementation project(':editor-helper')
    implementation project(':editor-webview')
    implementation project(':react-native-inappbrowser-reborn')
    implementation project(':widget-helper')
    implementation project(':audio-manager')
    implementation project(':keyboard-helper')
    implementation project(':rn-fetch-blob')
    implementation project(':biometrics')
    implementation project(':secrets-handler')
    implementation project(':lifecycle')
    implementation project(':root-view-background')
    implementation project(':react-native-keychain')
    implementation project(':remote-config-manager')
    implementation project(':react-native-background-fetch')
    implementation project(':legacy-upgrade')
    implementation project(':log-helper')
    implementation project(':async-task-helper')
    implementation project(':en-search-engine-react-native')
    implementation project(':neutron-performance')
    implementation project(':react-native-background-timer')
    implementation project(':react-native-haptic-feedback')
    implementation project(':react-native-rate')
    implementation "androidx.appcompat:appcompat:${rootProject.ext.androidXVersion}"
    implementation "androidx.activity:activity:1.5.1"
    implementation "androidx.fragment:fragment:1.5.2"
    implementation "androidx.recyclerview:recyclerview:1.1.0"
    // implementation "androidx.gridlayout:gridlayout:1.1.0"
    // For control over item selection of both touch and mouse driven selection
    implementation "androidx.recyclerview:recyclerview-selection:1.1.0-rc03"
    implementation 'com.google.firebase:firebase-messaging:19.0.0'
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"  // From node_modules
    implementation("io.reactivex.rxjava2:rxkotlin:$kotlin_rx_version")
    implementation "com.evernote.native:commons:${rootProject.ext.internal_artifact_version}"
    implementation "com.evernote.conduit:cachediteminfo:${rootProject.ext.internal_artifact_version}"
    implementation "com.evernote.neutron:reactcommons:${rootProject.ext.internal_artifact_version}"
    implementation "com.evernote.native:resources:${rootProject.ext.internal_artifact_version}"
    implementation "com.evernote.performance:pieprofiler:${rootProject.ext.internal_artifact_version}"
    implementation "com.evernote.native:share:${rootProject.ext.internal_artifact_version}"
    implementation "com.squareup.okhttp3:okhttp-urlconnection:4.4.1"

    implementation 'org.jetbrains:annotations:13.0'

    // IAP dependencies
    implementation 'com.android.billingclient:billing:5.1.0'

    // Kochava dependencies
    implementation 'com.google.android.gms:play-services-ads-identifier:15.0.1'
    implementation 'com.android.installreferrer:installreferrer:1.0'
    implementation 'com.google.android.instantapps:instantapps:1.1.0'

    if (hermesEnabled.toBoolean()) {
        implementation("com.facebook.react:hermes-android")
    } else {
        implementation jscFlavor
    }


    // Flipper dependencies
    debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}")
    debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
        exclude group:'com.squareup.okhttp3', module:'okhttp'
    }
    debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}")

    testImplementation "junit:junit:4.13.2"
    testImplementation "org.mockito:mockito-inline:4.6.1"
    testImplementation "org.mockito.kotlin:mockito-kotlin:4.0.0"
    testImplementation "org.json:json:20140107"


}

configurations.implementation {
    exclude group: 'org.jetbrains' , module:'annotations'
}

configurations.implementation {
    exclude group: 'org.jetbrains' , module:'annotations'
}

task copyCE {
    println('Delete web (CE/Ink/Skitch) files from prior build')
    delete "$rootDir/app/src/main/assets/web"
    println('Copying web (CE/Ink/Skitch) files')
    copy {
        from "$rootDir/../assets/web"
        into "$rootDir/app/src/main/assets/web"
    }
    println('web (CE/Ink/Skitch) files copied')
}

preBuild.dependsOn(copyCE)

task copyFiles {
    println('copy clipper files')
    copy {
        from "$rootDir/../assets/web/webclipper/clipper.js"
        into "$rootDir/app/src/main/assets/"
    }
}

preBuild.dependsOn(copyFiles)

preBuild.dependsOn(copyCE)

project.gradle.buildFinished {
    println('Deleting web (CE/Ink/Skitch) files after build')
    delete 'src/main/assets/web'
}

repositories {
    google()
    mavenCentral()
    maven {
        url 'https://maven.vpn.etonreve.com/repo'
    }
}

Boolean isDebug() {
    return getGradle().getStartParameter().getTaskRequests().toString().toLowerCase().contains("debug")
}

apply from: file('../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle'); applyNativeModulesAppBuildGradle(project)
apply plugin: 'com.google.gms.google-services'

alexkrav avatar Mar 06 '23 21:03 alexkrav

@alexkrav A couple of questions:

  1. Have you enabled New Architecture?
  2. Do you have a reproducer to share?

cortinico avatar Mar 07 '23 11:03 cortinico

@cortinico

  1. Have you enabled New Architecture?
newArchEnabled=false
hermesEnabled=true
  1. Do you have a reproducer to share?

No, I do not. This is huge project.

alexkrav avatar Mar 07 '23 16:03 alexkrav

No, I do not. This is huge project.

Then please consider creating a reprodcuer (a smaller project that crashes in your same way).

cortinico avatar Mar 09 '23 13:03 cortinico

:warning: Missing Reproducible Example
:information_source: It looks like your issue is missing a reproducible example. Please provide a Snack or a repository that demonstrates the issue you are reporting in a minimal, complete, and reproducible manner.

github-actions[bot] avatar Mar 09 '23 13:03 github-actions[bot]

This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.

github-actions[bot] avatar Apr 02 '23 18:04 github-actions[bot]

This issue was closed because the author hasn't provided the requested feedback after 7 days.

github-actions[bot] avatar Apr 09 '23 18:04 github-actions[bot]