Open filipe-maia opened 2 years ago
This bug is not urgent, I think.
At the same time, another notification I got was:
A java.io.FileNotFoundException exception has occurred. However, the system should continue working without further problems. Click Show Details for the stack trace.
Annotation: From: nbfs://nbhost/SystemFileSystem/org-netbeans-api-project-libraries/Libraries/restapi.xml
Annotation: From: nbfs://nbhost/SystemFileSystem/org-netbeans-api-project-libraries/Libraries/restapi.xml
Annotation: From: nbfs://nbhost/SystemFileSystem/org-netbeans-api-project-libraries/Libraries/restapi.xml
From: nbfs://nbhost/SystemFileSystem/org-netbeans-api-project-libraries/Libraries/restapi.xml
From: nbfs://nbhost/SystemFileSystem/org-netbeans-api-project-libraries/Libraries/restapi.xml
Caused: java.nio.file.NoSuchFileException: C:\desenv-java\NetBeans IDE\14\enterprise\modules\org-netbeans-modules-websvc-restlib.jar
at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:85)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:108)
at java.base/sun.nio.fs.WindowsFileAttributeViews$Basic.readAttributes(WindowsFileAttributeViews.java:53)
at java.base/sun.nio.fs.WindowsFileAttributeViews$Basic.readAttributes(WindowsFileAttributeViews.java:38)
at java.base/sun.nio.fs.WindowsFileSystemProvider.readAttributes(WindowsFileSystemProvider.java:199)
at java.base/java.nio.file.Files.readAttributes(Files.java:1851)
at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1264)
at java.base/java.util.zip.ZipFile$CleanableResource.
Maybe this was caused by some plugin imported from version 12.0 to 14.
After further testing, the first notification appears everytime I try to open a XHTML file, and NetBeans won't open that XHTML file.
Same error in Apache NetBeans 17 and OpenJDK 17.0.7+7-LTS. NetBeans won't open any file.
java.lang.NullPointerException: Cannot invoke "javax.swing.text.AttributeSet.getAttribute(Object)" because "as" is null
at org.netbeans.editor.Coloring.toFont(Coloring.java:795)
at org.netbeans.editor.Coloring.fromAttributeSet(Coloring.java:758)
at com.junichi11.netbeans.modules.color.codes.preview.ui.DrawingPanel.updateColors(DrawingPanel.java:307)
at com.junichi11.netbeans.modules.color.codes.preview.ui.DrawingPanel.
How to fix this error? java.lang.NullPointerException: Cannot invoke "javax.swing.text.AttributeSet.getAttribute(Object)" because "attr" is null at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.resolveBackColor(CodeFoldingSideBar.java:353) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.updateColors(CodeFoldingSideBar.java:368) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.access$200(CodeFoldingSideBar.java:99) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar$2.preferenceChange(CodeFoldingSideBar.java:231) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.addNotify(CodeFoldingSideBar.java:287) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4846) at org.netbeans.modules.editor.impl.CustomizableSideBar$WestSidebarHolder.addNotify(CustomizableSideBar.java:288) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4846) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4846) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4846) at java.desktop/java.awt.Container.addImpl(Container.java:1150) at java.desktop/java.awt.Container.add(Container.java:1001) at org.openide.text.CloneableEditorInitializer.initCustomEditor(CloneableEditorInitializer.java:523) at org.openide.text.CloneableEditorInitializer.initCustomEditorAndDecorationsInEDT(CloneableEditorInitializer.java:573) [catch] at org.openide.text.CloneableEditorInitializer.run(CloneableEditorInitializer.java:321) at org.openide.text.CloneableEditorInitializer.processPendingEDTRequests(CloneableEditorInitializer.java:135) at org.openide.text.CloneableEditorInitializer.waitForFinishedInitialization(CloneableEditorInitializer.java:103) at org.openide.text.CloneableEditor.getEditorPane(CloneableEditor.java:673) at org.netbeans.core.multiview.MultiViewCloneableTopComponent.getEditorPane(MultiViewCloneableTopComponent.java:274) at org.openide.text.CloneableEditorSupport.getOpenedPanes(CloneableEditorSupport.java:830) at org.netbeans.modules.nbform.FormEditorSupport.isJavaEditorDisplayed(FormEditorSupport.java:1198) at org.netbeans.modules.form.JavaCodeGenerator$FormListener.formChanged(JavaCodeGenerator.java:4037) at org.netbeans.modules.form.FormModel.fireEvents(FormModel.java:1312) at org.netbeans.modules.form.FormModel.fireEventBatch(FormModel.java:1285) at org.netbeans.modules.form.FormModel.firePendingEvents(FormModel.java:1248) at org.netbeans.modules.form.FormModel.access$000(FormModel.java:43) at org.netbeans.modules.form.FormModel$2.run(FormModel.java:1225) at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:773) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:720) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:714) at java.base/java.security.AccessController.doPrivileged(AccessController.java:400) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:87) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742) at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:136) at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
I found this error after my pc ran out of battery and the drive where I had NetBeans got disconnected. Seems like the cache got corrupted, because deleting NetBeans' cache and restarting it fixed the problem
Apache NetBeans version
Apache NetBeans 14
What happened
Started NetBeans and got a notification saying: "A java.lang.NullPointerException exception has occurred. Please report this at https://netbeans.apache.org/nb/report-issue, including a copy of your messages.log file as an attachment. The messages.log file is located in your C:\Users***\AppData\Roaming\NetBeans\14\var\log folder."
java.lang.NullPointerException: Cannot invoke "javax.swing.text.AttributeSet.getAttribute(Object)" because "attr" is null at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.resolveBackColor(CodeFoldingSideBar.java:353) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.updateColors(CodeFoldingSideBar.java:368) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.access$200(CodeFoldingSideBar.java:99) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar$2.preferenceChange(CodeFoldingSideBar.java:231) at org.netbeans.modules.editor.fold.ui.CodeFoldingSideBar.addNotify(CodeFoldingSideBar.java:287) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at org.netbeans.modules.editor.impl.CustomizableSideBar$WestSidebarHolder.addNotify(CustomizableSideBar.java:288) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4839) at java.desktop/javax.swing.JRootPane.addNotify(JRootPane.java:729) at java.desktop/java.awt.Container.addNotify(Container.java:2804) at java.desktop/java.awt.Window.addNotify(Window.java:791) at java.desktop/java.awt.Frame.addNotify(Frame.java:495) at java.desktop/java.awt.Window.pack(Window.java:829) at org.netbeans.modules.java.editor.JavaEditorWarmUpTask.run(JavaEditorWarmUpTask.java:269) at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:771) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:722) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:716) at java.base/java.security.AccessController.doPrivileged(AccessController.java:399) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:741) at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:136) [catch] at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90
messages.log messages1.log messages2.log
How to reproduce
Just started NetBeans 14 after updating from 12.0 to 14 and after importing 12.0 definitions.
Did this work correctly in an earlier version?
No / Don't know
Operating System
Win10 64bit
JDK
OpenJDK17.0.2
Apache NetBeans packaging
Apache NetBeans binary zip
Anything else
No response
Are you willing to submit a pull request?
No
Code of Conduct
Yes