pylint-pycharm
pylint-pycharm copied to clipboard
Plugin argument doesn't work !
I am trying to add the https://github.com/OCA/pylint-odoo to Pycharm but it doesn't work with the plugin.
here is the configuration
the result from the plugin
the result using external tools
this the log when I only add one argument--output-format=colorized
10:53 Unexpected Exception Caught
The scan failed due to an exception: Use JsonReader.setLenient(true) to accept malformed JSON at path $
Root cause:
Use JsonReader.setLenient(true) to accept malformed JSON at path $
com.squareup.moshi.JsonEncodingException: Use JsonReader.setLenient(true) to accept malformed JSON at path $
at com.squareup.moshi.JsonReader.syntaxError(JsonReader.java:233)
at com.squareup.moshi.JsonUtf8Reader.checkLenient(JsonUtf8Reader.java:1051)
at com.squareup.moshi.JsonUtf8Reader.doPeek(JsonUtf8Reader.java:366)
at com.squareup.moshi.JsonUtf8Reader.peek(JsonUtf8Reader.java:193)
at com.squareup.moshi.JsonAdapter$2.fromJson(JsonAdapter.java:134)
at com.squareup.moshi.JsonAdapter.fromJson(JsonAdapter.java:36)
at com.leinardi.pycharm.pylint.plapi.PylintRunner.scan(PylintRunner.java:283)
at com.leinardi.pycharm.pylint.checker.ScanFiles.scan(ScanFiles.java:108)... (show balloon)
+1
Tried to add the pylint_django plugin but it did not work either.
Edit:
Although I'm using the pylint
binary outside of my virtualenv, I had to install the plugin in the virtualenv as well. Now the plugin works like a charm. Maybe this helps you as well, @m3asmi?
thank you @jonathanhacker for the tip, but I'm not using virtualenv
I have this same issue.
interesting, it does seem to be related to the colorized parameter. I took that out and suddenly it seems to work just fine.
Look in the source code. The plugin calls pylint the the --output-format json
to extract the result of pylint.
So of course if you use --output-format=colorized
it will fail, as it now doesn't get the JSON result it expects...