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

Gradle plugin org.codehaus.groovy.runtime.GStringImpl cannot be cast to java.lang.String #690

Closed
SlyDen opened this Issue Feb 4, 2014 · 3 comments

Comments

Projects
None yet
2 participants
@SlyDen

SlyDen commented Feb 4, 2014

Just got exception java.lang.ClassCastException: org.codehaus.groovy.runtime.GStringImpl cannot be cast to java.lang.String with Gradle 1.10 and Flyway plugin (version 2.3).

Workaround from Gradle's issue tracker http://issues.gradle.org/browse/GRADLE-2566 works for me.

Situation:
I have some string property in gradle.properties file (in project's root)
Later I use it in build.gradle to configure flyway plugin, like:

placeholders = ['execUserName' : "${project.execUserName}"]

and it gives exception: java.lang.ClassCastException: org.codehaus.groovy.runtime.GStringImpl cannot be cast to java.lang.String

But

placeholders = ['execUserName' : "${project.execUserName}".toString()]

works like expected.

Not sure if it is Flyway plugin specific error or Gradle's (posted comment to http://issues.gradle.org/browse/GRADLE-2566 too)

May be relevant to #574

axelfontaine added a commit that referenced this issue Feb 12, 2014

@axelfontaine

This comment has been minimized.

Show comment
Hide comment
@axelfontaine

axelfontaine Feb 12, 2014

Contributor

Hi Denys,

thanks for reporting this. I tried to reproduce this, both with Gradle 1.7 and 1.11 and failed. Could you provide me with all definite series of steps to recreate this?

Cheers
Axel

Contributor

axelfontaine commented Feb 12, 2014

Hi Denys,

thanks for reporting this. I tried to reproduce this, both with Gradle 1.7 and 1.11 and failed. Could you provide me with all definite series of steps to recreate this?

Cheers
Axel

@axelfontaine

This comment has been minimized.

Show comment
Hide comment
@axelfontaine

axelfontaine Mar 1, 2014

Contributor

Any news?

Contributor

axelfontaine commented Mar 1, 2014

Any news?

@axelfontaine

This comment has been minimized.

Show comment
Hide comment
@axelfontaine

axelfontaine Apr 15, 2014

Contributor

Closing due to lack of reaction from original reporter

Contributor

axelfontaine commented Apr 15, 2014

Closing due to lack of reaction from original reporter

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