-
Notifications
You must be signed in to change notification settings - Fork 255
Open
Labels
Keep Openthis label avoids the stale botthis label avoids the stale bot
Description
Description
Build fails when locking gradle dependencies.
Note
this started happening after upgrading to "react-native": "0.74.3",
where Gradle was upgraded to version 8.
Error Message
> Could not resolve all artifacts for configuration ':app:developmentDebugRuntimeClasspath'.
> Could not resolve app.notifee:core:+.
Required by:
project :app > project :notifee_react-native
> Failed to list versions for app.notifee:core.
> Unable to load Maven meta-data from file:/Users/jadjbara/projects/......./node_modules/@notifee/react-native/android/libs/app/notifee/core/maven-metadata.xml.
> org.xml.sax.SAXNotRecognizedException: Property 'http://javax.xml.XMLConstants/property/accessExternalSchema' is not recognized.
Project Specifics
- react-native version: 0.74.3
- notifee version: 7.8.2
Steps to Reproduce
- Enable gradle dependencies locking
You can follow the guide on the official Gradle docs
Steps are below:
Add the following to your rootandroid/build.gradle
directory.
subprojects {
configurations.all {
it.resolutionStrategy.activateDependencyLocking()
}
}
dependencyLocking {
lockAllConfigurations()
}
- Build the app with adding
--write-locks
to the command for example in our case we are running./android/gradlew -p ./android androidDependencies --write-locks
R&D
According to Gradle, depending on version 8 will lead to builds failing in case a dependency still uses legacy xml parsers.
How to Bypass the Error
The only way I could actually bypass the error was by disabling dependency locking in the project, which is not ideal since we would like to keep this in our repo.
Any idea how this can be resolved? Thanks!
mujehoxe
Metadata
Metadata
Assignees
Labels
Keep Openthis label avoids the stale botthis label avoids the stale bot