idea-conventional-commit icon indicating copy to clipboard operation
idea-conventional-commit copied to clipboard

"Unable to save settings" in WebStorm

Open rklec opened this issue 2 years ago • 5 comments
trafficstars

STR

  1. I open the settings and change the paths to some custom-made CoAuthors file and token JSON: grafik

  2. I then click save.

What happens

grafik

"Unable to save settings"

If I restart WebStorm as stated, the settings are reset/back as the old ones again. And if I change the settings again then, the issue happens again. So this issue is reproducible.

What should happen

No error.

This has worked previously (in Rider e.g.).

System

(I have just updated to the last WebStorm version.)

WebStorm 2023.2.3
Build #WS-232.10072.28, built on October 11, 2023
*****
Runtime version: 17.0.8.1+7-b1000.32 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Windows 10.0
GC: G1 Young Generation, G1 Old Generation
Memory: 4096M
Cores: 12
Registry:
    debugger.new.tool.window.layout=true
    ide.experimental.ui=true

Non-Bundled Plugins:
    com.github.lppedd.idea-conventional-commit (0.22.0)
    de.femtopedia.diffplugin (2.1.11)
    com.4lex4.intellij.solarized (2.4.0)
    some.awesome (1.14)
    com.jetbrains.space (232.10072.29)
    monokai-pro (1.10)
    com.crunch42.openapi (1.66)
    Key Promoter X (2023.2.0)
    com.intellij.ml.llm (232.9826)
    org.sonarlint.idea (9.1.0.75538)
    com.microsoft.vso.idea (1.162.2)
    zielu.gittoolbox (500.0.21+222)
    mobi.hsz.idea.gitignore (4.5.2)
    izhangzhihao.rainbow.brackets.lite (1.1.0)

rklec avatar Oct 13 '23 08:10 rklec

Hmm same error happens when I change the GUI compact mode (though the setting seems to be applied then).

Also reported upstream: https://youtrack.jetbrains.com/issue/WEB-63366/Unable-to-save-settings-in-WebStorm-each-time-when-changing-a-setting-after-updating-to-232.10072.28

rklec avatar Oct 13 '23 08:10 rklec

Upstream (IntelliJ) devs helped and it seems to be an issue about this plugin. Because if I disable it, everything works again and GUI settings can be saved.

IntelliJ log here: https://gist.github.com/rklec/aafa74ccaecf8f59badde1d1086a2fa2

rklec avatar Oct 13 '23 09:10 rklec

Linked to #124. Having a look now.

lppedd avatar Nov 09 '23 15:11 lppedd

Looks like I managed to get an infinite loop into a regexp. That's quite an accomplishment.

The good way to solve this problem is to phase out the commit message parsing using regexp, and instead rely on the language support. I need to improve the lexer for that.

lppedd avatar Nov 09 '23 19:11 lppedd

Yeah infinite RegEx'es are bad. It's a common problem: https://stackoverflow.com/questions/15919146/regular-expression-goes-into-infinite-loop

Is there any solution for now or could you push a hotfix release with some bad commit reverted (if you need, "git bisect" is always great to find a problematic commit.), as this issue makes the whole extension unusable?

rklec avatar Nov 28 '23 16:11 rklec