lubritto / pdf_viewer_plugin

A Flutter plugin for IOS and Android providing a simple way to display PDFs.
MIT License
57 stars 65 forks source link

Cannot set the value of read-only property 'force ' for DefaultExternalModuleDependency #54

Open Kazi-Wahed opened 11 months ago

Kazi-Wahed commented 11 months ago

implementation('com.github.barteksc:android-pdf-viewer:3.0.0-beta.4') { force = true }

A problem occurred evaluating project ':pdf_viewer_plugin'.

Cannot set the value of read-only property 'force' for DefaultExternalModuleDependency{group='com.github.barteksc', name='android-pdf-viewer', version='3.0.0-beta.4', configuration='default'} of type org.gradle.api.internal.artifacts.dependencies.DefaultExternalModuleDependency.

gabrielaraujoz commented 5 months ago

@lubritto hey there! Is there any chance we could solve this issue? If you're willing to merge the PR, I could make this update for you. Let me know <3

johnyen220 commented 4 months ago

Does it solved ? And new version released? Thank a lot!

Tolulope05 commented 2 months ago

No update on this? cc @johnyen220 @gabrielaraujoz @Kazi-Wahed @chrismills @lubritto

Tolulope05 commented 2 months ago

Launching lib\main.dart on SM A205F in debug mode...

FAILURE: Build failed with an exception.

BUILD FAILED in 8s Error: Gradle task assembleDebug failed with exit code 1

Tolulope05 commented 2 months ago

Below is the build.gradle:

group 'dev.britto.pdf_viewer_plugin' version '1.0'

buildscript { repositories { google() jcenter() }

dependencies {
    classpath 'com.android.tools.build:gradle:4.1.0'
}

}

rootProject.allprojects { repositories { google() jcenter() } }

apply plugin: 'com.android.library'

android { compileSdkVersion 30

defaultConfig {
    minSdkVersion 16
    testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
lintOptions {
    disable 'InvalidPackage'
}

}

dependencies { implementation 'androidx.appcompat:appcompat:1.2.0' implementation('com.github.barteksc:android-pdf-viewer:3.0.0-beta.4') { force = true } }

pscire commented 1 month ago

Same problem here:

A problem occurred evaluating project ':pdf_viewer_plugin'.
> Cannot set the value of read-only property 'force' for DefaultExternalModuleDependency{group='com.github.barteksc', name='android-pdf-viewer', version='3.0.0-beta.4', configuration='default'} of type org.gradle.api.internal.artifacts.dependencies.DefaultExternalModuleDependency.

by commenting the force = true end up to:

Could not resolve com.github.barteksc:android-pdf-viewer:3.0.0-beta.4.
         > Could not get resource 'https://www.jitpack.io/com/github/barteksc/android-pdf-viewer/3.0.0-beta.4/android-pdf-viewer-3.0.0-beta.4.pom'.
            > Could not GET 'https://www.jitpack.io/com/github/barteksc/android-pdf-viewer/3.0.0-beta.4/android-pdf-viewer-3.0.0-beta.4.pom'. Received status code 401 from server: Unauthorized