I keep getting this error whenever I try to run the jar file of the project from the command prompt. What does this mean? I checked the manifest for ValidatorBuilder and it has the jcabi-version attribute. Any help is appreciated. Thanks.
2014-12-01 09:42:49 DEBUG ServiceLoaderUtils:138 - Trying to load all SPI implem
entations of interface com.phloc.commons.hash.IHashCodeImplementationRegistrarSP
I
2014-12-01 09:42:49 DEBUG ServiceLoaderUtils:172 - Finished loading all SPI impl
ementations of interface com.phloc.commons.hash.IHashCodeImplementationRegistrar
SPI --> returning 2 instances
2014-12-01 09:42:49 DEBUG HashCodeImplementationRegistry:281 - Found no hashCode
implementation for class java.lang.String
2014-12-01 09:42:49 DEBUG Manifests:168 - 6 attribute(s) loaded ["Archiver-Versi
on", "Build-Jdk", "Built-By", "Created-By", "Main-Class", "Manifest-Version"]
2014-12-01 09:42:49 INFO Manifests:193 - 6 attributes loaded from 1 stream(s) i
n 10ms, 6 saved, 0 ignored: ["Archiver-Version", "Build-Jdk", "Built-By", "Creat
ed-By", "Main-Class", "Manifest-Version"]
Exception in thread "main" java.lang.ExceptionInInitializerError
at com.jcabi.w3c.ValidatorBuilder.<clinit>(ValidatorBuilder.java:71)
at com.cerner.devcenter.wag.processor.CSSValidatorAdapter.cssW3CValidati
on(CSSValidatorAdapter.java:29)
at com.cerner.devcenter.wag.processor.CSSValidator.validateCSS(CSSValida
tor.java:50)
at com.cerner.devcenter.wag.ruleEngine.CSSRuleEngine.<init>(CSSRuleEngin
e.java:64)
at com.cerner.devcenter.wag.processor.CSSAssessment.getGradeReport(CSSAs
sessment.java:134)
at com.cerner.devcenter.wag.textHandler.AssessmentFactory.getGradeReport
(AssessmentFactory.java:98)
at com.cerner.devcenter.wag.WebAssessmentGraderRunner.trackAssessmentFil
es(WebAssessmentGraderRunner.java:138)
at com.cerner.devcenter.wag.WebAssessmentGraderRunner.trackAssessmentFil
es(WebAssessmentGraderRunner.java:135)
at com.cerner.devcenter.wag.WebAssessmentGraderRunner.main(WebAssessment
GraderRunner.java:85)
Caused by: java.lang.IllegalArgumentException: Attribute 'JCabi-Version' not fou
nd in MANIFEST.MF file(s) among 6 other attribute(s): ["Archiver-Version", "Buil
d-Jdk", "Built-By", "Created-By", "Main-Class", "Manifest-Version"]
at com.jcabi.manifests.Manifests.read(Manifests.java:274)
at com.jcabi.w3c.BaseValidator.<clinit>(BaseValidator.java:63)
... 9 more
Looks like you're using an old version of jcabi-w3c. Try the latest one (1.1). If you still have the same issue, submit a ticket here: https://github.com/jcabi/jcabi-w3c/issues We'll try to help
Related
I use PDFbox to read PDF files; I understand that it does not use Log4j, it uses apache's common logging (I was surprised to hear this, since its Maven configuration includes Log4j v1).
When I run my program, I get messages like:
18:13:20.093 [SwingWorker-pool-2-thread-1] DEBUG org.apache.fontbox.ttf.PostScriptTable - No PostScript name information is provided for the font CourierNewPS-BoldMT
18:13:20.102 [SwingWorker-pool-2-thread-1] DEBUG org.apache.fontbox.ttf.GlyphSubstitutionTable - Type 4 GSUB lookup table is not supported and will be ignored
18:13:20.102 [SwingWorker-pool-2-thread-1] DEBUG org.apache.fontbox.ttf.GlyphSubstitutionTable - Type 6 GSUB lookup table is not supported and will be ignored
18:13:20.102 [SwingWorker-pool-2-thread-1] DEBUG org.apache.fontbox.ttf.GlyphSubstitutionTable - Type 6 GSUB lookup table is not supported and will be ignored
(68 messages about GlyphSubstitutionTable), and
18:13:20.163 [SwingWorker-pool-2-thread-1] DEBUG org.apache.fontbox.ttf.GlyphSubstitutionTable - Type 4 GSUB lookup table is not supported and will be ignored
18:13:20.476 [Finalizer] DEBUG org.apache.pdfbox.io.ScratchFileBuffer - ScratchFileBuffer not closed!
18:13:23.327 [Finalizer] DEBUG org.apache.pdfbox.io.ScratchFileBuffer - ScratchFileBuffer not closed!
I have tried putting a commons-logging.properties file in src/main/resources containing
org.apache.commons.logging.Log=org.apache.commons.logging.impl.NoOpLog
I have tried putting the code java.util.logging.Logger.getLogger("org.apache.pdfbox").setLevel(java.util.logging.Level.OFF) into a static initializer of the class containing the static void main method of my program.
I have tried putting
System.setProperty("org.apache.commons.logging.Log", "org.apache.commons.logging.impl.NoOpLog");
into that static initializer, separately and together with the previous code.
When I read the PDF in my code, I still get the log messages mentioned above with any and all of the above attempted fixes. How can I eliminate them; I would prefer to just limit them to warning, error, and severe messaages instead of eliminating all messages, but at this point I'll take suggestions for either one.
public class Main {
static {
java.util.logging.Logger.getLogger(
"org.apache").setLevel(java.util.logging.Level.SEVERE);
}
// ...
has helped me to disable warnings from fontbox also.
While "org.apache.pdfbox" only disables pdfbox warnings, not fontbox ones.
And "org.apache.fontbox" somehow does not disable fontbox warnings.
I have a problem w HotSwap Agent. It is not working correctly.
Setup:
JDK 11 from HotswapAgent.org
Widlfly 14
NetBeans 9
HotSwapAgent 1.3.1-SNAPSHOT
On start i
HOTSWAP AGENT: 08:17:59.098 INFO (org.hotswap.agent.HotswapAgent) - Loading Hotswap agent {1.3.1-SNAPSHOT} - unlimited runtime class redefinition.
In the middle i get a strange:
08:18:56,713 INFO [stdout] (ServerService Thread Pool -- 77) HOTSWAP AGENT: 08:18:56.713 WARNING (org.hotswap.agent.watch.nio.TreeWatcherNIO) - Unable to watch for path vfs:/C:/Java/wildfly-14.0.0.Final/bin/content/application.war/WEB-INF/classes/com/company/, not a local regular file or directory.
But it goes further ok. I change code, click apply code chages. It seemingly changes the code:
Classes to reload:
com.company.web.HeaderPanel$13
com.company.web.HeaderPanel$2
com.company.web.HeaderPanel$3
com.company.web.HeaderPanel$4
com.company.web.HeaderPanel
com.company.web.HeaderPanel$5
com.company.web.HeaderPanel$10
com.company.web.HeaderPanel$11
com.company.web.HeaderPanel$1
com.company.web.HeaderPanel$12
com.company.web.HeaderPanel$6
com.company.web.HeaderPanel$7
com.company.web.HeaderPanel$8
com.company.web.HeaderPanel$9
Code updated
In runtime it then throws an incompatible class change error when i go to the changed class:
java.lang.IncompatibleClassChangeError: Type com.company.web.HeaderPanel$1 is not a nest member of com.company.web.HeaderPanel: current type is not listed as a nest member
at deployment.application.war//com.company.web.HeaderPanel$1.onConfigure(HeaderPanel.java:110)
The relevant source code line is a overriden function in an anonymous class, the super. call:
#Override
protected void onConfigure() {
super.onConfigure();
setVisible(!ssoService.isEnabled());
}
It is not the line i modified. I modified an completely different line.
I'm trying to connect to Teradata through RStudio, but for some reason JDBC function has problems recognizing the path where Java drivers sit. See the code below:
library(RODBC)
library(RJDBC)
library(rJava)
# both Java drivers definitely exist
file.exists('/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/tdgssconfig.jar')
[1] TRUE
file.exists('/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/terajdbc4.jar')
[1] TRUE
But when I paste those paths in JDBC call...
# allow more elaborated error messages to appear
.jclassLoader()$setDebug(1L)
drv = JDBC("com.teradata.jdbc.TeraDriver","/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/tdgssconfig.jar;/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/terajdbc4.jar")
... I get the following error:
RJavaClassLoader: added
'/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/tdgssconfig.jar;/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/terajdbc4.jar'
to the URL class path loader WARNING: the path
'/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/tdgssconfig.jar;/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/terajdbc4.jar'
does NOT exist, it will NOT be added to the internal class path!
RJavaClassLoader: added
'/Library/Frameworks/R.framework/Versions/3.4/Resources/library/RJDBC/java/RJDBC.jar'
to the URL class path loader RJavaClassLoader: adding Java archive
file
'/Library/Frameworks/R.framework/Versions/3.4/Resources/library/RJDBC/java/RJDBC.jar'
to the internal class path
RJavaClassLoader#3d4eac69.findClass(com.teradata.jdbc.TeraDriver)
- URL loader did not find it: java.lang.ClassNotFoundException: com.teradata.jdbc.TeraDriver
RJavaClassLoader.findClass("com.teradata.jdbc.TeraDriver")
- trying class path "/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rJava/java"
Directory, can get
'/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rJava/java/com/teradata/jdbc/TeraDriver.class'?
NO
- trying class path "/Library/Frameworks/R.framework/Versions/3.4/Resources/library/RJDBC/java/RJDBC.jar"
JAR file, can get 'com/teradata/jdbc/TeraDriver'? NO
ClassNotFoundException Error in .jfindClass(as.character(driverClass)[1]) : class not found
Running the same code in R, rather than RStudio, returns the same error.
Also, re-installing RJDBC package (as suggested here) didn't solve the issue.
Can anyone explain why this is happening? Thanks for help.
Here's my session info:
> sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS High Sierra 10.13.3
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib
locale:
[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] devtools_1.13.4 RJDBC_0.2-7 rJava_0.9-9 DBI_0.8 RODBC_1.3-15
[6] dplyr_0.7.4 readr_1.1.1
loaded via a namespace (and not attached):
[1] Rcpp_0.12.15 bindr_0.1 magrittr_1.5 hms_0.3 R6_2.2.2
[6] rlang_0.1.6 httr_1.3.1 tools_3.4.1 git2r_0.19.0 withr_2.1.1.9000
[11] yaml_2.1.16 assertthat_0.2.0 digest_0.6.15 tibble_1.4.2 bindrcpp_0.2
[16] curl_3.0 memoise_1.1.0 glue_1.2.0 compiler_3.4.1 pillar_1.1.0
[21] pkgconfig_2.0.1
That's a mistake in the path - you have inadvertently pasted two paths together (note the semicolon between the paths). You probably intended
drv <- JDBC("com.teradata.jdbc.TeraDriver",
c("/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/tdgssconfig.jar",
"/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/terajdbc4.jar"))
note that you probably can make your life easier by simply using
drv <- JDBC("com.teradata.jdbc.TeraDriver", Sys.glob("/Users/KULMAK/Documents/TeraJDBC__indep_indep.16.10.00.03/*.jar"))
This worked for me. Just make sure that both jars are located in the referenced directory.
library(RJDBC)
drv <- RJDBC::JDBC(driverClass = "com.teradata.jdbc.TeraDriver", classPath = Sys.glob("~/drivers/teradata/*"))
conn <- dbConnect(drv,'jdbc:teradata://<server>/<db>',"un","pw")
result.df<- dbGetQuery(conn,"select * from table")
I followed a tutorial to build a simple plugin for NetBeans v 7.3.1 ... I know this is an older version of NetBeans but I'm restricted by the software my employer insists on using.
All I have is a simple plugin that loads a toolbar item that consists of a button. But when I run the plugin, I always get the same exception alert in a popup:
A org.openide.util.RequestProcessor$SlowItem exception has occurred.
Please report this at [blah blah website blah blah log file created]
This message hasn't been helpful solving the problem. Here is the log file, which as a Java n00b I've been unable to decipher or understand what is going on in it well enough to figure out why I'm getting this error. And there's little to no info I've been able to find in searches. If I'm reading it right (I'm sure I'm not reading it right) then the error is happening in .jar files where I can't do anything about it. So is there anything I can hope to do to ship a plugin that will run without throwing exceptions? Workaround? Something stupid I missed as a n00b?
SEVERE [org.openide.util.RequestProcessor]: Error in RequestProcessor org.openide.loaders.FolderInstance$1R
java.lang.NullPointerException
at org.openide.util.Exceptions$AnnException.getMessage(Exceptions.java:238)
at org.openide.util.Exceptions$AnnException.toString(Exceptions.java:321)
at java.util.Objects.toString(Objects.java:159)
at java.lang.Throwable.initCause(Throwable.java:457)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:279)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:286)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:286)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:286)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:286)
at org.openide.util.Exceptions$AnnException.findOrCreate(Exceptions.java:256)
at org.openide.util.Exceptions.attachMessage(Exceptions.java:85)
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:157)
at org.openide.loaders.InstanceDataObject$Ser.instanceClass(InstanceDataObject.java:1338)
at org.openide.loaders.InstanceDataObject.instanceClass(InstanceDataObject.java:809)
at org.openide.awt.MenuBar$LazyMenu$MenuFolder.acceptCookie(MenuBar.java:808)
at org.openide.loaders.FolderInstance.acceptDataObject(FolderInstance.java:419)
at org.openide.loaders.FolderInstance.defaultProcessObjects(FolderInstance.java:795)
at org.openide.loaders.FolderInstance.access$000(FolderInstance.java:103)
at org.openide.loaders.FolderInstance$1R.init(FolderInstance.java:693)
at org.openide.loaders.FolderInstance$1R.run(FolderInstance.java:720)
Caused: org.openide.util.RequestProcessor$SlowItem: task failed due to
at org.openide.util.RequestProcessor$Task.schedule(RequestProcessor.java:1473)
at org.openide.loaders.FolderInstance.processObjects(FolderInstance.java:768)
at org.openide.loaders.FolderInstance$Listener.finished(FolderInstance.java:1052)
at org.openide.loaders.FolderList.createBoth(FolderList.java:923)
at org.openide.loaders.FolderList.getObjects(FolderList.java:608)
at org.openide.loaders.FolderList.access$200(FolderList.java:77)
at org.openide.loaders.FolderList$ListTask.computeResult(FolderList.java:1007)
at org.openide.loaders.FolderList$ListTask.run(FolderList.java:983)
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432)
[catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2044)
WARNING [org.netbeans.ProxyClassLoader]: Will not load class org.netbeans.modules.editor.NbCodeFoldingAction arbitrarily from one of ModuleCL#183d64f7[org.netbeans.modules.editor] and ModuleCL#52954826[com.mycompany.TrestleLauncher] starting from SystemClassLoader[263 modules]; see http://wiki.netbeans.org/DevFaqModuleCCE
INFO [org.openide.loaders.FolderInstance.Menu.View]
Cannot get class for MultiFileObject#26bf742[Menu/View/org-netbeans-modules-editor-NbCodeFoldingAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Cannot get class for MultiFileObject#26bf742[Menu/View/org-netbeans-modules-editor-NbCodeFoldingAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Caused: java.lang.NullPointerException
at org.openide.util.Exceptions$AnnException.getMessage(Exceptions.java:238)
at org.openide.util.Exceptions$AnnException.toString(Exceptions.java:321)
at java.util.Objects.toString(Objects.java:159)
at java.lang.Throwable.initCause(Throwable.java:457)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:279)
at org.openide.util.Exceptions$AnnException.findOrCreate(Exceptions.java:256)
at org.openide.util.Exceptions.attachMessage(Exceptions.java:85)
at org.openide.loaders.InstanceSupport.findClass(InstanceSupport.java:506)
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:148)
Caused: java.lang.ClassNotFoundException: From file: MultiFileObject#26bf742[Menu/View/org-netbeans-modules-editor-NbCodeFoldingAction.instance] due to
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:162)
at org.openide.loaders.InstanceDataObject$Ser.instanceClass(InstanceDataObject.java:1338)
at org.openide.loaders.InstanceDataObject.instanceClass(InstanceDataObject.java:809)
at org.openide.awt.MenuBar$LazyMenu$MenuFolder.acceptCookie(MenuBar.java:808)
[catch] at org.openide.loaders.FolderInstance.acceptDataObject(FolderInstance.java:419)
at org.openide.loaders.FolderInstance.defaultProcessObjects(FolderInstance.java:795)
at org.openide.loaders.FolderInstance.access$000(FolderInstance.java:103)
at org.openide.loaders.FolderInstance$1R.init(FolderInstance.java:693)
at org.openide.loaders.FolderInstance$1R.run(FolderInstance.java:720)
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432)
at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2044)
ALL [null]: Cannot get class for MultiFileObject#26bf742[Menu/View/org-netbeans-modules-editor-NbCodeFoldingAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
WARNING [org.netbeans.modules.editor.settings.storage.keybindings.KeyMapsStorage]: The keybinding 'A-MOUSE_WHEEL_UP' in Editors/Keybindings/NetBeans/Defaults/org-netbeans-modules-editor-keybindings.xml may not work correctly on Mac. Keybindings starting with Alt or Ctrl should be coded with latin capital letters 'O' or 'D' respectively. For details see org.openide.util.Utilities.stringToKey().
WARNING [org.netbeans.modules.editor.settings.storage.keybindings.KeyMapsStorage]: The keybinding 'A-MOUSE_WHEEL_DOWN' in Editors/Keybindings/NetBeans/Defaults/org-netbeans-modules-editor-keybindings.xml may not work correctly on Mac. Keybindings starting with Alt or Ctrl should be coded with latin capital letters 'O' or 'D' respectively. For details see org.openide.util.Utilities.stringToKey().
WARNING [org.netbeans.ProxyClassLoader]: Will not load class org.netbeans.modules.editor.MainMenuAction$GoToSourceAction arbitrarily from one of ModuleCL#183d64f7[org.netbeans.modules.editor] and ModuleCL#52954826[com.mycompany.TrestleLauncher] starting from SystemClassLoader[263 modules]; see http://wiki.netbeans.org/DevFaqModuleCCE
INFO [org.openide.loaders.FolderInstance.Menu.GoTo]
Cannot get class for MultiFileObject#7e5308ff[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSourceAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Cannot get class for MultiFileObject#7e5308ff[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSourceAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Caused: java.lang.NullPointerException
at org.openide.util.Exceptions$AnnException.getMessage(Exceptions.java:238)
at org.openide.util.Exceptions$AnnException.toString(Exceptions.java:321)
at java.util.Objects.toString(Objects.java:159)
at java.lang.Throwable.initCause(Throwable.java:457)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:279)
at org.openide.util.Exceptions$AnnException.findOrCreate(Exceptions.java:256)
at org.openide.util.Exceptions.attachMessage(Exceptions.java:85)
at org.openide.loaders.InstanceSupport.findClass(InstanceSupport.java:506)
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:148)
Caused: java.lang.ClassNotFoundException: From file: MultiFileObject#7e5308ff[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSourceAction.instance] due to
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:162)
at org.openide.loaders.InstanceDataObject$Ser.instanceClass(InstanceDataObject.java:1338)
at org.openide.loaders.InstanceDataObject.instanceClass(InstanceDataObject.java:809)
at org.openide.awt.MenuBar$LazyMenu$MenuFolder.acceptCookie(MenuBar.java:808)
[catch] at org.openide.loaders.FolderInstance.acceptDataObject(FolderInstance.java:419)
at org.openide.loaders.FolderInstance.defaultProcessObjects(FolderInstance.java:795)
at org.openide.loaders.FolderInstance.access$000(FolderInstance.java:103)
at org.openide.loaders.FolderInstance$1R.init(FolderInstance.java:693)
at org.openide.loaders.FolderInstance$1R.run(FolderInstance.java:720)
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432)
at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2044)
ALL [null]: Cannot get class for MultiFileObject#7e5308ff[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSourceAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
WARNING [org.netbeans.ProxyClassLoader]: Will not load class org.netbeans.modules.editor.MainMenuAction$GoToSuperAction arbitrarily from one of ModuleCL#183d64f7[org.netbeans.modules.editor] and ModuleCL#52954826[com.mycompany.TrestleLauncher] starting from SystemClassLoader[263 modules]; see http://wiki.netbeans.org/DevFaqModuleCCE
INFO [org.openide.loaders.FolderInstance.Menu.GoTo]
Cannot get class for MultiFileObject#210198eb[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSuperAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Cannot get class for MultiFileObject#210198eb[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSuperAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
Caused: java.lang.NullPointerException
at org.openide.util.Exceptions$AnnException.getMessage(Exceptions.java:238)
at org.openide.util.Exceptions$AnnException.toString(Exceptions.java:321)
at java.util.Objects.toString(Objects.java:159)
at java.lang.Throwable.initCause(Throwable.java:457)
at org.openide.util.Exceptions$AnnException.findOrCreate0(Exceptions.java:279)
at org.openide.util.Exceptions$AnnException.findOrCreate(Exceptions.java:256)
at org.openide.util.Exceptions.attachMessage(Exceptions.java:85)
at org.openide.loaders.InstanceSupport.findClass(InstanceSupport.java:506)
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:148)
Caused: java.lang.ClassNotFoundException: From file: MultiFileObject#210198eb[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSuperAction.instance] due to
at org.openide.loaders.InstanceSupport.instanceClass(InstanceSupport.java:162)
at org.openide.loaders.InstanceDataObject$Ser.instanceClass(InstanceDataObject.java:1338)
at org.openide.loaders.InstanceDataObject.instanceClass(InstanceDataObject.java:809)
at org.openide.awt.MenuBar$LazyMenu$MenuFolder.acceptCookie(MenuBar.java:808)
[catch] at org.openide.loaders.FolderInstance.acceptDataObject(FolderInstance.java:419)
at org.openide.loaders.FolderInstance.defaultProcessObjects(FolderInstance.java:795)
at org.openide.loaders.FolderInstance.access$000(FolderInstance.java:103)
at org.openide.loaders.FolderInstance$1R.init(FolderInstance.java:693)
at org.openide.loaders.FolderInstance$1R.run(FolderInstance.java:720)
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432)
at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2044)
ALL [null]: Cannot get class for MultiFileObject#210198eb[Menu/GoTo/org-netbeans-modules-editor-MainMenuAction$GoToSuperAction.instance] defined by [jar:file:/C:/Program%20Files/NetBeans%207.3.1/ide/modules/org-netbeans-modules-editor.jar!/org/netbeans/modules/editor/resources/layer.xml]
WARNING [org.openide.filesystems.Ordering]: Not all children in Menu/Window/ marked with the position attribute: [Other], but some are: [org-netbeans-modules-project-ui-logical-tab-action.shadow, org-netbeans-modules-project-ui-physical-tab-action.shadow, org-netbeans-modules-favorites-View.shadow, org-netbeans-core-ide-ServicesTabAction.shadow, org-netbeans-modules-tasklist-ui-TaskListAction.shadow, ShowPaletteAction.shadow, org-netbeans-core-windows-actions-GlobalPropertiesAction.shadow, Output, Navigator, Debug, Versioning, Web, SwitchToRecentDocumentAction.shadow, ProgressListAction.shadow, Separator3.instance, ConfigureWindow, org-netbeans-core-windows-actions-ResetWindowsAction.shadow, Separator4.instance, CloseWindowAction.shadow, CloseAllDocumentsAction.shadow, CloseAllButThisAction.shadow, DocumentsAction.shadow]
WARNING [org.netbeans.TopSecurityManager]: use of system property netbeans.user has been obsoleted in favor of InstalledFileLocator/Places at org.netbeans.modules.uihandler.Installer.logsDirectory(Installer.java:840)
INFO [org.netbeans.core.netigso.Netigso]: bundle org.eclipse.osgi#3.8.0.v20120529-1548 256
INFO [org.netbeans.core.netigso.Netigso]: bundle org.eclipse.osgi#3.8.0.v20120529-1548 stopped
INFO [org.netbeans.core.netigso.Netigso]: bundle org.eclipse.osgi#3.8.0.v20120529-1548 stopped
This seems to have been a result of adding a library package via Wrapped .JAR that didn't need to be added (or more accurately, needed to be added using a more correct method). Instead of finding, downloading, and depending on Wrapped .JAR files to account for dependencies, I needed to add module dependencies by name (not by package) in NetBeans.
I am writing eclipse plugin. I've got MultiPageEditor in which i've got 5 pages. On first page there is an editor which extends GraphicalEditor(geEx), on second there are 2(logicInputEditor, logicOutputEditor) GroovyEditor's org.codehaus.groovy.eclipse.editor.GroovyEditor). geEx is working with one file(e.g. first.qwe) and
logicEditors are working with 2 other files(in.groovy, out.groovy). In
geEx there is a code:
#Override
public void commandStackChanged(EventObject event) {
firePropertyChange(IEditorPart.PROP_DIRTY);
super.commandStackChanged(event);
}
When I edit file first.qwe MultiPageEditor know that something has
been modified and marks it and allow to save file - everything is
fine.
I add listeners to GrooveEditors:
logicInputEditor.addPropertyListener(new IPropertyListener() {
#Override
public void propertyChanged(Object source, int propId) {
if (propId == IEditorPart.PROP_DIRTY){
firePropertyChange(IEditorPart.PROP_DIRTY);
}
}
});
I can't override commandStackChanged function, because GrooveEditor doesn't implement CommandStackListener.
Each time I edit something in one of GroovyEditors, the MultiPageEditor is changing its state to dirty - that's what i wanted, but also exception is printed on console. So - it's working as i want, but throwing and catching exception each time user type someting in editor is slow and generally bad.
The message is:
Problem trying to determine classpath of project Test:
Java Model Exception: Java Model Status [Test does not exist]
at org.eclipse.jdt.internal.core.JavaElement.newNotPresentException(JavaElement.java:495)
at org.eclipse.jdt.internal.core.JavaModelManager.getPerProjectInfoCheckExistence(JavaModelManager.java:2287)
at org.eclipse.jdt.internal.core.JavaProject.getPerProjectInfo(JavaProject.java:1914)
at org.eclipse.jdt.internal.core.JavaProject.getOutputLocation(JavaProject.java:1741)
at org.eclipse.jdt.core.util.CompilerUtils.calculateClasspath(CompilerUtils.java:209)
at org.eclipse.jdt.core.util.CompilerUtils.setGroovyClasspath(CompilerUtils.java:152)
at org.eclipse.jdt.core.util.CompilerUtils.setGroovyClasspath(CompilerUtils.java:117)
at org.codehaus.jdt.groovy.model.GroovyCompilationUnit.buildStructure(GroovyCompilationUnit.java:260)
at org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:258)
at org.eclipse.jdt.internal.core.JavaElement.openWhenClosed(JavaElement.java:526)
at org.eclipse.jdt.internal.core.CompilationUnit.makeConsistent(CompilationUnit.java:1100)
at org.codehaus.jdt.groovy.model.GroovyReconcileWorkingCopyOperation.makeConsistent(GroovyReconcileWorkingCopyOperation.java:60)
at org.eclipse.jdt.internal.core.ReconcileWorkingCopyOperation.executeOperation(ReconcileWorkingCopyOperation.java:89)
at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:728)
at org.eclipse.jdt.internal.core.JavaModelOperation.runOperation(JavaModelOperation.java:788)
at org.codehaus.jdt.groovy.model.GroovyCompilationUnit.reconcile(GroovyCompilationUnit.java:423)
at org.eclipse.jdt.internal.core.CompilationUnit.reconcile(CompilationUnit.java:1231)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:133)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.access$0(JavaReconcilingStrategy.java:108)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy$1.run(JavaReconcilingStrategy.java:89)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:87)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:151)
at org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
at org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:104)
at org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:77)
at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206)
or:
!ENTRY org.eclipse.jdt.core 4 4 2012-08-13 20:33:29.402
!MESSAGE Problem with build structure for in.groovy
!STACK 1
Java Model Exception: Java Model Status [Test does not exist]
at org.eclipse.jdt.internal.core.JavaElement.newJavaModelException(JavaElement.java:505)
at org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:246)
at org.eclipse.jdt.internal.core.JavaElement.openWhenClosed(JavaElement.java:526)
at org.eclipse.jdt.internal.core.JavaElement.getElementInfo(JavaElement.java:255)
at org.eclipse.jdt.internal.core.JavaElement.getElementInfo(JavaElement.java:241)
at org.eclipse.jdt.internal.core.JavaProject.getJavaProjectElementInfo(JavaProject.java:1646)
at org.eclipse.jdt.internal.core.JavaProject.newNameLookup(JavaProject.java:2334)
at org.eclipse.jdt.internal.core.SearchableEnvironment.<init>(SearchableEnvironment.java:59)
at org.eclipse.jdt.internal.core.SearchableEnvironment.<init>(SearchableEnvironment.java:66)
at org.eclipse.jdt.internal.core.CancelableNameEnvironment.<init>(CancelableNameEnvironment.java:26)
at org.eclipse.jdt.internal.core.CompilationUnitProblemFinder.process(CompilationUnitProblemFinder.java:178)
at org.codehaus.jdt.groovy.model.GroovyCompilationUnit.buildStructure(GroovyCompilationUnit.java:338)
at org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:258)
at org.eclipse.jdt.internal.core.JavaElement.openWhenClosed(JavaElement.java:526)
at org.eclipse.jdt.internal.core.CompilationUnit.makeConsistent(CompilationUnit.java:1100)
at org.codehaus.jdt.groovy.model.GroovyReconcileWorkingCopyOperation.makeConsistent(GroovyReconcileWorkingCopyOperation.java:60)
at org.eclipse.jdt.internal.core.ReconcileWorkingCopyOperation.executeOperation(ReconcileWorkingCopyOperation.java:89)
at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:728)
at org.eclipse.jdt.internal.core.JavaModelOperation.runOperation(JavaModelOperation.java:788)
at org.codehaus.jdt.groovy.model.GroovyCompilationUnit.reconcile(GroovyCompilationUnit.java:423)
at org.eclipse.jdt.internal.core.CompilationUnit.reconcile(CompilationUnit.java:1231)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:133)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.access$0(JavaReconcilingStrategy.java:108)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy$1.run(JavaReconcilingStrategy.java:89)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:87)
at org.eclipse.jdt.internal.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:151)
at org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
at org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:104)
at org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:77)
at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206)
!SUBENTRY 1 org.eclipse.jdt.core 4 969 2012-08-13 20:33:29.402
!MESSAGE Test does not exist
The question is - how i can fix this? How should i send 'message' to MultiPageEditor, that one of GroovyEditors is 'dirty'?
Finally solved - the problem was not in my code, but in GroovyEditor - if project nature is Java project nature(probably Groovy project nature will work too) everything is fine, otherwise GroovyEditor throws exceptions. I've reported bug to Groove Editor issue tracker and it has been solved so in next version everything should be fine. Now only solution is to add java project nature to natures of your project.