Bug 986892

Summary: gedit-latex 3.4.1 can't load on Gedit 3.8.1
Product: [Fedora] Fedora Reporter: Rémi G. <remjg>
Component: gedit-latexAssignee: Ignacio Casal Quinteiro (nacho) <icq>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: bart, danielbristot, griffin.milsap, icq, mebassett, sergio.pasra
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: gedit-latex-3.8.0-3.fc19 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-10 01:04:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Rémi G. 2013-07-22 10:56:08 UTC
Description of problem:
The LaTeX Gedit plugin can't be loaded.

Version-Release number of selected component (if applicable):
gedit-2:3.8.3-1.fc19 (64 bits)
gedit-latex-3.4.1-3.fc19 (64 bits)
gedit-plugins-3.8.3-1.fc19 (64 bits)

Steps to Reproduce:
1. Go to Application menu > Preferences
2. In the tab "Plugins", check "LaTeX Plugin"

Actual results:
The LaTeX plugin doesn't load, it shows instead a stop sign in place of the checkbox and you can read the following tooltip by moving the pointer on it:
> The plugin 'LaTeX Plugin' couldn't not be loaded
> An error occurred: Plugin loader 'Python' was not found
If I run Gedit from a terminal, I can read the following message:
> libpeas-WARNING **: Could not find loader 'python' for plugin 'latex'

Additional info:
I've just found that this problem might be fixed upstream in gedit-latex 3.8:
https://mail.gnome.org/archives/gedit-list/2013-July/msg00001.html

Comment 1 Fedora Update System 2013-07-22 11:29:59 UTC
gedit-latex-3.8.0-1.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/gedit-latex-3.8.0-1.fc19

Comment 2 Fedora Update System 2013-07-23 01:11:29 UTC
Package gedit-latex-3.8.0-1.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing gedit-latex-3.8.0-1.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-13405/gedit-latex-3.8.0-1.fc19
then log in and leave karma (feedback).

Comment 3 Rémi G. 2013-07-23 07:23:52 UTC
Thank you for the prompt reaction, I'm impressed.
I've just installed it. Plugin seems to load until I encounter another issue:

 Traceback (most recent call last):
  File "/usr/lib64/gedit/plugins/latex/__init__.py", line 39, in <module>
    from .windowactivatable import LaTeXWindowActivatable
  File "/usr/lib64/gedit/plugins/latex/windowactivatable.py", line 36, in <module>
    from .config import EDITOR_VIEWS, ACTIONS
  File "/usr/lib64/gedit/plugins/latex/config.py", line 26, in <module>
    from .latex.actions import LaTeXMenuAction, LaTeXNewAction, LaTeXChooseMasterAction, \
  File "/usr/lib64/gedit/plugins/latex/latex/actions.py", line 33, in <module>
    from .editor import LaTeXEditor
  File "/usr/lib64/gedit/plugins/latex/latex/editor.py", line 37, in <module>
    from .expander import LaTeXReferenceExpander
  File "/usr/lib64/gedit/plugins/latex/latex/expander.py", line 28, in <module>
    from .cache import LaTeXDocumentCache
  File "/usr/lib64/gedit/plugins/latex/latex/cache.py", line 111
    print self.__file.path
             ^
SyntaxError: invalid syntax

(gedit:2560): libpeas-WARNING **: Error loading plugin 'latex'

So I don't know what to check (Untested/Works for me/Does not work) on the Fedora Update System since it solves a previous problem and adds another one (at least for me).

Comment 4 Fedora Update System 2013-08-02 03:37:51 UTC
gedit-latex-3.8.0-1.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 5 Bart Ratgers 2013-09-04 22:42:39 UTC
(In reply to Fedora Update System from comment #4)
> gedit-latex-3.8.0-1.fc19 has been pushed to the Fedora 19 stable repository.
> If problems still persist, please make note of it in this bug report.

I found that the problem still exist with the updated package:
Installaed packages
gedit.x86_64                                        2:3.8.3-1.fc19
gedit-collaboration.x86_64                          3.6.1-2.fc19
gedit-latex.x86_64                                  3.8.0-1.fc19
gedit-plugins.x86_64                                3.8.3-1.fc19

The same error messages after trying to activate the plugin:
Traceback (most recent call last):
  File "/usr/lib64/gedit/plugins/latex/__init__.py", line 39, in <module>
    from .windowactivatable import LaTeXWindowActivatable
  File "/usr/lib64/gedit/plugins/latex/windowactivatable.py", line 36, in <module>
    from .config import EDITOR_VIEWS, ACTIONS
  File "/usr/lib64/gedit/plugins/latex/config.py", line 26, in <module>
    from .latex.actions import LaTeXMenuAction, LaTeXNewAction, LaTeXChooseMasterAction, \
  File "/usr/lib64/gedit/plugins/latex/latex/actions.py", line 33, in <module>
    from .editor import LaTeXEditor
  File "/usr/lib64/gedit/plugins/latex/latex/editor.py", line 37, in <module>
    from .expander import LaTeXReferenceExpander
  File "/usr/lib64/gedit/plugins/latex/latex/expander.py", line 28, in <module>
    from .cache import LaTeXDocumentCache
  File "/usr/lib64/gedit/plugins/latex/latex/cache.py", line 111
    print self.__file.path
             ^
SyntaxError: invalid syntax

Comment 6 Griffin Milsap 2013-09-18 05:10:44 UTC
(In reply to Bart Ratgers from comment #5)
> The same error messages after trying to activate the plugin:
> Traceback (most recent call last):
>   File "/usr/lib64/gedit/plugins/latex/__init__.py", line 39, in <module>
>     from .windowactivatable import LaTeXWindowActivatable
>   File "/usr/lib64/gedit/plugins/latex/windowactivatable.py", line 36, in
> <module>
>     from .config import EDITOR_VIEWS, ACTIONS
>   File "/usr/lib64/gedit/plugins/latex/config.py", line 26, in <module>
>     from .latex.actions import LaTeXMenuAction, LaTeXNewAction,
> LaTeXChooseMasterAction, \
>   File "/usr/lib64/gedit/plugins/latex/latex/actions.py", line 33, in
> <module>
>     from .editor import LaTeXEditor
>   File "/usr/lib64/gedit/plugins/latex/latex/editor.py", line 37, in <module>
>     from .expander import LaTeXReferenceExpander
>   File "/usr/lib64/gedit/plugins/latex/latex/expander.py", line 28, in
> <module>
>     from .cache import LaTeXDocumentCache
>   File "/usr/lib64/gedit/plugins/latex/latex/cache.py", line 111
>     print self.__file.path
>              ^
> SyntaxError: invalid syntax

I'm seeing this same error with gedit 3.8.3 and gedit-latex 3.8.0-1

Comment 7 Daniel Bristot 2013-09-29 15:27:13 UTC
I'm seeing this same error with the gedit 3.8.3-1 and gedit-latex 3.8.0-1, on f19.i686.

But, I found a workaround.

In a old version of the file /usr/lib64/gedit/plugins/latex/latex/cache.py, from the package gedit-latex-3.2.1-1.fc16 on my other computer, the line "print self.__file.path" is not present, and it seems to be only a debug message that someone else forgot to remove, then, I just removed this line.

After this, I got the following error message:

Traceback (most recent call last):
  File "/usr/lib/gedit/plugins/latex/__init__.py", line 39, in <module>
    from .windowactivatable import LaTeXWindowActivatable
  File "/usr/lib/gedit/plugins/latex/windowactivatable.py", line 36, in <module>
    from .config import EDITOR_VIEWS, ACTIONS
  File "/usr/lib/gedit/plugins/latex/config.py", line 76, in <module>
    from .bibtex.editor import BibTeXEditor
  File "/usr/lib/gedit/plugins/latex/bibtex/editor.py", line 35, in <module>
    from ..job import Job, JobChangeListener
  File "/usr/lib/gedit/plugins/latex/job.py", line 25, in <module>
    import dbus
ImportError: No module named 'dbus'

To fix this, I install the package "python3-dbus", that now is in the version 1.1.1-5.fc19.i686.

And it works.

Comment 8 Sergio Pascual 2013-09-29 21:37:31 UTC
So we just need a 

Requires: python3-dbus in spec

and patch away the python2 print in cache.py

@nacho, I can do the update if you want

Comment 9 Ignacio Casal Quinteiro (nacho) 2013-09-30 07:20:51 UTC
Sergio: please feel free.

Comment 10 Fedora Update System 2013-09-30 11:43:37 UTC
gedit-latex-3.8.0-3.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/gedit-latex-3.8.0-3.fc20

Comment 11 Fedora Update System 2013-09-30 11:44:48 UTC
gedit-latex-3.8.0-3.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/gedit-latex-3.8.0-3.fc19

Comment 12 Fedora Update System 2013-10-01 02:02:43 UTC
Package gedit-latex-3.8.0-3.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing gedit-latex-3.8.0-3.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-17987/gedit-latex-3.8.0-3.fc19
then log in and leave karma (feedback).

Comment 13 Fedora Update System 2013-10-09 14:18:22 UTC
gedit-latex-3.8.0-3.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 14 Fedora Update System 2013-10-10 01:04:26 UTC
gedit-latex-3.8.0-3.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.