REACT NATIVE找不到com.google.firebase:firebase-id:.iid的新更新破坏了项目



一些信息首先:这不是我的工作站,这个笔记本是我工作的公司的,我确实有一些访问权限。

有些事情对环境来说很奇怪,但我们可以工作,我不是唯一一个对环境有问题的人,但我不认为这与env有关,而是与最新的iid更新有关。

我必须通过的两个终端来启动项目

  • 使用sudo su是为了防止环境中的一些错误

    1 > [sudo su] yarn react-native start
    2 > [sudo su] yarn android:android:debug
    

导致此错误:

* What went wrong:
Could not determine the dependencies of task ':app:mergeDebugAssets'.
> Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
> Could not find com.google.firebase:firebase-iid:.
Required by:
project :app > project :@react-native-firebase_iid

**导入信息:@react-native-firebase_id于2020年7月7日昨天收到更新所以在此之前,所有的都在工作

遵循package.json文件

"dependencies": {
"@react-native-community/async-storage": "^1.6.1",
"@react-native-community/netinfo": "^5.6.2",
"@react-native-firebase/analytics": "^6.1.0",
"@react-native-firebase/app": "^6.1.0", DOWNGRADING DID NOT HELP ( version bellow )
"@react-native-firebase/iid": "^6.3.4", DOWNGRADING DID NOT HELP ( version bellow )
"axios": "^0.19.0",
"native-base": "^2.13.1",
"prop-types": "^15.7.2",
"react": "16.8.6",
"react-native": "^0.60.4",
"react-native-barcode-builder": "^1.0.5",
"react-native-config": "^0.12.0",
"react-native-dialog": "^5.6.0",
"react-native-elements": "^1.2.0",
"react-native-flip-card": "^3.5.5",
"react-native-geolocation-service": "^3.1.0",
"react-native-gesture-handler": "^1.3.0",
"react-native-image-picker": "^1.1.0",
"react-native-keychain": "^3.1.3",
"react-native-map-link": "^2.5.1",
"react-native-maps": "^0.25.0",
"react-native-masked-text": "^1.13.0",
"react-native-screens": "^2.3.0",
"react-native-splash-screen": "^3.2.0",
"react-native-touch-id": "^4.4.1",
"react-native-vector-icons": "^6.6.0",
"react-navigation": "^3.11.1",
"uninstall": "0.0.0"
},

纱线表-图案"@反应天然火球";中的结果

yarn list v1.22.4
├─ @react-native-firebase/analytics@6.7.2
├─ @react-native-firebase/app-types@6.7.1
├─ @react-native-firebase/app@6.7.1
└─ @react-native-firebase/iid@6.7.1
Done in 0.49s.

接下来的另一个类似于这个问题的问题给了我这些选项

rm -rf node_modules/
rm -rf yarn.lock
./gradlew clean
yarn react-native link react-native-firebase
yarn react-native start --reset-cache
tryng to sync the android project on android studio
IOS also having problems
following the iid instalation to react native from firebase

遗憾的是,没有成功

纱线反应天然链接反应天然火球导致

$ /home/raiadrogasil.com/kamoraes/Workspace/ProjetosRd/univers-app-react/node_modules/.bin/react-native link react-native-firebase
warn The following packages use deprecated "rnpm" config that will stop working from next release:
- react-native-maps: https://npmjs.com/package/react-native-maps
Please notify their maintainers about it. You can find more details at https://github.com/react-native-community/cli/blob/master/docs/configuration.md#migration-guide.
error Unknown dependency. Make sure that the package you are trying to link is already installed in your "node_modules" and present in your "package.json" dependencies. Run CLI with --verbose flag for more details.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.```

设置。渐变

rootProject.name = 'universAppReact'
include ':react-native-touch-id'
project(':react-native-touch-id').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-touch-id/android')
include ':react-native-gesture-handler'
project(':react-native-gesture-handler').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-gesture-handler/android')
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
include ':@react-native-firebase_app'
project(':@react-native-firebase_app').projectDir = new File(rootProject.projectDir, './../node_modules/@react-native-firebase/app/android')
include ':app'

build.gradle

// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext {
buildToolsVersion = "28.0.3"
minSdkVersion = 16
compileSdkVersion = 28
targetSdkVersion = 28
supportLibVersion = "28.0.0"
}
repositories {
google()
jcenter()
}
dependencies {
classpath("com.android.tools.build:gradle:3.4.1")
classpath 'com.google.gms:google-services:4.3.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
mavenLocal()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url("$rootDir/../node_modules/react-native/android")
}
maven {
// Android JSC is installed from npm
url("$rootDir/../node_modules/jsc-android/dist")
}
google()
jcenter()
}
}

该项目在我们尝试了一个新的克隆后停止了工作,该项目的ro解决了一些问题。如果需要更多信息,请告诉我。

试着玩软件包的版本。在我的情况下,我在版本之前清除了向上箭头,它起了作用。别担心,毕竟我恢复了变化,一切都很好。

"@react-native-firebase/iid": "6.3.4", DOWNGRADING DID NOT HELP ( version bellow )
"@react-native-firebase/iid": "^6.3.4", DOWNGRADING DID NOT HELP ( version bellow )

最新更新