You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by Prez Cannady <re...@opencorrelate.org> on 2016/01/16 21:09:16 UTC

Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Attempting to get settled with Flink under Scala 2.11, but running into some odd issues with macro expansion in a project that depends on flink-scala_2.11 and flink-runtime_211. 

I’ve instrumented the SocketStreamWordCount quick start <https://github.com/OCExercise/wordcount-processing> to test this issue. It depends on Flink 1.0-SNAPSHOT, so you can test against a local build of Flink for 2.11.

Steps taken

Cloned source and checked out release-0.1
Ran tools/change-scala-version.sh 2.11
Ran mvn clean install -Dscala.version=2.11.4 -Dscala.binary.version=2.11 -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
Ran my spring-booted downstream project’s build and boot run.
Expected result

Success

Actual result

During compilation, I get the following error:

[ERROR] /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73: error: could not find implicit value for evidence parameter of type org.apache.flink.api.common.typeinfo.TypeInformation[String]
[ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+") filter { _.nonEmpty } }
[ERROR]                                   ^
[ERROR] /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40: error: can't expand macros compiled by previous versions of Scala
[ERROR]     val text = env.fromElements("To be, or not to be,--that is the question:--",


Discussion

I’m not sure how the Maven build actually succeeded, as there doesn’t seem to be any quasiquotes_2.11 under org.scalamacros <http://central.maven.org/maven2/org/scalamacros/> of any version in the public repos, nor in the four vendor repos configured in flink-parent’s pom.xml. Unless I’m missing something, 

            <dependencies>
                <dependency>
                    <groupId>org.scalamacros</groupId>
                    <artifactId>quasiquotes_${scala.binary.version}</artifactId>
                    <version>${scala.macros.version}</version>
                </dependency>
            </dependencies>


I recall an earlier discussion about issues with 2.10 stuff polluting the 2.11 build. Not sure if this is related–I’m able to get through everything I’ve identified up to this point by simply overriding properties in flunk-parent with command line arguments. 

Also not sure what next steps to take. Don’t know enough about Scala Macros to know if substituting, say, org.scalameta:quasiquotes_2.11:0.0.4 is a viable option (actually tried it, seems to be more trouble than it’s worth). 

If anyone has any ideas, I’m more than willing to try thing—Flink’s on our critical path and if we can get it operational under 2.11 then we’er golden.



Prez Cannady  
p: 617 500 3378  
e: revprez@opencorrelate.org <ma...@opencorrelate.org>  
GH: https://github.com/opencorrelate <https://github.com/opencorrelate>  
LI: https://www.linkedin.com/in/revprez <https://www.linkedin.com/in/revprez>  










Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Prez Cannady <re...@correlatesystems.com>.
Finally got a chance to sit down and run through a few tests. Upfront, I have been able to resolve my issue sufficiently to move forward, but seems there’s an issue with the current bits for both 1.0-SNAPSHOT and 0.10-SNAPSHOT in the remote Maven repos.

Notes

wordcount-processing <https://github.com/OCExercise/wordcount-processing> is a customized version of the Flink quickstart archetype I’m using to test Flink integration with Spring Boot. It is instrumented for Maven and Gradle build and execution.
I’m targeting Scala 2.11 and Flink 0.10.
0.10-SNAPSHOT source build

Steps

Checked out release–0.10 branch (snapshot version 0.10-SNAPSHOT).
Built with mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true -Dscala.version=2.11.7 -Dscala.binary.version=2.11.
Ran wordcount-process with mvn clean spring-boot:run -Drun.arguments=“localhost,9999”.
Ran wordcount-process with gradle bootRun -Drun.arguments=“localhost 9999”.
Result

Maven execution of test succeeds without incident.
Gradle execution of test succeeds without incident.
0.10-SNAPSHOT with fetched binary dependencies

Steps

Cleaned out local maven repository with rm -rf $HOME/.m2/repo/org/apache/flink && rm -rf $HOME/.m2/repo/org/scala*.
Cleaned out local gradle repository with rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.apache.flink && rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.scala*.
Ran wordcount-process with mvn clean spring-boot:run -Drun.arguments=“localhost,9999”.
Ran wordcount-process with gradle bootRun -Drun.arguments=“localhost 9999”.
Result

Maven build completed without incident. Maven execution error’d out with issue supposedly resolved with pull request 1511 <https://github.com/apache/flink/pull/1511>.
Gradle execution of test succeeds without incident.
1.0-SNAPSHOT source build

Steps

Cleaned out local maven repository with rm -rf $HOME/.m2/repo/org/apache/flink && rm -rf $HOME/.m2/repo/org/scala*.
Cleaned out local gradle repository with rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.apache.flink && rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.scala*.
Checked out release–0.10 branch (snapshot version 0.10-SNAPSHOT).
Built with mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true -Dscala.version=2.11.7 -Dscala.binary.version=2.11.
Ran wordcount-process with mvn clean spring-boot:run -Drun.arguments=“localhost,9999”.
Ran wordcount-process with gradle bootRun -Drun.arguments=“localhost 9999”.
Result

Maven build completed without incident. Maven execution error’d out with issue supposedly resolved with pull request 1511 <https://github.com/apache/flink/pull/1511>.
Gradle execution of test succeeds without incident.
1.0-SNAPSHOT with fetched binary dependencies

Steps

Cleaned out local maven repository with rm -rf $HOME/.m2/repo/org/apache/flink && rm -rf $HOME/.m2/repo/org/scala*.
Cleaned out local gradle repository with rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.apache.flink && rm -rf $HOME/.gradle/caches/modules-2/files-2.1/org.scala*.
Ran wordcount-process with mvn clean spring-boot:run -Drun.arguments=“localhost,9999”.
Ran wordcount-process with gradle bootRun -Drun.arguments=“localhost 9999”.
Result

Maven build error’d out with
could not find implicit value for evidence parameter of type org.apache.flink.api.common.typeinfo.TypeInformation[String], and
can't expand macros compiled by previous versions of Scala[ERROR] val text = env.fromElements("To be, or not to be,--that is the question:—“.
(Gist <https://gist.github.com/revprez/c70a6f3976b091413c8c>).
Gradle build error’d out with java.lang.NoClassDefFoundError: scala/reflect/macros/Context (gist <https://gist.github.com/revprez/298a0302711908975add>).
Discussion

As it stands, I can move forward with building 0.10-SNAPSHOT from source for my own purposes.
I’m guessing pull request 1511 <https://github.com/apache/flink/pull/1511> hasn’t made it into the the upstream snapshot repos yet.
I’m not sure as to why 1.0-SNAPSHOT is suffering from a macros incident and not 0.10-SNAPSHOT. Both are bringing in dependencies (quasiquotes, scala-library, scala-reflect, and a bunch of akka-* stuff) compiled for 2.10, but 0.10-SNAPSHOT does not invite the macro-related errors some of us have seen when building against 1.0-SNAPSHOT dependencies.

Prez Cannady  
p: 617 500 3378  
e: revprez@opencorrelate.org <ma...@opencorrelate.org>  
GH: https://github.com/opencorrelate <https://github.com/opencorrelate>  
LI: https://www.linkedin.com/in/revprez <https://www.linkedin.com/in/revprez>  









> On Jan 18, 2016, at 3:57 AM, Till Rohrmann <tr...@apache.org> wrote:
> 
> This might be related to the problem mentioned in
> https://issues.apache.org/jira/browse/FLINK-3241 and
> http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/flink-1-0-SNAPSHOT-scala-2-11-compilation-error-td4303.html
> .
> 
> Cheers,
> Till
> 
> On Sun, Jan 17, 2016 at 6:26 PM, Prez Cannady <re...@correlatesystems.com>
> wrote:
> 
>> I concur.  Already had "import org.apache.flink.streaming.api.scala._”,
>> and just tried adding "import org.apache.flink.api.scala._”.  Same issue.
>> 
>> 
>> 
>> Prez Cannady
>> p: 617 500 3378
>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
>> LI: https://www.linkedin.com/in/revprez <
>> https://www.linkedin.com/in/revprez>
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>> On Jan 17, 2016, at 8:59 AM, Aljoscha Krettek <al...@apache.org>
>> wrote:
>>> 
>>> Hi,
>>> I think it’s more complicated than a missing import statement (the code
>> has the correct import statement). I’ll look into it.
>>> 
>>> Cheers,
>>> Aljoscha
>>>> On 17 Jan 2016, at 13:32, Stephan Ewen <se...@apache.org> wrote:
>>>> 
>>>> Hi!
>>>> 
>>>> I think this no Scala version issue, you probably miss an import
>> statement:
>>>> 
>>>> "import org.apache.flink.streaming.api.scala._" or "import
>>>> org.apache.flink.api.scala._"
>>>> 
>>>> See also here:
>>>> 
>> http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters
>>>> 
>>>> Greetings,
>>>> Stephan
>>>> 
>>>> On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <
>> revprez@opencorrelate.org>
>>>> wrote:
>>>> 
>>>>> Attempting to get settled with Flink under Scala 2.11, but running into
>>>>> some odd issues with macro expansion in a project that depends on
>>>>> flink-scala_2.11 and flink-runtime_211.
>>>>> 
>>>>> I’ve instrumented the SocketStreamWordCount quick start <
>>>>> https://github.com/OCExercise/wordcount-processing> to test this
>> issue.
>>>>> It depends on Flink 1.0-SNAPSHOT, so you can test against a local
>> build of
>>>>> Flink for 2.11.
>>>>> 
>>>>> Steps taken
>>>>> 
>>>>> Cloned source and checked out release-0.1
>>>>> Ran tools/change-scala-version.sh 2.11
>>>>> Ran mvn clean install -Dscala.version=2.11.4
>> -Dscala.binary.version=2.11
>>>>> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
>>>>> Ran my spring-booted downstream project’s build and boot run.
>>>>> Expected result
>>>>> 
>>>>> Success
>>>>> 
>>>>> Actual result
>>>>> 
>>>>> During compilation, I get the following error:
>>>>> 
>>>>> [ERROR]
>>>>> 
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
>>>>> error: could not find implicit value for evidence parameter of type
>>>>> org.apache.flink.api.common.typeinfo.TypeInformation[String]
>>>>> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
>>>>> filter { _.nonEmpty } }
>>>>> [ERROR]                                   ^
>>>>> [ERROR]
>>>>> 
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
>>>>> error: can't expand macros compiled by previous versions of Scala
>>>>> [ERROR]     val text = env.fromElements("To be, or not to be,--that is
>> the
>>>>> question:--",
>>>>> 
>>>>> 
>>>>> Discussion
>>>>> 
>>>>> I’m not sure how the Maven build actually succeeded, as there doesn’t
>> seem
>>>>> to be any quasiquotes_2.11 under org.scalamacros <
>>>>> http://central.maven.org/maven2/org/scalamacros/> of any version in
>> the
>>>>> public repos, nor in the four vendor repos configured in flink-parent’s
>>>>> pom.xml. Unless I’m missing something,
>>>>> 
>>>>>          <dependencies>
>>>>>              <dependency>
>>>>>                  <groupId>org.scalamacros</groupId>
>>>>> 
>>>>> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
>>>>>                  <version>${scala.macros.version}</version>
>>>>>              </dependency>
>>>>>          </dependencies>
>>>>> 
>>>>> 
>>>>> I recall an earlier discussion about issues with 2.10 stuff polluting
>> the
>>>>> 2.11 build. Not sure if this is related–I’m able to get through
>> everything
>>>>> I’ve identified up to this point by simply overriding properties in
>>>>> flunk-parent with command line arguments.
>>>>> 
>>>>> Also not sure what next steps to take. Don’t know enough about Scala
>>>>> Macros to know if substituting, say,
>> org.scalameta:quasiquotes_2.11:0.0.4
>>>>> is a viable option (actually tried it, seems to be more trouble than
>> it’s
>>>>> worth).
>>>>> 
>>>>> If anyone has any ideas, I’m more than willing to try thing—Flink’s on
>> our
>>>>> critical path and if we can get it operational under 2.11 then we’er
>> golden.
>>>>> 
>>>>> 
>>>>> 
>>>>> Prez Cannady
>>>>> p: 617 500 3378
>>>>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>>>>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate
>>> 
>>>>> LI: https://www.linkedin.com/in/revprez <
>>>>> https://www.linkedin.com/in/revprez>
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>> 
>> 
>> 


Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Prez Cannady <re...@correlatesystems.com>.
I agree, but it also may be more than a simple project structure and dependency problems

Flink currently has six files that import `scala.reflect.macros.Context`.  With 2.11, Scala has deprecated this import in favor of `scala.reflect.macros.blackbox.Context` and `scala.reflect.macros.whitebox.Context`.  

http://docs.scala-lang.org/overviews/macros/changelog211.html <http://docs.scala-lang.org/overviews/macros/changelog211.html>
http://docs.scala-lang.org/overviews/macros/blackbox-whitebox.html <http://docs.scala-lang.org/overviews/macros/blackbox-whitebox.html>


I’m still getting my head wrapped around macros in the first place, but I’ve at instrumented a gradle build in my take on the canonical Flink quickstart to illustrate the issue.  

https://github.com/OCExercise/wordcount-processing/blob/master/build.gradle <https://github.com/OCExercise/wordcount-processing/blob/master/build.gradle>

The error resulting from this is long, truncated at the most important part, and doesn’t give any direct hint as to where it might be emerging within the Flink dependencies.

https://gist.github.com/revprez/298a0302711908975add <https://gist.github.com/revprez/298a0302711908975add>





Prez Cannady  
p: 617 500 3378  
e: revprez@opencorrelate.org <ma...@opencorrelate.org>  
GH: https://github.com/opencorrelate <https://github.com/opencorrelate>  
LI: https://www.linkedin.com/in/revprez <https://www.linkedin.com/in/revprez>  









> On Jan 18, 2016, at 3:57 AM, Till Rohrmann <tr...@apache.org> wrote:
> 
> This might be related to the problem mentioned in
> https://issues.apache.org/jira/browse/FLINK-3241 and
> http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/flink-1-0-SNAPSHOT-scala-2-11-compilation-error-td4303.html
> .
> 
> Cheers,
> Till
> 
> On Sun, Jan 17, 2016 at 6:26 PM, Prez Cannady <re...@correlatesystems.com>
> wrote:
> 
>> I concur.  Already had "import org.apache.flink.streaming.api.scala._”,
>> and just tried adding "import org.apache.flink.api.scala._”.  Same issue.
>> 
>> 
>> 
>> Prez Cannady
>> p: 617 500 3378
>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
>> LI: https://www.linkedin.com/in/revprez <
>> https://www.linkedin.com/in/revprez>
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>> On Jan 17, 2016, at 8:59 AM, Aljoscha Krettek <al...@apache.org>
>> wrote:
>>> 
>>> Hi,
>>> I think it’s more complicated than a missing import statement (the code
>> has the correct import statement). I’ll look into it.
>>> 
>>> Cheers,
>>> Aljoscha
>>>> On 17 Jan 2016, at 13:32, Stephan Ewen <se...@apache.org> wrote:
>>>> 
>>>> Hi!
>>>> 
>>>> I think this no Scala version issue, you probably miss an import
>> statement:
>>>> 
>>>> "import org.apache.flink.streaming.api.scala._" or "import
>>>> org.apache.flink.api.scala._"
>>>> 
>>>> See also here:
>>>> 
>> http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters
>>>> 
>>>> Greetings,
>>>> Stephan
>>>> 
>>>> On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <
>> revprez@opencorrelate.org>
>>>> wrote:
>>>> 
>>>>> Attempting to get settled with Flink under Scala 2.11, but running into
>>>>> some odd issues with macro expansion in a project that depends on
>>>>> flink-scala_2.11 and flink-runtime_211.
>>>>> 
>>>>> I’ve instrumented the SocketStreamWordCount quick start <
>>>>> https://github.com/OCExercise/wordcount-processing> to test this
>> issue.
>>>>> It depends on Flink 1.0-SNAPSHOT, so you can test against a local
>> build of
>>>>> Flink for 2.11.
>>>>> 
>>>>> Steps taken
>>>>> 
>>>>> Cloned source and checked out release-0.1
>>>>> Ran tools/change-scala-version.sh 2.11
>>>>> Ran mvn clean install -Dscala.version=2.11.4
>> -Dscala.binary.version=2.11
>>>>> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
>>>>> Ran my spring-booted downstream project’s build and boot run.
>>>>> Expected result
>>>>> 
>>>>> Success
>>>>> 
>>>>> Actual result
>>>>> 
>>>>> During compilation, I get the following error:
>>>>> 
>>>>> [ERROR]
>>>>> 
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
>>>>> error: could not find implicit value for evidence parameter of type
>>>>> org.apache.flink.api.common.typeinfo.TypeInformation[String]
>>>>> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
>>>>> filter { _.nonEmpty } }
>>>>> [ERROR]                                   ^
>>>>> [ERROR]
>>>>> 
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
>>>>> error: can't expand macros compiled by previous versions of Scala
>>>>> [ERROR]     val text = env.fromElements("To be, or not to be,--that is
>> the
>>>>> question:--",
>>>>> 
>>>>> 
>>>>> Discussion
>>>>> 
>>>>> I’m not sure how the Maven build actually succeeded, as there doesn’t
>> seem
>>>>> to be any quasiquotes_2.11 under org.scalamacros <
>>>>> http://central.maven.org/maven2/org/scalamacros/> of any version in
>> the
>>>>> public repos, nor in the four vendor repos configured in flink-parent’s
>>>>> pom.xml. Unless I’m missing something,
>>>>> 
>>>>>          <dependencies>
>>>>>              <dependency>
>>>>>                  <groupId>org.scalamacros</groupId>
>>>>> 
>>>>> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
>>>>>                  <version>${scala.macros.version}</version>
>>>>>              </dependency>
>>>>>          </dependencies>
>>>>> 
>>>>> 
>>>>> I recall an earlier discussion about issues with 2.10 stuff polluting
>> the
>>>>> 2.11 build. Not sure if this is related–I’m able to get through
>> everything
>>>>> I’ve identified up to this point by simply overriding properties in
>>>>> flunk-parent with command line arguments.
>>>>> 
>>>>> Also not sure what next steps to take. Don’t know enough about Scala
>>>>> Macros to know if substituting, say,
>> org.scalameta:quasiquotes_2.11:0.0.4
>>>>> is a viable option (actually tried it, seems to be more trouble than
>> it’s
>>>>> worth).
>>>>> 
>>>>> If anyone has any ideas, I’m more than willing to try thing—Flink’s on
>> our
>>>>> critical path and if we can get it operational under 2.11 then we’er
>> golden.
>>>>> 
>>>>> 
>>>>> 
>>>>> Prez Cannady
>>>>> p: 617 500 3378
>>>>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>>>>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate
>>> 
>>>>> LI: https://www.linkedin.com/in/revprez <
>>>>> https://www.linkedin.com/in/revprez>
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>> 
>> 
>> 


Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Till Rohrmann <tr...@apache.org>.
This might be related to the problem mentioned in
https://issues.apache.org/jira/browse/FLINK-3241 and
http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/flink-1-0-SNAPSHOT-scala-2-11-compilation-error-td4303.html
.

Cheers,
Till

On Sun, Jan 17, 2016 at 6:26 PM, Prez Cannady <re...@correlatesystems.com>
wrote:

> I concur.  Already had "import org.apache.flink.streaming.api.scala._”,
> and just tried adding "import org.apache.flink.api.scala._”.  Same issue.
>
>
>
> Prez Cannady
> p: 617 500 3378
> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
> LI: https://www.linkedin.com/in/revprez <
> https://www.linkedin.com/in/revprez>
>
>
>
>
>
>
>
>
>
> > On Jan 17, 2016, at 8:59 AM, Aljoscha Krettek <al...@apache.org>
> wrote:
> >
> > Hi,
> > I think it’s more complicated than a missing import statement (the code
> has the correct import statement). I’ll look into it.
> >
> > Cheers,
> > Aljoscha
> >> On 17 Jan 2016, at 13:32, Stephan Ewen <se...@apache.org> wrote:
> >>
> >> Hi!
> >>
> >> I think this no Scala version issue, you probably miss an import
> statement:
> >>
> >> "import org.apache.flink.streaming.api.scala._" or "import
> >> org.apache.flink.api.scala._"
> >>
> >> See also here:
> >>
> http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters
> >>
> >> Greetings,
> >> Stephan
> >>
> >> On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <
> revprez@opencorrelate.org>
> >> wrote:
> >>
> >>> Attempting to get settled with Flink under Scala 2.11, but running into
> >>> some odd issues with macro expansion in a project that depends on
> >>> flink-scala_2.11 and flink-runtime_211.
> >>>
> >>> I’ve instrumented the SocketStreamWordCount quick start <
> >>> https://github.com/OCExercise/wordcount-processing> to test this
> issue.
> >>> It depends on Flink 1.0-SNAPSHOT, so you can test against a local
> build of
> >>> Flink for 2.11.
> >>>
> >>> Steps taken
> >>>
> >>> Cloned source and checked out release-0.1
> >>> Ran tools/change-scala-version.sh 2.11
> >>> Ran mvn clean install -Dscala.version=2.11.4
> -Dscala.binary.version=2.11
> >>> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
> >>> Ran my spring-booted downstream project’s build and boot run.
> >>> Expected result
> >>>
> >>> Success
> >>>
> >>> Actual result
> >>>
> >>> During compilation, I get the following error:
> >>>
> >>> [ERROR]
> >>>
> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
> >>> error: could not find implicit value for evidence parameter of type
> >>> org.apache.flink.api.common.typeinfo.TypeInformation[String]
> >>> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
> >>> filter { _.nonEmpty } }
> >>> [ERROR]                                   ^
> >>> [ERROR]
> >>>
> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
> >>> error: can't expand macros compiled by previous versions of Scala
> >>> [ERROR]     val text = env.fromElements("To be, or not to be,--that is
> the
> >>> question:--",
> >>>
> >>>
> >>> Discussion
> >>>
> >>> I’m not sure how the Maven build actually succeeded, as there doesn’t
> seem
> >>> to be any quasiquotes_2.11 under org.scalamacros <
> >>> http://central.maven.org/maven2/org/scalamacros/> of any version in
> the
> >>> public repos, nor in the four vendor repos configured in flink-parent’s
> >>> pom.xml. Unless I’m missing something,
> >>>
> >>>           <dependencies>
> >>>               <dependency>
> >>>                   <groupId>org.scalamacros</groupId>
> >>>
> >>> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
> >>>                   <version>${scala.macros.version}</version>
> >>>               </dependency>
> >>>           </dependencies>
> >>>
> >>>
> >>> I recall an earlier discussion about issues with 2.10 stuff polluting
> the
> >>> 2.11 build. Not sure if this is related–I’m able to get through
> everything
> >>> I’ve identified up to this point by simply overriding properties in
> >>> flunk-parent with command line arguments.
> >>>
> >>> Also not sure what next steps to take. Don’t know enough about Scala
> >>> Macros to know if substituting, say,
> org.scalameta:quasiquotes_2.11:0.0.4
> >>> is a viable option (actually tried it, seems to be more trouble than
> it’s
> >>> worth).
> >>>
> >>> If anyone has any ideas, I’m more than willing to try thing—Flink’s on
> our
> >>> critical path and if we can get it operational under 2.11 then we’er
> golden.
> >>>
> >>>
> >>>
> >>> Prez Cannady
> >>> p: 617 500 3378
> >>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
> >>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate
> >
> >>> LI: https://www.linkedin.com/in/revprez <
> >>> https://www.linkedin.com/in/revprez>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >
>
>

Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Prez Cannady <re...@correlatesystems.com>.
I concur.  Already had "import org.apache.flink.streaming.api.scala._”, and just tried adding "import org.apache.flink.api.scala._”.  Same issue.



Prez Cannady  
p: 617 500 3378  
e: revprez@opencorrelate.org <ma...@opencorrelate.org>  
GH: https://github.com/opencorrelate <https://github.com/opencorrelate>  
LI: https://www.linkedin.com/in/revprez <https://www.linkedin.com/in/revprez>  









> On Jan 17, 2016, at 8:59 AM, Aljoscha Krettek <al...@apache.org> wrote:
> 
> Hi,
> I think it’s more complicated than a missing import statement (the code has the correct import statement). I’ll look into it.
> 
> Cheers,
> Aljoscha
>> On 17 Jan 2016, at 13:32, Stephan Ewen <se...@apache.org> wrote:
>> 
>> Hi!
>> 
>> I think this no Scala version issue, you probably miss an import statement:
>> 
>> "import org.apache.flink.streaming.api.scala._" or "import
>> org.apache.flink.api.scala._"
>> 
>> See also here:
>> http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters
>> 
>> Greetings,
>> Stephan
>> 
>> On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <re...@opencorrelate.org>
>> wrote:
>> 
>>> Attempting to get settled with Flink under Scala 2.11, but running into
>>> some odd issues with macro expansion in a project that depends on
>>> flink-scala_2.11 and flink-runtime_211.
>>> 
>>> I’ve instrumented the SocketStreamWordCount quick start <
>>> https://github.com/OCExercise/wordcount-processing> to test this issue.
>>> It depends on Flink 1.0-SNAPSHOT, so you can test against a local build of
>>> Flink for 2.11.
>>> 
>>> Steps taken
>>> 
>>> Cloned source and checked out release-0.1
>>> Ran tools/change-scala-version.sh 2.11
>>> Ran mvn clean install -Dscala.version=2.11.4 -Dscala.binary.version=2.11
>>> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
>>> Ran my spring-booted downstream project’s build and boot run.
>>> Expected result
>>> 
>>> Success
>>> 
>>> Actual result
>>> 
>>> During compilation, I get the following error:
>>> 
>>> [ERROR]
>>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
>>> error: could not find implicit value for evidence parameter of type
>>> org.apache.flink.api.common.typeinfo.TypeInformation[String]
>>> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
>>> filter { _.nonEmpty } }
>>> [ERROR]                                   ^
>>> [ERROR]
>>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
>>> error: can't expand macros compiled by previous versions of Scala
>>> [ERROR]     val text = env.fromElements("To be, or not to be,--that is the
>>> question:--",
>>> 
>>> 
>>> Discussion
>>> 
>>> I’m not sure how the Maven build actually succeeded, as there doesn’t seem
>>> to be any quasiquotes_2.11 under org.scalamacros <
>>> http://central.maven.org/maven2/org/scalamacros/> of any version in the
>>> public repos, nor in the four vendor repos configured in flink-parent’s
>>> pom.xml. Unless I’m missing something,
>>> 
>>>           <dependencies>
>>>               <dependency>
>>>                   <groupId>org.scalamacros</groupId>
>>> 
>>> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
>>>                   <version>${scala.macros.version}</version>
>>>               </dependency>
>>>           </dependencies>
>>> 
>>> 
>>> I recall an earlier discussion about issues with 2.10 stuff polluting the
>>> 2.11 build. Not sure if this is related–I’m able to get through everything
>>> I’ve identified up to this point by simply overriding properties in
>>> flunk-parent with command line arguments.
>>> 
>>> Also not sure what next steps to take. Don’t know enough about Scala
>>> Macros to know if substituting, say, org.scalameta:quasiquotes_2.11:0.0.4
>>> is a viable option (actually tried it, seems to be more trouble than it’s
>>> worth).
>>> 
>>> If anyone has any ideas, I’m more than willing to try thing—Flink’s on our
>>> critical path and if we can get it operational under 2.11 then we’er golden.
>>> 
>>> 
>>> 
>>> Prez Cannady
>>> p: 617 500 3378
>>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
>>> LI: https://www.linkedin.com/in/revprez <
>>> https://www.linkedin.com/in/revprez>
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
> 


Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Aljoscha Krettek <al...@apache.org>.
Hi,
I think it’s more complicated than a missing import statement (the code has the correct import statement). I’ll look into it.

Cheers,
Aljoscha
> On 17 Jan 2016, at 13:32, Stephan Ewen <se...@apache.org> wrote:
> 
> Hi!
> 
> I think this no Scala version issue, you probably miss an import statement:
> 
> "import org.apache.flink.streaming.api.scala._" or "import
> org.apache.flink.api.scala._"
> 
> See also here:
> http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters
> 
> Greetings,
> Stephan
> 
> On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <re...@opencorrelate.org>
> wrote:
> 
>> Attempting to get settled with Flink under Scala 2.11, but running into
>> some odd issues with macro expansion in a project that depends on
>> flink-scala_2.11 and flink-runtime_211.
>> 
>> I’ve instrumented the SocketStreamWordCount quick start <
>> https://github.com/OCExercise/wordcount-processing> to test this issue.
>> It depends on Flink 1.0-SNAPSHOT, so you can test against a local build of
>> Flink for 2.11.
>> 
>> Steps taken
>> 
>> Cloned source and checked out release-0.1
>> Ran tools/change-scala-version.sh 2.11
>> Ran mvn clean install -Dscala.version=2.11.4 -Dscala.binary.version=2.11
>> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
>> Ran my spring-booted downstream project’s build and boot run.
>> Expected result
>> 
>> Success
>> 
>> Actual result
>> 
>> During compilation, I get the following error:
>> 
>> [ERROR]
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
>> error: could not find implicit value for evidence parameter of type
>> org.apache.flink.api.common.typeinfo.TypeInformation[String]
>> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
>> filter { _.nonEmpty } }
>> [ERROR]                                   ^
>> [ERROR]
>> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
>> error: can't expand macros compiled by previous versions of Scala
>> [ERROR]     val text = env.fromElements("To be, or not to be,--that is the
>> question:--",
>> 
>> 
>> Discussion
>> 
>> I’m not sure how the Maven build actually succeeded, as there doesn’t seem
>> to be any quasiquotes_2.11 under org.scalamacros <
>> http://central.maven.org/maven2/org/scalamacros/> of any version in the
>> public repos, nor in the four vendor repos configured in flink-parent’s
>> pom.xml. Unless I’m missing something,
>> 
>>            <dependencies>
>>                <dependency>
>>                    <groupId>org.scalamacros</groupId>
>> 
>> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
>>                    <version>${scala.macros.version}</version>
>>                </dependency>
>>            </dependencies>
>> 
>> 
>> I recall an earlier discussion about issues with 2.10 stuff polluting the
>> 2.11 build. Not sure if this is related–I’m able to get through everything
>> I’ve identified up to this point by simply overriding properties in
>> flunk-parent with command line arguments.
>> 
>> Also not sure what next steps to take. Don’t know enough about Scala
>> Macros to know if substituting, say, org.scalameta:quasiquotes_2.11:0.0.4
>> is a viable option (actually tried it, seems to be more trouble than it’s
>> worth).
>> 
>> If anyone has any ideas, I’m more than willing to try thing—Flink’s on our
>> critical path and if we can get it operational under 2.11 then we’er golden.
>> 
>> 
>> 
>> Prez Cannady
>> p: 617 500 3378
>> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
>> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
>> LI: https://www.linkedin.com/in/revprez <
>> https://www.linkedin.com/in/revprez>
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 


Re: Dependency on non-existent org.scalamacros:quasiquotes_2.11:

Posted by Stephan Ewen <se...@apache.org>.
Hi!

I think this no Scala version issue, you probably miss an import statement:

"import org.apache.flink.streaming.api.scala._" or "import
org.apache.flink.api.scala._"

See also here:
http://flink.apache.org/faq.html#in-scala-api-i-get-an-error-about-implicit-values-and-evidence-parameters

Greetings,
Stephan

On Sat, Jan 16, 2016 at 9:09 PM, Prez Cannady <re...@opencorrelate.org>
wrote:

> Attempting to get settled with Flink under Scala 2.11, but running into
> some odd issues with macro expansion in a project that depends on
> flink-scala_2.11 and flink-runtime_211.
>
> I’ve instrumented the SocketStreamWordCount quick start <
> https://github.com/OCExercise/wordcount-processing> to test this issue.
> It depends on Flink 1.0-SNAPSHOT, so you can test against a local build of
> Flink for 2.11.
>
> Steps taken
>
> Cloned source and checked out release-0.1
> Ran tools/change-scala-version.sh 2.11
> Ran mvn clean install -Dscala.version=2.11.4 -Dscala.binary.version=2.11
> -Dakka.version=2.4.1 -DskipTests=true at Flink root; build succeeds
> Ran my spring-booted downstream project’s build and boot run.
> Expected result
>
> Success
>
> Actual result
>
> During compilation, I get the following error:
>
> [ERROR]
> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/SocketTextStreamWordCount.scala:73:
> error: could not find implicit value for evidence parameter of type
> org.apache.flink.api.common.typeinfo.TypeInformation[String]
> [ERROR]         val counts = text.flatMap { _.toLowerCase.split("\\W+")
> filter { _.nonEmpty } }
> [ERROR]                                   ^
> [ERROR]
> /Users/revprez/dev/exercise/systems/jvm/flink/wordcount-processing/src/main/scala/org/opencorrelate/jvm/scala/WordCount.scala:40:
> error: can't expand macros compiled by previous versions of Scala
> [ERROR]     val text = env.fromElements("To be, or not to be,--that is the
> question:--",
>
>
> Discussion
>
> I’m not sure how the Maven build actually succeeded, as there doesn’t seem
> to be any quasiquotes_2.11 under org.scalamacros <
> http://central.maven.org/maven2/org/scalamacros/> of any version in the
> public repos, nor in the four vendor repos configured in flink-parent’s
> pom.xml. Unless I’m missing something,
>
>             <dependencies>
>                 <dependency>
>                     <groupId>org.scalamacros</groupId>
>
> <artifactId>quasiquotes_${scala.binary.version}</artifactId>
>                     <version>${scala.macros.version}</version>
>                 </dependency>
>             </dependencies>
>
>
> I recall an earlier discussion about issues with 2.10 stuff polluting the
> 2.11 build. Not sure if this is related–I’m able to get through everything
> I’ve identified up to this point by simply overriding properties in
> flunk-parent with command line arguments.
>
> Also not sure what next steps to take. Don’t know enough about Scala
> Macros to know if substituting, say, org.scalameta:quasiquotes_2.11:0.0.4
> is a viable option (actually tried it, seems to be more trouble than it’s
> worth).
>
> If anyone has any ideas, I’m more than willing to try thing—Flink’s on our
> critical path and if we can get it operational under 2.11 then we’er golden.
>
>
>
> Prez Cannady
> p: 617 500 3378
> e: revprez@opencorrelate.org <ma...@opencorrelate.org>
> GH: https://github.com/opencorrelate <https://github.com/opencorrelate>
> LI: https://www.linkedin.com/in/revprez <
> https://www.linkedin.com/in/revprez>
>
>
>
>
>
>
>
>
>
>