Could not generate a proxy class ContractVerifierExtension in Spring Cloud Contract - spring-cloud-contract

I'm following the basic setup under Gradle project. Getting this error:
* What went wrong:
An exception occurred applying plugin request [id: 'org.springframework.cloud.contract', version: '2.2.0.RELEASE']
> Failed to apply plugin [id 'org.springframework.cloud.contract']
> Could not generate a proxy class for class org.springframework.cloud.contract.verifier.plugin.ContractVerifierExtension.
Related stacktrace:
Caused by: java.lang.NoClassDefFoundError: org/gradle/api/provider/MapProperty
Is there some gradle version requirement? I am currently on Gradle 4.9. Or some other reason?

Your version of gradle is wrong. Please use the latest 5.x version.

Related

Flutter:The plugin firebase_auth could not be built due to the issue above

I just use firebase_auth package to send me code by phone Number. it work fine in debug mode but when I try to get apk it show me this error. can anyone help me please?
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':sms:verifyReleaseResources'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
> Android resource linking failed
C:\Users\Mohammad Asef\.gradle\caches\transforms-2\files-2.1\8014592fef965c457f4d96ed4583a915\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/fontVariationSettings not found.
C:\Users\Mohammad Asef\.gradle\caches\transforms-2\files-2.1\8014592fef965c457f4d96ed4583a915\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/ttcIndex not found.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 3m 52s
Running Gradle task 'assembleRelease'...
Running Gradle task 'assembleRelease'... Done 233.5s (!)
The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetfier to solve the
incompatibility.
Building plugin firebase_auth...
Running Gradle task 'assembleAarRelease'...
Running Gradle task 'assembleAarRelease'... Done 0.3s
Exception in thread "main" java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:225)
at java.util.zip.ZipFile.<init>(ZipFile.java:155)
at java.util.zip.ZipFile.<init>(ZipFile.java:169)
at org.gradle.wrapper.Install.unzip(Install.java:214)
at org.gradle.wrapper.Install.access$600(Install.java:27)
at org.gradle.wrapper.Install$1.call(Install.java:74)
at org.gradle.wrapper.Install$1.call(Install.java:48)
at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65)
at org.gradle.wrapper.Install.createDist(Install.java:48)
at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:128)
at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61)
The plugin firebase_auth could not be built due to the issue above.
firebase_auth is using AndroidX libraries, but your flutter project is still using the old android support library. To solve this upgrade to flutter latest version. From the docs:
How do I know if my project is using AndroidX?
Starting from Flutter v1.12.13, new projects created with flutter create -t <project-type> use AndroidX by default.
Projects created prior to this Flutter version must not depend on any old build artifact or old Support Library class.
In an app or module project, the file android/gradle.properties or .android/gradle.properties must contain:
android.useAndroidX=true
android.enableJetifier=true
https://flutter.dev/docs/development/androidx-migration
I solved it by adding firebase_analytics dependency in pubspec, then adding manually string value of default_notification_channel_id in android resource just like below
<string name="default_notification_channel_id" translatable="false">fcm_default_channel</string>

Firebase ML Kit

Trying to use Firebase ml kit for label but getting error below with version; firebase_ml_vision: ^0.9.10
Error
Launching lib\main.dart on sdk gphone x86 arm in debug mode...
lib\main.dart
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
> In project 'app' a resolved Google Play services library dependency depends on another at an exact version (e.g. "[19.0.
2]", but isn't being resolved to that version. Behavior exhibited by the library will be unknown.
Dependency failing: com.google.android.gms:play-services-vision:20.0.0 -> com.google.android.gms:play-services-vision-co
mmon#[19.0.2], but play-services-vision-common version was 19.1.0.
The following dependencies are project dependencies that are direct or have transitive dependencies that lead to the art
ifact with the issue.
-- Project 'app' depends onto com.google.firebase:firebase-ml-vision#{strictly 24.1.0}
-- Project 'app' depends on project 'firebase_ml_vision' which depends onto com.google.firebase:firebase-ml-vision#20.0.
0
-- Project 'app' depends onto com.google.android.gms:play-services-vision-common#{strictly 19.1.0}
-- Project 'app' depends onto com.google.firebase:firebase-bom#26.2.0
-- Project 'app' depends onto com.google.android.gms:play-services-vision-image-label#{strictly 18.0.4}
-- Project 'app' depends onto com.google.firebase:firebase-bom#{strictly 26.2.0}
-- Project 'app' depends onto com.google.android.gms:play-services-vision#{strictly 20.0.0}
For extended debugging info execute Gradle from the command line with ./gradlew --info :app:assembleDebug to see the dep
endency paths to the artifact. This error message came from the google-services Gradle plugin, report issues at https://
github.com/google/play-services-plugins and disable by adding "googleServices { disableVersionCheck = true }" to your bu
ild.gradle file.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BU�LD FAILED in 13s
Exception: Gradle task assembleDebug failed with exit code 1
Exited (sigterm)
After searching on github, somehow with edit below, app is running now, but when i try to use mlkit, getting error below
Edit 2
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation platform('com.google.firebase:firebase-bom:26.0.0')
implementation 'com.google.firebase:firebase-analytics'
implementation 'com.android.support:multidex:1.0.3'
api 'com.google.firebase:firebase-ml-vision-face-model:20.0.2'
implementation 'com.google.android.gms:play-services-vision:20.1.1'
implementation 'com.google.android.gms:play-services-vision-common:19.1.1'
implementation 'com.google.android.gms:play-services-vision-image-label:18.0.5'
implementation 'com.google.android.gms:play-services-vision-face-contour-internal:16.0.2'
}
Error in App
D/MediaScannerConnection( 8393): Scanned /storage/emulated/0/Android/data/com.example.temp_name/files/Pictures/e235923b-70f9-404a-aa0b-930333cceea96952909717190624838.jpg to null
I/flutter ( 8393): /storage/emulated/0/Android/data/com.example.temp_name/files/Pictures/scaled_e235923b-70f9-404a-aa0b-930333cceea96952909717190624838.jpg
W/DynamiteModule( 8393): Local module descriptor class for com.google.android.gms.vision.dynamite.ica not found.
I/DynamiteModule( 8393): Considering local module com.google.android.gms.vision.dynamite.ica:0 and remote module com.google.android.gms.vision.dynamite.ica:0
W/DynamiteModule( 8393): Local module descriptor class for com.google.android.gms.vision.ica not found.
I/DynamiteModule( 8393): Considering local module com.google.android.gms.vision.ica:0 and remote module com.google.android.gms.vision.ica:0
E/Vision ( 8393): Error loading optional module com.google.android.gms.vision.ica: com.google.android.gms.dynamite.DynamiteModule$LoadingException: No acceptable module found. Local version is 0 and remote version is 0.
W/LabelerNativeHandle( 8393): Native handle not yet available. Reverting to no-op handle.
Since you're including firebase-bom:26.2.0, that determines the versions of all Firebase SDKs you use. So remove the version numbers from all other Firebase SDK dependencies in your build.gradle to get rid of the version conflict.

sbt lagom template+InvalidRemoteException

I tried to follow the follow tutorial:
https://www.lagomframework.com/documentation/1.4.x/java/GettingStartedSbt.html
For generating the project scaffolding, I want to use the following template:
sbt new lagom/lagom-java.g8
But already receive the following error:
[error] org.eclipse.jgit.api.errors.InvalidRemoteException: Invalid remote: origin
A bit frustrating at such early stage in the tutorial...
Any idea how to fix this?
Edit: the error is caused by:
[error] Caused by: org.eclipse.jgit.errors.NoRemoteRepositoryException: https//github.com/lagom/lagom-java.g8.git: not found.
Seems there is a :missing after https. How to fix?
Verify you have the prerequisites. Prerequisites documented here https://www.lagomframework.com/documentation/1.4.x/java/JavaPrereqs.html
I just followed the instructions and was unable to reproduce the error from the CLI using sbt version 1.1.1.
What version of sbt are you using?

Karaf 3.0.3 add system.properties --> karaf.lock.level, leads to java.lang.RuntimeException

When i add to apache-karaf-3.0.3\etc\system.properties the property karaf.lock.level=50
the following exception is thrown:
java.lang.RuntimeException: Error installing bundle listed in startup.properties with url: mvn:org.ops4j.pax.url/pax-url-aether/2.3.0 and startlevel: 5
at org.apache.karaf.main.Main.installAndStartBundles(Main.java:392)
at org.apache.karaf.main.Main.launch(Main.java:245)
at org.apache.karaf.main.Main.main(Main.java:167)
Caused by: org.osgi.framework.BundleException: Unresolved constraint in bundle org.ops4j.pax.url.mvn [1]: Unable to resolve 1.0: missing requirement [1.0] osgi.wiring.package; (&(osgi.wiring.package=org.slf4j)(version>=1.6.0)(!(version>=2.0.0)))
at org.apache.felix.framework.Felix.resolveBundleRevision(Felix.java:3974)
at org.apache.felix.framework.Felix.startBundle(Felix.java:2037)
at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:955)
at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:942)
at org.apache.karaf.main.Main.installAndStartBundles(Main.java:389)
... 2 more
same result when configuring the failover mechanism as described in the documentation. http://karaf.apache.org/manual/latest/users-guide/failover.html
karaf.lock=true
karaf.lock.class=org.apache.karaf.main.lock.DefaultJDBCLock
karaf.lock.level=50
karaf.lock.delay=10
karaf.lock.jdbc.url=jdbc:mysql://localhost/something
karaf.lock.jdbc.driver=com.mysql.jdbc.Driver
karaf.lock.jdbc.user=aUser
karaf.lock.jdbc.password=aUnsecurePassword
karaf.lock.jdbc.table=KARAF_LOCK
karaf.lock.jdbc.clustername=karaf
karaf.lock.jdbc.timeout=30
the driver is dropped to apache-karaf-3.0.3\lib\ext
when karaf.lock.level is removed or set to greater than 0 and lower than 5 it seems to work.
when i set the same lock.level.property to 50 in a 2.3.3 installation of karaf everything seems to work just fine.
does anyone know what changed there from 3.x.x to 2.3.3 or what could cause the problem.
best regards and thank you for your time :D

Getting error while deploying WAR file

I am getting below error while deploying war file .Here JDK version on development machine and deployment machines is same then also i am getting this error.
[05/Jun/2013:11:20:42] failure ( 5712): WebModule[/cover]: WEB2671: Error configuring application listener of class com.bt.cover.ContextListener
java.lang.UnsupportedClassVersionError: com/bt/cover/ContextListener (Unsupported major.minor version 49.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1717)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:983)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1431)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1301)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3349)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:3743)
at com.iplanet.ias.web.WebModule.start(WebModule.java:251)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1133)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:652)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1133)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:355)
at org.apache.catalina.startup.Embedded.start(Embedded.java:995)
at com.iplanet.ias.web.WebContainer.start(WebContainer.java:431)
at com.iplanet.ias.web.WebContainer.startInstance(WebContainer.java:500)
at com.iplanet.ias.server.J2EERunner.confPostInit(J2EERunner.java:161)
Based on this answer: Unsupported major.minor version 49.0, it looks like you may be running on a different JVM from what you used to compile your code. Hope this helps.

Resources