Code Style settings not loading, related error appears in idea.log

Hi,

I've been getting a "Unable to save settings: Failed to save settings. Please restart PhpStorm" error for a week or two now. I recently checked the idea.log file, which I've attached. It is essentially a repeat of the following Exception:

2019-07-04 01:17:51,337 [41399412]   WARN - mponents.impl.stores.StoreUtil - Save settings failed 
java.lang.RuntimeException: Cannot save scheme codestyles/XenForo 2
at com.intellij.configurationStore.schemeManager.SchemeManagerImpl.save(SchemeManagerImpl.kt:316)
at com.intellij.configurationStore.schemeManager.SchemeManagerFactoryBase.save(SchemeManagerFactoryImpl.kt:96)
at com.intellij.configurationStore.ComponentStoreWithExtraComponents$saveSettingsSavingComponentsAndCommitComponents$2$1.invokeSuspend(ComponentStoreWithExtraComponents.kt:61)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:32)
at kotlinx.coroutines.DispatchedTask.run(Dispatched.kt:236)
at com.intellij.openapi.application.TransactionGuardImpl$2.run(TransactionGuardImpl.java:315)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.doRun(LaterInvocator.java:435)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.runNextEvent(LaterInvocator.java:419)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.run(LaterInvocator.java:403)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:764)
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:74)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:734)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:729)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:678)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:373)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
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)
Caused by: java.lang.NullPointerException
at com.intellij.psi.impl.source.codeStyle.CodeStyleSchemeImpl.writeScheme(CodeStyleSchemeImpl.java:123)
at com.intellij.configurationStore.LazySchemeProcessor.writeScheme(scheme-impl.kt:62)
at com.intellij.configurationStore.LazySchemeProcessor.writeScheme(scheme-impl.kt:53)
at com.intellij.configurationStore.schemeManager.SchemeManagerImpl.saveScheme(SchemeManagerImpl.kt:373)
at com.intellij.configurationStore.schemeManager.SchemeManagerImpl.save(SchemeManagerImpl.kt:313)
... 25 more

When I noticed that it was referring to the Code Style preferences, I attempted to check them, in order to re-save them, but the Code Style preferences pane never loads - there's a fixed loading spinner visible.

Any idea on how to fix this?

PhpStorm 2019.1.3
Build #PS-191.7479.51, built on June 18, 2019
JRE: 1.8.0_202-release-1483-b53 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
macOS 10.14.5

2 comments
Comment actions Permalink

Apologies, I forgot to attach the idea.log file, however, it's literally just the above exception repeated ad-nauseum.

0
Comment actions Permalink

I just tried removing the ~/Library/Application Support/PhpStorm* directory and it resolved it.

0

Please sign in to leave a comment.