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

Eclipse validtion is failed with "The type org.eclipse.jdt.annotation.NonNull cannot be resolved" #5078

Closed
romani opened this Issue Sep 6, 2017 · 2 comments

Comments

Projects
None yet
1 participant
@romani
Member

romani commented Sep 6, 2017

Build on master is failed and for many PRs:
https://travis-ci.org/checkstyle/checkstyle/jobs/272149359#L2934

$ mvn clean compile exec:exec -Peclipse-compiler
...
2017-09-06 01:39:52 (2.92 MB/s) - `/home/travis/.m2/repository/R-4.7-201706120950/ecj-4.7.jar' saved [2484245/2484245]
Executing eclipse compiler, output is redirected to target/eclipse/report.txt...
Checking for ERROR|WARNING|INFO  in target/eclipse/report.txt ...
----------
1. ERROR in /home/travis/build/checkstyle/checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/api/AbstractCheck.java (at line 1)
	////////////////////////////////////////////////////////////////////////////////
	^

The type org.eclipse.jdt.annotation.NonNull cannot be resolved. It is indirectly referenced from required .class files
----------
1 problem (1 error)
[ERROR] Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)

problem was not reproducible on my local.

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Sep 6, 2017

Member

validation: https://www.eclipse.org/eclipse/news/4.6/jdt.php#null-analysis-generics

web proposed solution: https://stackoverflow.com/a/33785728/1015848

new dependency case in new violations:

----------
9. ERROR in /home/rivanov/java/github/checkstyle/checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/gui/ParseTreeTableModel.java (at line 146)
	listenerList.add(TreeModelListener.class, listener);
	                                          ^^^^^^^^
Null type safety (type annotations): The expression of type 'TreeModelListener' needs unchecked conversion to conform to '@NonNull TreeModelListener'
----------
10. ERROR in /home/rivanov/java/github/checkstyle/checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/gui/ParseTreeTableModel.java (at line 151)
	listenerList.remove(TreeModelListener.class, listener);
	                                             ^^^^^^^^
Null type safety (type annotations): The expression of type 'TreeModelListener' needs unchecked conversion to conform to '@NonNull TreeModelListener'
----------
10 problems (10 errors)
[ERROR] Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)

violations will be suppressed till #5060 .

Member

romani commented Sep 6, 2017

validation: https://www.eclipse.org/eclipse/news/4.6/jdt.php#null-analysis-generics

web proposed solution: https://stackoverflow.com/a/33785728/1015848

new dependency case in new violations:

----------
9. ERROR in /home/rivanov/java/github/checkstyle/checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/gui/ParseTreeTableModel.java (at line 146)
	listenerList.add(TreeModelListener.class, listener);
	                                          ^^^^^^^^
Null type safety (type annotations): The expression of type 'TreeModelListener' needs unchecked conversion to conform to '@NonNull TreeModelListener'
----------
10. ERROR in /home/rivanov/java/github/checkstyle/checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/gui/ParseTreeTableModel.java (at line 151)
	listenerList.remove(TreeModelListener.class, listener);
	                                             ^^^^^^^^
Null type safety (type annotations): The expression of type 'TreeModelListener' needs unchecked conversion to conform to '@NonNull TreeModelListener'
----------
10 problems (10 errors)
[ERROR] Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)

violations will be suppressed till #5060 .

romani added a commit that referenced this issue Sep 6, 2017

@romani romani added the miscellaneous label Sep 6, 2017

@romani romani added this to the 8.3 milestone Sep 6, 2017

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Sep 6, 2017

Member

fix is merged.

Member

romani commented Sep 6, 2017

fix is merged.

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