gpt4 book ai didi

android - 序言中不能有内容。在构建我的 android 项目时出现此错误

转载 作者:行者123 更新时间:2023-12-03 06:28:24 25 4
gpt4 key购买 nike

我在过去 24 小时内收到此错误。请帮我解决这个问题。更新依赖版本后出现此错误。我还添加了 Exo 播放器依赖项。我不知道真正的问题是什么。
我尝试了以下事情:
**清理并重建项目**
** 删除 C:/users/.android/cache 中的缓存文件**
** 重启安卓工作室**
** 检查 xml 文件的编码方案**
这是我的构建 gradle(app) 文件:

apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'

android {
compileSdkVersion 29
defaultConfig {
applicationId "com.example.eventscheduling"
minSdkVersion 22
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
lintOptions {
checkReleaseBuilds false
// Or, if you prefer, you can continue to check for errors in release builds,
// but continue the build even when errors are found:
abortOnError false
}
}

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.navigation:navigation-fragment:2.3.0'
implementation "androidx.constraintlayout:constraintlayout:2.0.1"

implementation 'androidx.navigation:navigation-ui:2.3.0'
implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0'

implementation 'com.google.firebase:firebase-functions:19.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
implementation 'com.google.android.gms:play-services-maps:17.0.0'
implementation "com.google.android.gms:play-services-location:17.0.0"
// Firebase dependencies
implementation 'com.google.firebase:firebase-storage:19.2.0'
implementation 'com.google.firebase:firebase-auth:19.3.2'
implementation 'com.google.firebase:firebase-firestore:21.6.0'
implementation 'com.firebaseui:firebase-ui-firestore:6.2.1'
// glide libraries
implementation 'com.github.bumptech.glide:glide:4.11.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.11.0'

// CircleView images
implementation 'de.hdodenhof:circleimageview:3.1.0'
// Material dependency
implementation 'com.google.android.material:material:1.2.1'

//Stylable Toast
implementation 'com.muddzdev:styleabletoast:2.2.3'

// GraphView dependency
implementation 'com.github.PhilJay:MPAndroidChart:v3.1.0'

// Volley library
implementation 'com.android.volley:volley:1.1.1'
}
我一次又一次地收到这个错误。
Build gradle(app)
这是构建 gradle(module)
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
repositories {
google()
jcenter()

}
dependencies {
classpath 'com.android.tools.build:gradle:4.0.1'
classpath 'com.google.gms:google-services:4.3.3'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}

allprojects {
repositories {
google()
jcenter()
maven { url 'https://jitpack.io' }


}
}

task clean(type: Delete) {
delete rootProject.buildDir
}
这是 list 文件
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.eventscheduling">
<!--
The ACCESS_COARSE/FINE_LOCATION permissions are not required to use
Google Maps Android API v2, but you must specify either coarse or fine
location permissions for the 'MyLocation' functionality.
-->
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name=".eventorg.ui.evntOrg_setting" />
<activity android:name=".eventorg.ui.evntOrg_Package_detail" />
<activity android:name=".eventorg.ui.evntOrg_Package_create" />
<activity android:name=".eventorg.ui.evntOrg_emailVerification" />
<activity android:name=".eventorg.ui.evntOrg_friend_list" />
<activity android:name=".eventorg.ui.evntOrg_MessageDetail" />
<activity android:name=".eventorg.mapService" />
<activity android:name=".util.InternetBroadCastReceiver" />
<activity
android:name=".client.ui.client_home"
android:theme="@style/AppTheme.NoActionBar" />
<activity
android:name=".eventorg.ui.evntOrg_home"
android:label="@string/title_activity_evnt_org_home"
android:theme="@style/AppTheme.NoActionBar" />
<!--
The API key for Google Maps-based APIs is defined as a string resource.
(See the file "res/values/google_maps_api.xml").
Note that the API key is linked to the encryption key used to sign the APK.
You need a different API key for each encryption key, including the release key that is used to
sign the APK for publishing.
You can define the keys for the debug and release targets in src/debug/ and src/release/.
-->
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="@string/google_maps_key" />

<activity
android:name=".MapLocation"
android:label="Map" />
<activity
android:name=".eventorg.ui.evntOrg_signUp2"
android:label="Sign Up" />
<activity
android:name=".SplashActivity"
android:theme="@style/splashScreenStyle">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:label="EventSchedulingSystem" />
<activity
android:name=".eventorg.ui.evntOrg_signIn"
android:label="Sign In"
android:theme="@style/splashScreenStyle" />
<activity
android:name=".eventorg.ui.evntOrg_signUp"
android:label="Sign Up" />
<activity android:name=".client.ui.client_signIn" />
<activity android:name=".client.ui.client_signUp" />

<service android:name=".eventorg.mapService" />
</application>

</manifest>
任何帮助将不胜感激。谢谢

最佳答案

我收到此错误是因为我的 Firebase 依赖项的版本号不同。我通过更改版本号来修复此错误。

关于android - 序言中不能有内容。在构建我的 android 项目时出现此错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63750027/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com