You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Anthony Vanelverdinghe (Jira)" <ji...@apache.org> on 2021/01/05 19:45:00 UTC

[jira] [Commented] (NETBEANS-4477) Autocompletion often fails

    [ https://issues.apache.org/jira/browse/NETBEANS-4477?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17259169#comment-17259169 ] 

Anthony Vanelverdinghe commented on NETBEANS-4477:
--------------------------------------------------

[~Kacer] The steps to reproduce are: (1) set up an environment like mine, and (2) code Java for 5-10 minutes. Now you can argue that the second step is too vague, but as I said in the decription:
bq. It happens frequently, but I don't have a simple recipe to reproduce.

> Autocompletion often fails
> --------------------------
>
>                 Key: NETBEANS-4477
>                 URL: https://issues.apache.org/jira/browse/NETBEANS-4477
>             Project: NetBeans
>          Issue Type: Bug
>          Components: java - Editor
>    Affects Versions: 12.0
>         Environment: Product Version: Apache NetBeans IDE 12.0
> Java: 15-ea; OpenJDK 64-Bit Server VM 15-ea+28-1400
> Runtime: OpenJDK Runtime Environment 15-ea+28-1400
> System: Windows 10 version 10.0 running on amd64; UTF-8; en_GB (nb)
>            Reporter: Anthony Vanelverdinghe
>            Priority: Major
>
> It happens frequently, but I don't have a simple recipe to reproduce. The log is full of stacktraces like follows, so hopefully that's sufficient: 
> {noformat}
> java.lang.IllegalStateException: Cannot call getCompilationUnit() if current phase < JavaSource.Phase.PARSED. You must call toPhase(Phase.PARSED) first.
> 	at org.netbeans.modules.java.source.parsing.CompilationInfoImpl.getCompilationUnit(CompilationInfoImpl.java:200)
> 	at org.netbeans.api.java.source.CompilationInfo.getCompilationUnit(CompilationInfo.java:167)
> 	at org.netbeans.api.java.source.TreeUtilities.pathFor(TreeUtilities.java:330)
> 	at org.netbeans.modules.java.completion.BaseTask.getCompletionEnvironment(BaseTask.java:264)
> 	at org.netbeans.modules.java.completion.JavaCompletionTask.resolve(JavaCompletionTask.java:297)
> 	at org.netbeans.modules.java.completion.BaseTask.run(BaseTask.java:94)
> 	at org.netbeans.modules.java.completion.JavaCompletionTask.run(JavaCompletionTask.java:60)
> 	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)
> Caused: org.netbeans.modules.parsing.spi.ParseException
> 	at org.netbeans.modules.parsing.impl.TaskProcessor.runUserTask(TaskProcessor.java:186)
> 	at org.netbeans.modules.parsing.api.ParserManager.parse(ParserManager.java:81)
> [catch] at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.query(JavaCompletionProvider.java:193)
> 	at org.netbeans.spi.editor.completion.support.AsyncCompletionTask.run(AsyncCompletionTask.java:198)
> 	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)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists