wt-io-it / odoo-pycharm-plugin

Plugin to Support Odoo in Pycharm
GNU Affero General Public License v3.0
19 stars 10 forks source link

OdooModelServer getModels(): Read access is allowed from inside read-action #47

Open davidmonterocrespo24 opened 2 years ago

davidmonterocrespo24 commented 2 years ago

Plugin Version: 0.5.16 IDEA Version: PyCharm 2021.2.3

Details: Current thread: Thread[JobScheduler FJ pool 6/7,4,main] 1413330547 ; dispatch thread: false; isDispatchThread(): false SystemEventQueueThread: Thread[AWT-EventQueue-0,6,main] 72222086 ``` java.lang.Throwable: Read access is allowed from inside read-action (or EDT) only (see com.intellij.openapi.application.Application.runReadAction()) at com.intellij.openapi.diagnostic.Logger.error(Logger.java:200) at com.intellij.openapi.application.impl.ApplicationImpl.assertReadAccessAllowed(ApplicationImpl.java:969) at com.intellij.util.indexing.FileBasedIndexImpl.ensureUpToDate(FileBasedIndexImpl.java:756) at com.intellij.util.indexing.FileBasedIndexEx.processExceptions(FileBasedIndexEx.java:244) at com.intellij.util.indexing.FileBasedIndexEx.processValueIterator(FileBasedIndexEx.java:349) at com.intellij.util.indexing.FileBasedIndexEx.processValuesInScope(FileBasedIndexEx.java:318) at com.intellij.util.indexing.FileBasedIndexEx.getContainingFiles(FileBasedIndexEx.java:200) at at.wtioit.intellij.plugins.odoo.models.impl.OdooModelServiceImpl.lambda$getModels$0(OdooModelServiceImpl.java:31) at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195) at java.base/java.util.HashMap$KeySpliterator.tryAdvance(HashMap.java:1624) at java.base/java.util.stream.StreamSpliterators$WrappingSpliterator.lambda$initPartialTraversalState$0(StreamSpliterators.java:294) at java.base/java.util.stream.StreamSpliterators$AbstractWrappingSpliterator.fillBuffer(StreamSpliterators.java:206) at java.base/java.util.stream.StreamSpliterators$AbstractWrappingSpliterator.doAdvance(StreamSpliterators.java:169) at java.base/java.util.stream.StreamSpliterators$WrappingSpliterator.tryAdvance(StreamSpliterators.java:300) at java.base/java.util.Spliterators$1Adapter.hasNext(Spliterators.java:681) at java.base/java.util.Spliterators$IteratorSpliterator.trySplit(Spliterators.java:1776) at java.base/java.util.stream.AbstractShortCircuitTask.compute(AbstractShortCircuitTask.java:114) at java.base/java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:746) at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290) at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020) at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656) at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594) at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183) ```
ap-wtioit commented 2 years ago

@davidmonterocrespo24 i could not reproduce this (although in 2021.2.3 and 0.5.x i get a lot of Slow operations are prohibited on EDT, which will hopefully be fixed in 0.6.x)

Can you remember if you did anything that would cause this and help me reproduce it?