matthiasblaesing opened a new issue, #4211: URL: https://github.com/apache/netbeans/issues/4211
### Apache NetBeans version Apache NetBeans latest daily build ### What happened The ValidateLayerConsistencyTest seems to be flaky: https://github.com/apache/netbeans/blob/2bdbb637653cf19179963a3150add8f99d8b6977/platform/o.n.core/test/qa-functional/src/org/netbeans/core/validation/ValidateLayerConsistencyTest.java Sometimes fails in an assertion: ``` 2022-06-08T18:30:24.0613903Z [junit] FINE [org.openide.util.lookup.implspi.ActiveQueue]: Got dequeued reference org.openide.util.lookup.AbstractLookup$ReferenceToResult@597289e4 2022-06-08T18:30:24.0614562Z [junit] FINE [org.openide.util.lookup.implspi.ActiveQueue]: Got dequeued reference org.openide.util.lookup.AbstractLookup$ReferenceToResult@67cb9a30 2022-06-08T18:30:27.1650822Z [junit] java.lang.AssertionError: Has to be NbRepository: org.openide.filesystems.Repository@5cf749fa Initialization stack: java.lang.Exception: initialized 2022-06-08T18:30:27.1651908Z [junit] at org.openide.filesystems.Repository.<init>(Repository.java:326) 2022-06-08T18:30:27.1652502Z [junit] at org.openide.filesystems.Repository$3.call(Repository.java:373) 2022-06-08T18:30:27.1652987Z [junit] at org.openide.filesystems.Repository$3.call(Repository.java:368) 2022-06-08T18:30:27.1653709Z [junit] at org.openide.filesystems.Repository.delayFileSystemAttachImpl(Repository.java:1018) 2022-06-08T18:30:27.1654297Z [junit] at org.openide.filesystems.Repository.getDefault(Repository.java:368) 2022-06-08T18:30:27.1654794Z [junit] at org.netbeans.core.startup.Main.start(Main.java:298) 2022-06-08T18:30:27.1655764Z [junit] at org.netbeans.core.startup.TopThreadGroup.run(TopThreadGroup.java:98) 2022-06-08T18:30:27.1656203Z [junit] at java.lang.Thread.run(Thread.java:750) 2022-06-08T18:30:27.1656523Z [junit] 2022-06-08T18:30:27.1656885Z [junit] at org.netbeans.core.startup.Main.start(Main.java:298) 2022-06-08T18:30:27.1657532Z [junit] at org.netbeans.core.startup.TopThreadGroup.run(TopThreadGroup.java:98) 2022-06-08T18:30:27.1657948Z [junit] at java.lang.Thread.run(Thread.java:750) ``` The full log of the run is zipped: [fulllog.txt.zip](https://github.com/apache/netbeans/files/8864253/fulllog.txt.zip) (The quoted part start in line 109186). The listed stack trace was retrieved using an idea from @jtulach, by creating a fake exception in the Repository constructor, fetching the stacktrace from it and storing it into a public field of that class. This seems to be a race when initializing the META-INF based services. The `NbRepository` that is expected, is registered as such a service and thus should be available from the default lookup. ### How to reproduce _No response_ ### Did this work correctly in an earlier version? No ### Operating System Linux ### JDK JDK 8 - 19 all show behavior sometimes ### Apache NetBeans packaging Other ### Anything else _No response_ ### Are you willing to submit a pull request? No ### Code of Conduct Yes -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
