Results 1 to 10 of 10

Thread: SDG : Compiler error in Java Editor but not marked in file, and Maven build is OK

  1. #1
    Join Date
    Jan 2006
    Location
    Edmonton, Alberta, Canada
    Posts
    62

    Default SDG : Compiler error in Java Editor but not marked in file, and Maven build is OK

    I'm not sure it is only me or anyone else has the same problem.

    I downloaded Spring Data Graph Neo4J Hello World example and successfully imported to STS 2.6.0.SR1. The Maven build and Junit Tests are all OK in STS, and if open World.java in editor, I got compiler error mark at line 26:
    Type mismatch : cannot convert from Class<World> to Class<? extends NodeBacked>
    And there is a red line under "World.class".

    Same compiler error at line 57 for "relateTo".

    But no error mark at file icon in Package Explorer view and no error in Problems view. If I right click this file and select "Validate", it reports "The validation completed with no errors or warnings."

    I tried to clean up, and tried in STS 2.6.0.RELEASE, created my own test project, always the same compiler error mark in Java Editor. I can still test, run and continue development, just feel annoying to see those error marks.

    In AJDT Event Trace view, I can see those messages:
    ...
    10:14:10 addSourcelineTask message=advice defined in org.springframework.data.graph.neo4j.support.relat ionship.Neo4jRelationshipBacking has not been applied [Xlint:adviceDidNotMatch] file=C:\Users\Yuan\.m2\repository\org\springframew ork\data\spring-data-neo4j\1.0.0.RELEASE\spring-data-neo4j-1.0.0.RELEASE.jar!org\springframework\data\graph\n eo4j\support\relationship\Neo4jRelationshipBacking .class line=130
    10:14:10 addSourcelineTask message=advice defined in org.springframework.data.graph.neo4j.support.relat ionship.Neo4jRelationshipBacking has not been applied [Xlint:adviceDidNotMatch] file=C:\Users\Yuan\.m2\repository\org\springframew ork\data\spring-data-neo4j\1.0.0.RELEASE\spring-data-neo4j-1.0.0.RELEASE.jar!org\springframework\data\graph\n eo4j\support\relationship\Neo4jRelationshipBacking .class line=137
    10:14:10 AspectJ reports build successful, build was: FULL
    10:14:10 AJDE Callback: finish. Was full build: true
    I googled [Xlint:adviceDidNotMatch], and found Andy Clement mentioned that here http://aspectj.2085585.n4.nabble.com...td2085505.html

    Couldn't find the bug report in Eclipse Bugzilla, so not sure if it has been resolved or not. Any help?

    Thanks,

    Yuan

  2. #2
    Join Date
    Jan 2011
    Location
    Dresden, Germany
    Posts
    525

    Default

    Could you please update to STS 2.6.0 release or at least your ajdt plugin
    to the latest version 1.6.11.RELEASE

    That is the version also used by the maven build

    Thanks

    Michael

  3. #3
    Join Date
    Jan 2006
    Location
    Edmonton, Alberta, Canada
    Posts
    62

    Default

    I did a fresh install of STS 2.6.0.SR1, build Id: 201103161000. The AJDT version is 2.1.2.e36x-20110307-1000. See attached img of plugin details. Thanks,

    Yuan
    Attached Images Attached Images

  4. #4
    Join Date
    Jul 2010
    Posts
    139

    Default

    I see this same error, but have just learned to ingore it.

  5. #5
    Join Date
    Jan 2011
    Location
    Dresden, Germany
    Posts
    525

    Default

    The "adviceDidNotMatch" is just a warning from AJ, I'm more concerned about the editor window error. That shouldn't show up at all with a current version of AJDT.

    I forwarded this thread to Andy Clement, we'll see what he can say about that.

    Thanks

    Michael

  6. #6
    Join Date
    May 2009
    Location
    Vancouver
    Posts
    274

    Default

    Hi,

    I observed this last week when playing around with the example, we are currently tracking it as https://bugs.eclipse.org/bugs/show_bug.cgi?id=343001

    If you really want to remove the errors for now, turn off 'report problems as you type' in the Java>Editor preferences. They are harmless, but annoying.

    cheers
    Andy
    ---
    Andy Clement
    AspectJ Project Lead

  7. #7
    Join Date
    May 2009
    Location
    Vancouver
    Posts
    274

    Default

    Just a quick follow up to say the editor problem is now fixed. Grab the latest AJDT that includes the fix using this update site:

    http://download.eclipse.org/tools/ajdt/36/dev/update

    cheers
    Andy

  8. #8
    Join Date
    Jan 2006
    Location
    Edmonton, Alberta, Canada
    Posts
    62

    Default

    Quote Originally Posted by Andy Clement View Post
    Just a quick follow up to say the editor problem is now fixed. Grab the latest AJDT that includes the fix using this update site:

    http://download.eclipse.org/tools/ajdt/36/dev/update

    cheers
    Andy
    I updated AJDT to 2.1.3.e36x-20110502-0800 through this update site, but the problem still exists. I will wait for new version of STS and try again.

    Thank you Andy for your update.

    Yuan

  9. #9
    Join Date
    May 2009
    Location
    Vancouver
    Posts
    274

    Default

    Hi Yuan,

    A full build will be required to get everything in step after installing that update.

    However, maybe we fixed something other than what you see, can you confirm where you are seeing issues, is it still in World.java? I started up my eclipse this morning, saw two warnings in World.java, kicked off a build and they disappeared.

    cheers,
    Andy

  10. #10
    Join Date
    Jan 2006
    Location
    Edmonton, Alberta, Canada
    Posts
    62

    Default It works now!

    Yes, it is working. I did a fresh install of STS 2.6.0.SR1 and updated AJDT. Then import the hello-worlds sample, the errors in Java Editor were gone.

    Thank you And for the help!

    Yuan

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •