Closed oferRounds closed 3 years ago
hey mate, can you share your package.js? first guess is that you dont have @react-native-firebase/app
listed in dependencies
Hi mate, thanks! it is there actually, here is the all file. It actually stated when I changed this two android vriables to true
, following this article:
// app/builld.gradle
def enableProguardInReleaseBuilds = true
def enableSeparateBuildPerCPUArchitecture = true
{
"name": "Bob",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"postinstall": "npx jetify && patch-package",
"test": "jest --coverage",
"tsc": "tsc",
"clean": "rimraf artifacts",
"build": "./localizationDownload.sh && npm run clean && npm run tsc --",
"lint": "tslint src/**/*.ts",
"watch": "npm run build -- -w",
"start:ios": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios'",
"start:ios_6": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 6\"'",
"start:ios_se": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone SE\"'",
"start:ios_8": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 8\"'",
"start:ios_8p": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 8 Plus\"'",
"start:ios_x": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone X\"'",
"start:ios_xr": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone XR\"'",
"start:ios_xs": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone XS\"'",
"start:ios_xsm": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone XS Max\"'",
"start:ios_11": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 11\"'",
"start:ios_xp": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 11 Pro\"'",
"start:ios_12": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 12\"'",
"start:ios_12p": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 12 Pro\"'",
"start:ios_12m": "npm run build && concurrently -r 'npm run watch' 'react-native run-ios --simulator=\"iPhone 12 mini\"'",
"start:android": "npm run build && concurrently -r 'npm run watch' 'react-native run-android'"
},
"dependencies": {
"@babel/plugin-proposal-decorators": "^7.10.5",
"@react-native-community/async-storage": "^1.11.0",
"@react-native-community/clipboard": "^1.5.1",
"@react-native-community/cookies": "^3.0.0",
"@react-native-community/datetimepicker": "3.4.0",
"@react-native-community/google-signin": "^5.0.0",
"@react-native-community/netinfo": "^5.9.5",
"@react-native-community/push-notification-ios": "^1.3.0",
"@react-native-community/segmented-control": "^2.2.1",
"@react-native-firebase/app": "12.1.0",
"@react-native-firebase/crashlytics": "12.1.0",
"@react-native-firebase/perf": "12.1.0",
"@segment/analytics-react-native": "^1.2.1",
"@segment/analytics-react-native-firebase": "^1.2.1",
"@types/lodash": "^4.14.106",
"@types/react-native-i18n": "^2.0.0",
"add": "^2.0.6",
"axios": "^0.16.2",
"axios-retry": "^3.0.2",
"babel-plugin-transform-typescript-metadata": "^0.3.0",
"babel-preset-es2015": "^6.24.1",
"class-transformer": "^0.1.7",
"compare-versions": "^3.6.0",
"country-code-emoji": "^2.2.0",
"deprecated-react-native-listview": "^0.0.6",
"emoji-name-map": "^1.2.9",
"emoji-unicode": "^2.0.0",
"flat": "^5.0.2",
"grapheme-splitter": "^1.0.4",
"html-truncate": "git+https://github.com/huang47/nodejs-html-truncate#43c749e2c3bcdd0b8064caf6f27e0addacee7dc6",
"intl": "^1.2.5",
"intl-locales-supported": "^1.8.12",
"javascript-time-ago": "2.3.4",
"jest-cli": "^23.1.0",
"js-base64": "^2.4.9",
"js-pinyin": "^0.1.9",
"js-sha256": "^0.9.0",
"jsc-android": "^241213.1.0",
"jwt-decode": "^2.2.0",
"libphonenumber-js": "^1.7.57",
"lodash": "^4.17.10",
"md5": "^2.2.1",
"moment": "^2.22.2",
"moment-duration-format": "git+https://github.com/jsmreese/moment-duration-format.git#796c9c8e11dfc043842c12785dadfb210f33f380",
"moment-range": "^3.0.3",
"nanoid": "^3.1.10",
"native-base": "2.13.13",
"npm": "^6.2.0",
"patch-package": "^6.1.2",
"react": "16.13.1",
"react-intl": "^5.9.2",
"react-localization": "^1.0.15",
"react-native": "0.63.4",
"react-native-android-badge": "^0.4.3",
"react-native-android-settings-library": "1.0.5",
"react-native-animatable": "^1.2.4",
"react-native-app-auth": "^5.1.2",
"react-native-autogrow-textinput": "^5.4.0",
"react-native-azure-auth": "1.8.1",
"react-native-background-fetch": "^3.1.0",
"react-native-background-geolocation-android": "git+ssh://git@github.com/transistorsoft/react-native-background-geolocation-android.git#4de83b6c1f7fb6cf349b4249dd98736c3bdf24b1",
"react-native-blink-view": "0.0.6",
"react-native-bottom-sheet-behavior": "2.0.0",
"react-native-buglife": "git+https://github.com/oferRounds/react-native-buglife.git#82335ec4467a50aedb2ac93cd711262e238fcbb8",
"react-native-contacts": "^6.0.3",
"react-native-dash": "0.0.9",
"react-native-device-info": "^5.6.2",
"react-native-device-time-format": "^2.3.0",
"react-native-document-picker": "^3.5.3",
"react-native-elements": "^3.4.0",
"react-native-fade-in-out": "^1.0.3",
"react-native-fast-image": "git+https://github.com/oferRounds/react-native-fast-image.git#0124a28e6a77243da21755689bc2bd48034e1bbe",
"react-native-file-viewer": "^2.1.4",
"react-native-fix-image": "^2.1.0",
"react-native-floating-action": "^1.19.1",
"react-native-fs": "^2.16.6",
"react-native-gesture-handler": "^1.6.1",
"react-native-get-random-values": "^1.4.0",
"react-native-google-places-autocomplete": "^2.1.3",
"react-native-haptic-feedback": "^1.9.0",
"react-native-htmlview": "0.16.0",
"react-native-hud-hybrid": "^0.37.0",
"react-native-hyperlink": "0.0.11",
"react-native-i18n": "^2.0.15",
"react-native-image-capinsets": "git+https://github.com/oferRounds/react-native-image-capinsets.git#2407c3c092a26fa1b4ee87f87b4048e3d6fae09b",
"react-native-image-crop-picker": "^0.32.2",
"react-native-image-resizer": "^1.4.2",
"react-native-image-zoom-viewer": "2.2.27",
"react-native-keyboard-accessory": "^0.1.10",
"react-native-keyboard-aware-scroll-view": "^0.4.1",
"react-native-keyboard-input": "6.0.2",
"react-native-keychain": "4.0.5",
"react-native-localization": "git+https://github.com/stefalda/ReactNativeLocalization",
"react-native-localize": "^1.4.0",
"react-native-mentions-editor": "git+https://github.com/oferRounds/react-native-mentions-editor#a60fa944cf87914eacf284d85489054e363f0a11",
"react-native-modal": "^11.5.3",
"react-native-navigation": "6.12.2",
"react-native-onesignal": "4.1.0",
"react-native-open-maps": "^0.3.4",
"react-native-parsed-text": "^0.0.22",
"react-native-permissions": "3.0.3",
"react-native-picker": "git+https://github.com/oferRounds/react-native-picker.git",
"react-native-platform-touchable": "^1.1.1",
"react-native-progress": "^4.0.3",
"react-native-prompt-android": "^0.3.5",
"react-native-push-notification": "7.3.1",
"react-native-rate": "^1.2.1",
"react-native-reanimated": "^1.10.1",
"react-native-safe-area": "^0.5.1",
"react-native-safe-area-context": "^3.2.0",
"react-native-sms": "^1.9.0",
"react-native-sound": "^0.11.0",
"react-native-startup-trace": "^0.4.0",
"react-native-status-bar-height": "^2.4.0",
"react-native-swiper": "1.6.0",
"react-native-text-input-mask": "^3.0.4",
"react-native-tooltips": "1.0.2",
"react-native-vector-icons": "^7.0.0",
"react-native-webview": "^10.3.2",
"react-redux": "^5.0.6",
"react-timer-mixin": "^0.13.4",
"reanimated-bottom-sheet": "^1.0.0-alpha.20",
"redux": "3.7.2",
"redux-logger": "^3.0.6",
"redux-promise": "^0.5.3",
"redux-promise-middleware": "^4.4.1",
"redux-thunk": "^2.2.0",
"reflect-metadata": "^0.1.10",
"regenerator-runtime": "^0.13.1",
"reselect": "^4.0.0",
"rn-pendo-sdk": "^2.6.1",
"rn-placeholder": "2.0.0",
"url-regex": "^5.0.0",
"yarn": "^1.22.4"
},
"resolutions": {
"babel-core": "7.0.0-bridge.0"
},
"rnpm": {
"assets": [
"./src/assets/fonts/"
]
},
"devDependencies": {
"@babel/core": "^7.8.4",
"@babel/plugin-proposal-class-properties": "^7.1.0",
"@babel/plugin-proposal-object-rest-spread": "^7.0.0",
"@babel/preset-env": "^7.1.6",
"@babel/preset-react": "^7.0.0",
"@babel/preset-typescript": "^7.1.0",
"@babel/runtime": "^7.8.4",
"@types/jest": "^20.0.8",
"@types/node": "^10.11.0",
"@types/react": "^16.7.6",
"@types/react-native": "0.63.1",
"@types/react-native-datepicker": "^1.6.3",
"@types/react-native-htmlview": "^0.12.2",
"@types/redux-promise-middleware": "0.0.11",
"babel-core": "^7.0.0-bridge.0",
"babel-jest": "^25.1.0",
"babel-preset-react-native": "5.0.2",
"concurrently": "^3.5.1",
"jest": "^25.1.0",
"jest-preset-typescript-react-native": "^1.2.0",
"jest-serializer-enzyme": "^1.0.0",
"jetifier": "^1.6.6",
"metro-react-native-babel-preset": "^0.59.0",
"react-native-typescript-transformer": "^1.2.13",
"react-test-renderer": "16.13.1",
"redux-mock-store": "^1.3.0",
"rimraf": "^2.6.1",
"schedule": "^0.4.0",
"ts-jest": "23.10.5",
"tslint": "^5.6.0",
"tslint-eslint-rules": "^5.4.0",
"tslint-react": "^3.6.0",
"tslint-react-recommended": "^1.0.15",
"typescript": "^3.1.6"
},
"jest": {
"preset": "jest-preset-typescript-react-native",
"roots": [
"<rootDir>/__tests__"
],
"setupFiles": [
"<rootDir>/scripts/jest/setup.js",
"<rootDir>/node_modules/appcenter/test/AppCenterMock.js",
"<rootDir>/node_modules/react-native-localization.js",
"./config/jest/mock.fetch.js",
"./config/jest/react-native-localization.js"
],
"moduleFileExtensions": [
"ts",
"tsx",
"js"
],
"transform": {
"^.+\\.ts?$": "ts-jest",
"^.+\\.tsx?$": "ts-jest",
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js"
},
"collectCoverage": true,
"coverageDirectory": "coverage",
"coverageReporters": [
"text-summary",
"html"
],
"testPathIgnorePatterns": [
"\\.snap$",
"<rootDir>/node_modules/",
"<rootDir>/lib/"
],
"collectCoverageFrom": [
"**/*.{js,jsx}",
"artifacts/**/*.js",
"!artifacts/**/*.spec.js",
"!artifacts/**/*.index.js",
"!<rootDir>/node_modules/"
]
}
}
oh nice. actually digging into this more I see that vnull
in
ReactNativeFirebase WARNING: NPM package 'react-native-startup-trace' depends on '@react-native-firebase/app' vnull but found v12.1.0, this might cause build issues or runtime crashes.
is coming from https://github.com/bamlab/react-native-performance/blob/master/react-native-startup-trace/android/build.gradle#L92 and it looks like that is null cause the correct peerDep
is not listed in the project's package.json
here https://github.com/bamlab/react-native-performance/blob/master/react-native-startup-trace/package.json#L22
ahmmm... Thank you! Do you what I can do to fix it?
Hi @oferRounds,
I don't think the warning from npm is necessarily related to the error.
Could you share a bit more the logs before and after Task :app:transformClassesAndResourcesWithR8ForRelease FAILED
? I think there should hopefully be something more precise there.
I've tried enabling proguard and separate builds and had no issue building a release build on a test app with this module.
However, this article seems to quite old. 🤔 Today I would personally recommend against both options unless you do see a great impact.
proguard
might incur more issues with other packages and proguard files can be tricky to manageThen again, the last time I wanted to decrease my APK size, it was simple enough 😅: I just analysed my APK with Android studio, realized my images were too big and converted them all to webp. We went from ~40MB of assets to ~10MB
Hi @Almouro what a great answer – thank you for this info!!! I actually just understood it later, after I wrote, that I actually don’t need – we do use bundle instead of apk, so it seems we’re good
Thank you again! Really appreciate your reply. Closing this issue
Getting:
Any idea how solve?