On Sun, Jun 11, 2017 at 07:23:45PM +0200, Jürgen Spitzmüller wrote:
> Am Sonntag, den 11.06.2017, 18:32 +0200 schrieb Enrico Forestieri:
> > > I also think this widget should be disabled if not all necessary
> > > packages are installed.
> > 
> > This is problematic, because we should check for installed python
> > modules, which I don't think we currently do. 
> 
> This can be added to configure.py, no?

I see a further difficulty here. The pygments module could be installed
as a python 2 or python 3 module. The right python version to use is
determined by the used pygmentize command. So, if we are running python 2
and don't find the pygments module, it is not an indication that it is
not available. Conversely if we are running python 3 and pygments is
installed as a python 2 module.

Maybe, the only sensible thing to do is checking for a pygmentize command
and, if not found, warn the user but don't disable the widget.

-- 
Enrico

Reply via email to