bumptech / glide

An image loading and caching library for Android focused on smooth scrolling
https://bumptech.github.io/glide/
Other
34.58k stars 6.12k forks source link

Failed to resolve: fragment-1.0.0 and Failed to resolve: vectordrawable-animated-1.0.0 #4392

Open Stevemoretz opened 3 years ago

Stevemoretz commented 3 years ago

Hi while gradle sync I get:

Failed to resolve: fragment-1.0.0
Affected Modules: expo-image-loader

and

Failed to resolve: vectordrawable-animated-1.0.0
Affected Modules: expo-image-loader

With removing glide from expo-image-loader the errors go aways.

Glide Version:

  implementation 'com.github.bumptech.glide:glide:4.9.0'
  annotationProcessor 'androidx.annotation:annotation:1.1.0'
  annotationProcessor 'com.github.bumptech.glide:compiler:4.9.0'

Integration libraries: OkHttp3

gradle top level :

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    ext {
        buildToolsVersion = "29.0.2"
        minSdkVersion = 16
        compileSdkVersion = 29
        targetSdkVersion = 29

        androidXCore = "1.0.2"
    }
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath("com.android.tools.build:gradle:4.0.2")
//        classpath("com.android.tools.build:gradle:3.5.3")
        classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.0")
        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 {
        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")
        }

        maven {
            url 'https://plugins.gradle.org/m2/'
        }

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

gradle for the module which is using glide 4.9.0

apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'maven'

buildscript {
  // Simple helper that allows the root project to override versions declared by this library.
  ext.safeExtGet = { prop, fallback ->
    rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
  }

  repositories {
    mavenCentral()
  }

  dependencies {
    classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${safeExtGet("kotlinVersion", "1.3.50")}")
  }
}

group = 'host.exp.exponent'
version = '1.2.0'

// Upload android library to maven with javadoc and android sources
configurations {
  deployerJars
}

// Creating sources with comments
task androidSourcesJar(type: Jar) {
  classifier = 'sources'
  from android.sourceSets.main.java.srcDirs
}

// Put the androidSources and javadoc to the artifacts
artifacts {
  archives androidSourcesJar
}

uploadArchives {
  repositories {
    mavenDeployer {
      configuration = configurations.deployerJars
      repository(url: mavenLocal().url)
    }
  }
}

android {
  compileSdkVersion safeExtGet("compileSdkVersion", 29)

  defaultConfig {
    minSdkVersion safeExtGet("minSdkVersion", 21)
    targetSdkVersion safeExtGet("targetSdkVersion", 29)
    versionCode 6
    versionName "1.2.0"
  }
  lintOptions {
    abortOnError false
  }
  compileOptions {
    sourceCompatibility = '1.8'
    targetCompatibility = '1.8'
  }
}

repositories {
  mavenCentral()
}

if (new File(rootProject.projectDir.parentFile, 'package.json').exists()) {
  apply from: project(":unimodules-core").file("../unimodules-core.gradle")
} else {
  throw new GradleException(
      '\'unimodules-core.gradle\' was not found in the usual Flutter or React Native dependency locations. ' +
          'This package can only be used in such projects. Are you sure you\'ve installed the dependencies properly?')
}

dependencies {
  unimodule 'unimodules-core'
  unimodule 'unimodules-image-loader-interface'

  api "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${safeExtGet('kotlinVersion', '1.3.50')}"
  implementation 'com.github.bumptech.glide:glide:4.9.0'
  annotationProcessor 'androidx.annotation:annotation:1.1.0'
  annotationProcessor 'com.github.bumptech.glide:compiler:4.9.0'
  api 'com.facebook.fresco:fresco:2.0.0'
}
Stevemoretz commented 3 years ago

Using : android.enableJetifier=false

Works but if I set it to true it fails.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had activity in the last seven days. It will be closed if no further activity occurs within the next seven days. Thank you for your contributions.