Mapbox Navigation SDK version:
Steps to trigger behavior
1.Clone the Mapbox Android Navigation . 2.Add Username and Access Token key in project gradle propoerties 3.Add Authentication in project modue gradle file
Expected behavior Project should sync and when run app should run in device
Actual behavior Facing debug compile errors:-
ERROR: Unable to resolve dependency for ':carbon@debug/compileClasspath': Could not resolve com.mapbox.maps:android:10.0.0-alpha.5. Show Details Affected Modules: carbon Project Gradle Code:- >apply plugin: 'com.github.kt3k.coveralls' apply plugin: 'jacoco' buildscript { apply from: "${rootDir}/gradle/dependencies.gradle" repositories { google() mavenCentral() jcenter() maven { url 'https://plugins.gradle.org/m2' } maven { url 'https://maven.fabric.io/public' } } dependencies { classpath pluginDependencies.gradle classpath pluginDependencies.kotlin classpath pluginDependencies.coveralls classpath pluginDependencies.errorprone classpath pluginDependencies.dependencyUpdates classpath pluginDependencies.jacoco classpath pluginDependencies.playPublisher classpath pluginDependencies.googleServices classpath pluginDependencies.crashlytics classpath pluginDependencies.license classpath pluginDependencies.mapboxSdkVersions classpath pluginDependencies.mavenPublish classpath pluginDependencies.bintray classpath pluginDependencies.artifactory classpath pluginDependencies.dokka } } task testReport(type: TestReport, group: 'Build') { description = 'Generates an aggregate test report' destinationDir = file("${buildDir}/reports/allTests") } allprojects { repositories { maven { url 'https://api.mapbox.com/downloads/v1/navigation/android/maven' authentication { basic(BasicAuthentication) } credentials { username = project.properties['username'] ?: "" password = project.properties['access_token'] ?: "" } } google() mavenCentral() jcenter() maven { url 'https://plugins.gradle.org/m2' } // maven { // url 'https://api.mapbox.com/downloads/v2/releases/maven' // authentication { // basic(BasicAuthentication) // } // credentials { // username = "mapbox" // password = project.hasProperty('SDK_REGISTRY_TOKEN') ? project.property('SDK_REGISTRY_TOKEN') : System.getenv('SDK_REGISTRY_TOKEN') // } // } maven { url 'https://mapbox.bintray.com/mapbox_internal' credentials { username = project.hasProperty('BINTRAY_USER') ? project.property('BINTRAY_USER') : System.getenv('BINTRAY_USER') password = project.hasProperty('BINTRAY_API_KEY') ? project.property('BINTRAY_API_KEY') : System.getenv('BINTRAY_API_KEY') } } maven { url 'https://mapbox.bintray.com/mapbox_collab' credentials { username = project.hasProperty('BINTRAY_USER') ? project.property('BINTRAY_USER') : System.getenv('BINTRAY_USER') password = project.hasProperty('BINTRAY_API_KEY') ? project.property('BINTRAY_API_KEY') : System.getenv('BINTRAY_API_KEY') } } maven { url 'https://mapbox.bintray.com/mapbox_private' credentials { username = project.hasProperty('BINTRAY_USER') ? project.property('BINTRAY_USER') : System.getenv('BINTRAY_USER') password = project.hasProperty('BINTRAY_API_KEY') ? project.property('BINTRAY_API_KEY') : System.getenv('BINTRAY_API_KEY') } } maven { url 'https://mapbox.bintray.com/mapbox' } maven { url 'https://oss.jfrog.org/artifactory/oss-snapshot-local/' } } group = GROUP version = VERSION_NAME } subprojects { apply plugin: 'idea' apply plugin: 'net.ltgt.errorprone' apply from: "${rootDir}/gradle/dependencies.gradle" dependencies { errorprone dependenciesList.errorprone } plugins.withId('org.jetbrains.kotlin.jvm') { compileKotlin { kotlinOptions { jvmTarget = "1.8" } } } }
Project Module Code
apply plugin: 'com.android.application' apply plugin: 'kotlin-android' apply plugin: 'kotlin-android-extensions' apply plugin: 'com.github.triplet.play' apply from: "${rootDir}/gradle/script-git-version.gradle" apply from: "${rootDir}/gradle/ktlint.gradle" android { compileSdkVersion androidVersions.compileSdkVersion compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } playConfigs { defaultAccountConfig { serviceAccountCredentials = file("$project.rootDir/android-gl-native- 15d95ab30d0f.json") } } def getGitHash = { -> try { def stdout = new ByteArrayOutputStream() exec { commandLine 'git', 'rev-parse', '--short', 'HEAD' standardOutput = stdout } return stdout.toString().trim() } catch (Exception exception) { return "" } } defaultConfig { applicationId "com.mapbox.services.android.navigation.app" `enter code here`minSdkVersion androidVersions.minSdkVersion targetSdkVersion androidVersions.targetSdkVersion multiDexEnabled true versionCode gitVersionCode versionName gitVersionName testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" vectorDrawables.useSupportLibrary = true buildConfigField "String", "GIT_HASH", "\"${getGitHash()}\"" } signingConfigs { release { keyAlias System.getenv("CIRCLECI_ANDROID_KEYSTORE_ALIAS") keyPassword System.getenv("CIRCLECI_ANDROID_KEYSTORE_PRIVATE_KEY_PASSWORD") storeFile file("$project.rootDir/navigation_testapp.keystore") storePassword System.getenv("CIRCLECI_ANDROID_KEYSTORE_PASSWORD") } } buildTypes { debug { testCoverageEnabled = false manifestPlaceholders = [enableCrashReporting:"false"] } release { minifyEnabled true signingConfig signingConfigs.release manifestPlaceholders = [enableCrashReporting:"true"] } } dexOptions { maxProcessCount 8 javaMaxHeapSize "2g" preDexLibraries true } lintOptions { abortOnError false } play { serviceAccountCredentials = playConfigs.defaultAccountConfig.serviceAccountCredentials track = System.getenv("GOOGLE_PLAY_TRACK") ?: "internal" } } dependencies { //ktlint ktlint dependenciesList.ktlint // Kotlin support implementation dependenciesList.kotlinStdLib implementation dependenciesList.ankoCommon // implementation 'com.mapbox.navigation:core:1.0.0-rc.2' // Mapbox Navigation SDK implementation project(':libandroid-navigation-ui') implementation dependenciesList.mapboxMapSdk implementation dependenciesList.mapboxSearchSdk implementation dependenciesList.mapboxCrashMonitor // Support libraries implementation dependenciesList.androidXAppCompat implementation dependenciesList.materialDesign implementation dependenciesList.androidXRecyclerView implementation dependenciesList.androidXConstraintLayout implementation dependenciesList.androidXCardView implementation dependenciesList.lifecycleExtensions implementation dependenciesList.gmsLocation implementation dependenciesList.firebaseCore implementation dependenciesList.crashlytics implementation dependenciesList.multidex // Logging implementation dependenciesList.timber // Network implementation(dependenciesList.okhttp) { force = true } implementation(dependenciesList.okhttpInterceptor) { force = true } // Butter Knife implementation dependenciesList.butterKnife annotationProcessor dependenciesList.butterKnifeProcessor // Leak Canary debugImplementation dependenciesList.leakCanaryDebug // Unit Testing testImplementation dependenciesList.junit testImplementation dependenciesList.mockito testImplementation dependenciesList.mockk // Instrumentation testing androidTestImplementation dependenciesList.testRules androidTestImplementation(dependenciesList.testEspressoCore, { exclude group: 'com.android.support', module: 'support-annotations' }) androidTestImplementation dependenciesList.testEspressoContrib } apply from: "${rootDir}/gradle/developer-config.gradle" apply from: "${rootDir}/gradle/checkstyle.gradle" apply from: "${rootDir}/gradle/dependency-updates.gradle" Projrct gradle.properties Code:- > VERSION_NAME=0.43.0-SNAPSHOT GROUP=com.mapbox.mapboxsdk POM_URL=https://github.com/mapbox/mapbox-navigation-android POM_SCM_URL=https://github.com/mapbox/mapbox-navigation-android POM_SCM_CONNECTION=scm:git@github.com:mapbox/mapbox-navigation-android.git POM_SCM_DEV_CONNECTION=scm:git@github.com:mapbox/mapbox-navigation-android.git POM_LICENCE_NAME=The MIT License POM_LICENCE_URL=https://opensource.org/licenses/MIT POM_LICENCE_DIST=repo POM_DEVELOPER_ID=mapbox POM_DEVELOPER_NAME=Mapbox POM_UI_SNAPSHOT_VERSION_NAME=1.0.0-SNAPSHOT POM_CORE_SNAPSHOT_VERSION_NAME=1.0.0-SNAPSHOT MAPBOX_USERNAME=harshit999 MAPBOX_DOWNLOADS_TOKEN="sktoken here"
Asked
Active
Viewed 462 times
2

Boken
- 4,825
- 10
- 32
- 42

karanveer singh
- 21
- 2