Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Write-unsafe context! Model changes are allowed #154

Open
rakeshkalshetti opened this issue Apr 18, 2018 · 1 comment
Open

Write-unsafe context! Model changes are allowed #154

rakeshkalshetti opened this issue Apr 18, 2018 · 1 comment

Comments

@rakeshkalshetti
Copy link

Write-unsafe context! Model changes are allowed from write-safe contexts only. Please ensure you're using invokeLater/invokeAndWait with a correct modality state (not "any"). See TransactionGuard documentation for details.
current modality=ModalityState.NON_MODAL
known modalities:
ModalityState:{[com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog0,94,116,1224x533,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Batch Drawable Importer,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]], [com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog1,440,58,424x483,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Select Image Asset(s),defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]]}, writingAllowed=true;
ModalityState:{[com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog0,94,116,1224x533,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Batch Drawable Importer,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]], [com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog2,244,41,924x683,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]]}, writingAllowed=true;
ModalityState:{[com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog0,94,116,1224x533,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Batch Drawable Importer,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]], [com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog3,244,41,924x683,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]]}, writingAllowed=true;
ModalityState:{[com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog0,94,116,1224x533,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Batch Drawable Importer,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]]}, writingAllowed=true;
ModalityState:{[com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog0,94,116,1224x533,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Batch Drawable Importer,defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]], [com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog[dialog4,440,58,424x483,invalid,hidden,layout=java.awt.BorderLayout,APPLICATION_MODAL,title=Select Image Asset(s),defaultCloseOperation=DO_NOTHING_ON_CLOSE,rootPane=,rootPaneCheckingEnabled=true]]}, writingAllowed=true;
ModalityState:{[Rearrange code 2128757946: running=false; canceled=false]}, writingAllowed=true;
ModalityState.NON_MODAL, writingAllowed=true
com.intellij.openapi.diagnostic.Logger$EmptyThrowable
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:140)
at com.intellij.openapi.application.TransactionGuardImpl.assertWriteActionAllowed(TransactionGuardImpl.java:232)
at com.intellij.psi.impl.PsiModificationTrackerImpl.fireEvent(PsiModificationTrackerImpl.java:93)
at com.intellij.psi.impl.PsiModificationTrackerImpl.incCountersInner(PsiModificationTrackerImpl.java:101)
at com.intellij.psi.impl.PsiModificationTrackerImpl.treeChanged(PsiModificationTrackerImpl.java:118)
at com.intellij.psi.impl.PsiManagerImpl.fireEvent(PsiManagerImpl.java:367)
at com.intellij.psi.impl.PsiManagerImpl.beforeChildAddition(PsiManagerImpl.java:236)
at com.intellij.psi.impl.file.impl.PsiVFSListener.lambda$fileCreated$1(PsiVFSListener.java:154)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:1003)
at com.intellij.psi.impl.file.impl.PsiVFSListener.fileCreated(PsiVFSListener.java:141)
at com.intellij.psi.impl.file.impl.PsiVFSListener.fileCopied(PsiVFSListener.java:134)
at com.intellij.openapi.vfs.impl.BulkVirtualFileListenerAdapter.fireAfter(BulkVirtualFileListenerAdapter.java:73)
at com.intellij.psi.impl.file.impl.PsiVFSListener.after(PsiVFSListener.java:687)
at com.intellij.psi.impl.file.impl.PsiVFSListener$1.after(PsiVFSListener.java:96)
at sun.reflect.GeneratedMethodAccessor94.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.intellij.util.messages.impl.MessageBusConnectionImpl.deliverMessage(MessageBusConnectionImpl.java:117)
at com.intellij.util.messages.impl.MessageBusImpl.doPumpMessages(MessageBusImpl.java:449)
at com.intellij.util.messages.impl.MessageBusImpl.pumpWaitingBuses(MessageBusImpl.java:410)
at com.intellij.util.messages.impl.MessageBusImpl.pumpMessages(MessageBusImpl.java:399)
at com.intellij.util.messages.impl.MessageBusImpl.sendMessage(MessageBusImpl.java:380)
at com.intellij.util.messages.impl.MessageBusImpl.access$200(MessageBusImpl.java:45)
at com.intellij.util.messages.impl.MessageBusImpl$2.invoke(MessageBusImpl.java:231)
at com.sun.proxy.$Proxy15.after(Unknown Source)
at com.intellij.openapi.vfs.newvfs.persistent.PersistentFSImpl.processEvent(PersistentFSImpl.java:688)
at com.intellij.openapi.vfs.newvfs.persistent.PersistentFSImpl.copyFile(PersistentFSImpl.java:415)
at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.lambda$copy$0(VirtualFileSystemEntry.java:255)
at com.intellij.openapi.vfs.encoding.EncodingRegistry.doActionAndRestoreEncoding(EncodingRegistry.java:70)
at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.copy(VirtualFileSystemEntry.java:255)
at com.intellij.psi.impl.file.PsiDirectoryImpl.copyFileFrom(PsiDirectoryImpl.java:358)
at de.mprengemann.intellij.plugin.androidicons.images.RefactoringTask$3.run(RefactoringTask.java:211)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:1003)
at de.mprengemann.intellij.plugin.androidicons.util.RunnableUtils$WriteAction.run(RunnableUtils.java:32)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:149)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:109)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:99)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:85)
at de.mprengemann.intellij.plugin.androidicons.util.RunnableUtils.runWriteCommand(RunnableUtils.java:23)
at de.mprengemann.intellij.plugin.androidicons.images.RefactoringTask.copy(RefactoringTask.java:198)
at de.mprengemann.intellij.plugin.androidicons.images.RefactoringTask.move(RefactoringTask.java:231)
at de.mprengemann.intellij.plugin.androidicons.images.RefactoringTask.access$200(RefactoringTask.java:45)
at de.mprengemann.intellij.plugin.androidicons.images.RefactoringTask$1.run(RefactoringTask.java:79)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:762)
at java.awt.EventQueue.access$500(EventQueue.java:98)
at java.awt.EventQueue$3.run(EventQueue.java:715)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:732)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:822)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:650)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:366)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

@tjwpdl
Copy link

tjwpdl commented Jul 23, 2018

I still have this problem, and it puts the drawable folders in the root directory of my drive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants