Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-1215

Failed formatted paste with Java package import

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 9.0
    • None
    • None

    Description

      Tried to do formatted paste in maven Java 8 web project, in Java class. I suppose the failure is related to import of Java package needed for pasted Java code.

      Stacktrace:

      java.lang.NoSuchMethodError: com.sun.tools.javac.code.Scope$NamedImportScope.<init>(Lcom/sun/tools/javac/code/Symbol;Lcom/sun/tools/javac/code/Scope;)V
      at org.netbeans.api.java.source.SourceUtils.resolveImport(SourceUtils.java:427)
      at org.netbeans.modules.java.editor.imports.ClipboardHandler$1.run(ClipboardHandler.java:154)
      at org.netbeans.modules.java.editor.imports.ClipboardHandler$1.run(ClipboardHandler.java:126)
      at org.netbeans.api.java.source.JavaSource$1.run(JavaSource.java:672)
      at org.netbeans.api.java.source.JavaSource$1.run(JavaSource.java:662)
      at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:501)
      at org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:586)
      at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:130)
      at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:114)
      at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:181)
      at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:178)
      at org.netbeans.modules.masterfs.filebasedfs.utils.FileChangedManager.priorityIO(FileChangedManager.java:153)
      at org.netbeans.modules.masterfs.providers.ProvidedExtensions.priorityIO(ProvidedExtensions.java:335)
      at org.netbeans.modules.parsing.nb.DataObjectEnvFactory.runPriorityIO(DataObjectEnvFactory.java:118)
      at org.netbeans.modules.parsing.impl.Utilities.runPriorityIO(Utilities.java:67)
      at org.netbeans.modules.parsing.impl.TaskProcessor.runUserTask(TaskProcessor.java:178)
      at org.netbeans.modules.parsing.api.ParserManager.parse(ParserManager.java:81)
      at org.netbeans.api.java.source.JavaSource.runUserActionTaskImpl(JavaSource.java:451)
      at org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:422)
      at org.netbeans.api.java.source.JavaSource.runModificationTask(JavaSource.java:683)
      at org.netbeans.modules.java.editor.imports.ClipboardHandler.doImport(ClipboardHandler.java:126)
      at org.netbeans.modules.java.editor.imports.ClipboardHandler.access$100(ClipboardHandler.java:113)
      at org.netbeans.modules.java.editor.imports.ClipboardHandler$4$1.run(ClipboardHandler.java:216)
      at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
      at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
      at org.openide.util.lookup.Lookups.executeWith(Lookups.java:278)
      at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)
      Caused: org.openide.util.RequestProcessor$FastItem: task failed due to

      Attachments

        Activity

          People

            jlahoda Jan Lahoda
            vit.suchanek Vít Suchánek
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: