Ubuntu: Why does pylint Gedit plugin give me an error when I try to enable it?


I downloaded and installed the pylint gedit plugin. I then copied the pylint.gedit_plugin file and the pylint directory to


I couldn't see it in the gedit plugins menu so I renamed pylint.gedit_plugin to pylint.plugin and changed the first line of the file from

[Gedit Plugin]  



Now I can see it in the menu. But when I select it, the red circle error icon appears and I cannot enable to plugin. What else do I need to do to use the plugin? Any help is appreciated.


This is a good question, as it is sometimes tricky to setup the pylint plugin for gedit. The following tutorial was tested with gedit 3.4.1 on 12.04.

1) The first thing you need to do is install pylint itself from the repositories, as without this program, the pylint plugin won't work. So please run:

sudo apt-get install pylint   

This is the necessary dependency and is not the plugin itself, and it should install as well python-logilab-common and python-logilab-astng, which are also necessary.

2) You may be using the wrong version of the plugin. It is of foremost importance that you use the forked version of the pylint plugin from the Launchpad page, which is called gedit-pylint-2, as that supports gedit 3.x versions; other versions of the plugin will not work with gedit 3.x. (However, if you are using an earlier version of gedit than 3.x, you should use the 1.1 version of the pylint plugin from the Launchpad page.)

Download the latest version of the source: it does not need compiling, but it is important to follow my installation procedure, as parts of the included README in the download are inaccurate. (I recommend you start again and follow this guide, as it worked for me. You should not need to tweak or rename anything, as you say you are doing.)

Move to the folder with the downloaded file (after checking the md5) and extract it with

tar -xzvf gedit-pylint-2-2.1.tar.gz  cd gedit-pylint-2-2.1  

Now, you can actually install it to ~/.local/share/gedit/plugins without placing it in any of the system directories. I should remove your installed version, and install it again as detailed below, as I think you had the wrong version anyway: the plugin name must be pylint-2.plugin, not pylint.gedit_plugin.

While in the downloaded plugin folder, run the following:

mkdir -p ~/.local/share/gedit/plugins  cp -R pylint-2/ ~/.local/share/gedit/plugins  cp pylint-2.plugin ~/.local/share/gedit/plugins  

Now, you need to install the gsettings schemas, before you try to activate the plugin in gedit. (The included README is accurate here).

Indeed, this is probably why you could not activate the plugin properly, as you must install the schemas. (The following commands assume you are in the downloaded plugin folder)

sudo cp gedit-pylint-2.gschema.xml /usr/share/glib-2.0/schemas/  sudo glib-compile-schemas /usr/share/glib-2.0/schemas/  

Now, run gedit and enable the plugin from edit > preferences > plugins (screenshot 1), and you will be able to use it from tools > pylint (screenshot 2). Make sure you have the bottom panel enabled, as that is where the output from the plugin will go (screenshot 3).

1) Enable the plugin from preferences:

enter image description here

2) It should be listed in the tools menu:

enter image description here

3) You can now analyse your python scripts: note the bottom pane is enabled. Click 'check' in the bottom pain to run the plugin.

enter image description here

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »