Skip to content

Could not determine the dependencies of null #777

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
theobouwman opened this issue Feb 25, 2025 · 6 comments
Open

Could not determine the dependencies of null #777

theobouwman opened this issue Feb 25, 2025 · 6 comments

Comments

@theobouwman
Copy link

Works perfectly with iOS but on android I cant build anymore, is this a common issue?

    "react-native": "0.70.14",
     "@react-native-documents/picker": "^10.1.0",
    "@react-native-documents/viewer": "^1.0.0",
A problem occurred configuring project ':react-native-documents_picker'.
> Could not determine the dependencies of null.
   > Could not resolve all task dependencies for configuration ':react-native-documents_picker:classpath'.
      > Could not find org.jetbrains.kotlin:kotlin-gradle-plugin:null.
        Searched in the following locations:
          - https://dl.google.com/dl/android/maven2/org/jetbrains/kotlin/kotlin-gradle-plugin/null/kotlin-gradle-plugin-null.pom
          - https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-gradle-plugin/null/kotlin-gradle-plugin-null.pom
        Required by:
            project :react-native-documents_picker

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html


@sahilthite
Copy link

Facing same issue when trying to add @react-native-documents/picker and @react-native-documents/viewer

Currently working on react native 0.76.0

@theobouwman
Copy link
Author

I had to specify the kotlinVersion in the build file

@sahilthite
Copy link

sahilthite commented Feb 25, 2025

What is the current kotlinVersion you're using?

Did it worked after changing?

@theobouwman
Copy link
Author

kotlinVersion = "1.8.0"
and add it later as well:

    repositories {
        google()
        mavenCentral()
    }
    dependencies {
        classpath("com.android.tools.build:gradle:7.2.1")
        classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion")

        classpath("com.facebook.react:react-native-gradle-plugin")
        classpath("de.undercouch:gradle-download-task:5.0.1")

@abburiv
Copy link

abburiv commented Mar 11, 2025

We faced the same issue, this package trying to read the "kotlinVersion", in our case we named the config as "kotlin_version". Renaming the prop in android/build.gradle did the fix.

@oleksandr-dziuban
Copy link

lib should have a default version fallback for kotlinVersion if not specified in root app.

It shouldn't rely just to kotlinVersion definition in app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants