GNU bug report logs - #35310
11.91; AUCTeX/Evince: server does not start, poor direct search, inverse search does not work

Previous Next

Package: auctex;

Reported by: Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com>

Date: Thu, 18 Apr 2019 01:03:01 UTC

Severity: normal

Tags: notabug

Found in version 11.91

Done: Ikumi Keita <ikumi <at> ikumi.que.jp>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 35310 in the body.
You can then email your comments to 35310 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Thu, 18 Apr 2019 01:03:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-auctex <at> gnu.org. (Thu, 18 Apr 2019 01:03:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
To: bug-auctex <at> gnu.org
Subject: 11.91; AUCTeX/Evince: server does not start, poor direct search,
 inverse search does not work
Date: Wed, 17 Apr 2019 19:58:07 -0500
*** Summary ***
1) Evince server does not start, so each "C-c C-v" issued opens a new
Evince instance, capturing the keyboard focus and bloating the screen.
2) Direct search works partially, it merely searches for the page and
not the specific line.
3) Inverse search simply does not work.

*** Note ***
I have copy-pasted a basic configuration to start a server and
activate direct/inverse search according to this:
https://www.gnu.org/software/auctex/manual/auctex/I_002fO-Correlation.html
I have also posted this message here:
https://bugs.launchpad.net/ubuntu/+source/auctex/+bug/1824257

*** What is to be expected ***
1) Open a .tex file with Emacs/AUCTeX.
2) Compile (C-c C-c).
3) View pdf output (C-c C-v).
>> An Evince server for that file is started.
>> Evince opens the pdf file.
>> Focus is still on Emacs instance.
3) Move to some line (in Emacs).
4) View pdf output (C-c C-v).
>> No new Evince instance is opened for that file.
>> The current Evince instance moves to the specific line corresponding to the cursor position in Emacs.
>> Focus is still on Emacs instance.
5) On Evince "control+left click" some line.
>> Emacs moves to the specific line corresponding to the pointed line in Evince.
>> Emacs instance captures the focus.

*** What happens ***
1) Open a .tex file with Emacs/AUCTeX.
2) Compile (C-c C-c).
3) View pdf output (C-c C-v).
>> No Evince server is started.
>> Evince opens the pdf file.
>> Focus is captured by Evince.
3) Move to some line (in Emacs).
4) View pdf output (C-c C-v).
>> A new Evince instance is opened for that file.
>> The new Evince instance moves to the page (not the line) corresponding to the cursor position in Emacs.
>> Focus is captured by the new Evince instance.
5) On Evince "control+left click" some line.
>> Nothing happens and Winter Is Coming.

*** init.el ***
(custom-set-variables
 ;; custom-set-variables was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 '(inhibit-startup-screen t)
 '(TeX-source-correlate-method (quote synctex))
 '(TeX-source-correlate-mode t)
 '(TeX-source-correlate-start-server t))



Ubuntu release: Ubuntu 18.04.2 LTS (fully updated as per today)
Emacs  : GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
 of 2017-09-22, modified by Debian
Package: 11.91

current state:
==============
(setq
 AUCTeX-date "2017-07-24"
 window-system 'x
 LaTeX-version "2e"
 TeX-style-path '("/var/lib/auctex/emacs25/"
  "/usr/share/emacs/site-lisp/auctex/style"
  "/home/myuser/.emacs.d/auctex/auto"
  "/home/myuser/.emacs.d/auctex/style" "auto" "style")
 TeX-auto-save nil
 TeX-parse-self nil
 TeX-master t
 TeX-command-list '(("TeX"
     "%(PDF)%(tex) %(file-line-error) %(extraopts) %`%S%(PDFout)%(mode)%' %t"
     TeX-run-TeX nil
     (plain-tex-mode ams-tex-mode texinfo-mode) :help
     "Run plain TeX")
    ("LaTeX" "%`%l%(mode)%' %t" TeX-run-TeX nil
     (latex-mode doctex-mode) :help "Run LaTeX")
    ("Makeinfo" "makeinfo %(extraopts) %t" TeX-run-compile nil
     (texinfo-mode) :help "Run Makeinfo with Info output")
    ("Makeinfo HTML" "makeinfo %(extraopts) --html %t"
     TeX-run-compile nil (texinfo-mode) :help
     "Run Makeinfo with HTML output")
    ("AmSTeX" "amstex %(PDFout) %(extraopts) %`%S%(mode)%' %t"
     TeX-run-TeX nil (ams-tex-mode) :help "Run AMSTeX")
    ("ConTeXt"
     "%(cntxcom) --once --texutil %(extraopts) %(execopts)%t"
     TeX-run-TeX nil (context-mode) :help "Run ConTeXt once")
    ("ConTeXt Full" "%(cntxcom) %(extraopts) %(execopts)%t"
     TeX-run-TeX nil (context-mode) :help
     "Run ConTeXt until completion")
    ("BibTeX" "bibtex %s" TeX-run-BibTeX nil t :help
     "Run BibTeX")
    ("Biber" "biber %s" TeX-run-Biber nil t :help "Run Biber")
    ("View" "%V" TeX-run-discard-or-function t t :help
     "Run Viewer")
    ("Print" "%p" TeX-run-command t t :help "Print the file")
    ("Queue" "%q" TeX-run-background nil t :help
     "View the printer queue" :visible TeX-queue-command)
    ("File" "%(o?)dvips %d -o %f " TeX-run-dvips t t :help
     "Generate PostScript file")
    ("Dvips" "%(o?)dvips %d -o %f " TeX-run-dvips nil t :help
     "Convert DVI file to PostScript")
    ("Dvipdfmx" "dvipdfmx %d" TeX-run-dvipdfmx nil t :help
     "Convert DVI file to PDF with dvipdfmx")
    ("Ps2pdf" "ps2pdf %f" TeX-run-ps2pdf nil t :help
     "Convert PostScript file to PDF")
    ("Glossaries" "makeglossaries %s" TeX-run-command nil t
     :help "Run makeglossaries to create glossary file")
    ("Index" "makeindex %s" TeX-run-index nil t :help
     "Run makeindex to create index file")
    ("upMendex" "upmendex %s" TeX-run-index t t :help
     "Run upmendex to create index file")
    ("Xindy" "texindy %s" TeX-run-command nil t :help
     "Run xindy to create index file")
    ("Check" "lacheck %s" TeX-run-compile nil (latex-mode)
     :help "Check LaTeX file for correctness")
    ("ChkTeX" "chktex -v6 %s" TeX-run-compile nil (latex-mode)
     :help "Check LaTeX file for common mistakes")
    ("Spell" "(TeX-ispell-document \"\")" TeX-run-function nil
     t :help "Spell-check the document")
    ("Clean" "TeX-clean" TeX-run-function nil t :help
     "Delete generated intermediate files")
    ("Clean All" "(TeX-clean t)" TeX-run-function nil t :help
     "Delete generated intermediate and output files")
    ("Other" "" TeX-run-command t t :help
     "Run an arbitrary command")
    )
 )




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Sun, 21 Apr 2019 13:37:02 GMT) Full text and rfc822 format available.

Message #8 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Ikumi Keita <ikumi <at> ikumi.que.jp>
To: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91;
 AUCTeX/Evince: server does not start, poor direct search, inverse
 search does not work
Date: Sun, 21 Apr 2019 22:36:01 +0900
Hi Cédric,

>>>>> Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com> writes:
> *** What happens ***
> 1) Open a .tex file with Emacs/AUCTeX.
> 2) Compile (C-c C-c).
> 3) View pdf output (C-c C-v).
>>> No Evince server is started.
>>> Evince opens the pdf file.
>>> Focus is captured by Evince.
> 3) Move to some line (in Emacs).
> 4) View pdf output (C-c C-v).
>>> A new Evince instance is opened for that file.
>>> The new Evince instance moves to the page (not the line) corresponding to the cursor position in Emacs.
>>> Focus is captured by the new Evince instance.
> 5) On Evince "control+left click" some line.
>>> Nothing happens and Winter Is Coming.

It seems that your emacs does not support dbus, or it actually does but
is not aware of that.  What are the return values of `(featurep
'dbusbind)' and `(TeX-evince-dbus-p "gnome" "evince")'?  I.e., what
responses are displayed in echo area when you place the cursor just
after the closing parenthes above and type C-x C-e?

> Ubuntu release: Ubuntu 18.04.2 LTS (fully updated as per today)
> Emacs  : GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
>  of 2017-09-22, modified by Debian
> Package: 11.91

Your emacs and AUCTeX are a bit out of date.  The customize option
`TeX-view-evince-keep-focus' was introduced in AUCTeX 11.92, so your
following expectation will be satisfied by that option after your emacs
begins to support dbus:

> *** What is to be expected ***
...
> 4) View pdf output (C-c C-v).
...
>>> Focus is still on Emacs instance.

By the way,
>>> No Evince server is started.
>>> An Evince server for that file is started.
What do you mean by "Evince server"?  If you are talking about the
"server" in `TeX-source-correlate-start-server', then it refers to
"emacs server", which accepts connection requests from emacsclient.

Regards,
Ikumi Keita




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Sun, 21 Apr 2019 22:37:01 GMT) Full text and rfc822 format available.

Message #11 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
To: Ikumi Keita <ikumi <at> ikumi.que.jp>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91; AUCTeX/Evince: server does not start, poor
 direct search, inverse search does not work
Date: Sun, 21 Apr 2019 17:36:37 -0500
Hi Ikumi,

thank you for your interest. Indeed it is something D-Bus related. I
was using a script I found many years ago on the web but it stopped
working. I therefore changed to another script,
https://gist.github.com/dandrake/2297447, which didn't work either. It
gives me the following error:

D-Bus error: "Unit org.gnome.Evince.service not found."

I then saw that Emacs/AUCTeX has currently built-in direct/inverse
search, which I tried and, as I mentioned, neither works (for me).

Coming back to your questions, these are the outputs I get when I
issue the commands you suggested.

Just after launching Emacs.

(featurep 'dbusbind) C-x C-e
t
(TeX-evince-dbus-p "gnome" "evince") C-x C-e
Debugger entered--Lisp error: (void-function TeX-evince-dbus-p)
  (TeX-evince-dbus-p "gnome" "evince")
  eval((TeX-evince-dbus-p "gnome" "evince") nil)
  elisp--eval-last-sexp(nil)
  eval-last-sexp(nil)
  funcall-interactively(eval-last-sexp nil)
  call-interactively(eval-last-sexp nil nil)
  command-execute(eval-last-sexp)

Just after opening a .tex file.

(featurep 'dbusbind) C-x C-e
t
(TeX-evince-dbus-p "gnome" "evince") C-x C-e
nil

I have tried to install emacs26 and auctex12, with no success.

With respect to the term "server", I don't know exactly who runs the
server. As far as I know, Emacs initiates a particular "evinced"
instance, which is a server for Evince,
https://emacs.stackexchange.com/questions/41633/dbus-error-when-running-tex-evince-sync-view.
Isn't it?

I appreciate much the help.

Regards,
Cédric




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Mon, 22 Apr 2019 13:31:01 GMT) Full text and rfc822 format available.

Message #14 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Ikumi Keita <ikumi <at> ikumi.que.jp>
To: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91;
 AUCTeX/Evince: server does not start, poor direct search, inverse
 search does not work
Date: Mon, 22 Apr 2019 22:30:17 +0900
Hi Cédric,

>>>>> Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com> writes:
> Just after opening a .tex file.

> (featurep 'dbusbind) C-x C-e
> t
> (TeX-evince-dbus-p "gnome" "evince") C-x C-e
> nil

Thanks, then emacs itself supports dbus but AUCTeX isn't ready to use it
for some reason.

> I was using a script I found many years ago on the web but it stopped
> working. I therefore changed to another script,
> https://gist.github.com/dandrake/2297447, which didn't work either. It
> gives me the following error:

> D-Bus error: "Unit org.gnome.Evince.service not found."

Hmm.  It looks like that your system does have working dbus.  Maybe the
interface which AUCTeX is using has changed due to, say, the upgrade of
Ubuntu?  Sorry, I'm not familiar with dbus nor Ubuntu, so I'm afraid
that I cannot be of your help anymore.
Are there anyone out there who knows dbus well and is willing to find
out what's going on?

Regards,
Ikumi Keita




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Tue, 23 Apr 2019 06:16:01 GMT) Full text and rfc822 format available.

Message #17 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Ikumi Keita <ikumi <at> ikumi.que.jp>
Cc: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>, 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91;
 AUCTeX/Evince: server does not start, poor direct search, inverse
 search does not work
Date: Tue, 23 Apr 2019 15:15:47 +0900
Hi Cédric,

>>>>> Ikumi Keita <ikumi <at> ikumi.que.jp> writes:
>> I was using a script I found many years ago on the web but it stopped
>> working. I therefore changed to another script,
>> https://gist.github.com/dandrake/2297447, which didn't work either. It
>> gives me the following error:

>> D-Bus error: "Unit org.gnome.Evince.service not found."

> Hmm.  It looks like that your system does have working dbus.

I might be wrong.  What do you get when you issue a command
"dbus-monitor" in terminal like xterm?  I got the following result:
----------------------------------------------------------------------
signal time=1555999845.737831 sender=org.freedesktop.DBus -> destination=:1.135 serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string ":1.135"
signal time=1555999845.738007 sender=org.freedesktop.DBus -> destination=:1.135 serial=4 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameLost
   string ":1.135"
----------------------------------------------------------------------
You will get similar result if you have working dbus.

Regards,
Ikumi Keita




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Tue, 23 Apr 2019 16:10:01 GMT) Full text and rfc822 format available.

Message #20 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
To: Ikumi Keita <ikumi <at> ikumi.que.jp>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91; AUCTeX/Evince: server does not start, poor
 direct search, inverse search does not work
Date: Tue, 23 Apr 2019 11:09:20 -0500
Hi Ikumi,

I do get a similar result. D-Bus is working, so as you said, it is
some problem with AUCTeX's interface.

I'll investigate.

Regards,
Cédric




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Tue, 23 Apr 2019 17:40:01 GMT) Full text and rfc822 format available.

Message #23 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
To: Ikumi Keita <ikumi <at> ikumi.que.jp>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91; AUCTeX/Evince: server does not start, poor
 direct search, inverse search does not work
Date: Tue, 23 Apr 2019 12:39:22 -0500
BTW, what is the output you get when issuing `(TeX-evince-dbus-p
"gnome" "evince")'?




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Tue, 23 Apr 2019 18:19:01 GMT) Full text and rfc822 format available.

Message #26 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
To: Ikumi Keita <ikumi <at> ikumi.que.jp>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91; AUCTeX/Evince: server does not start, poor
 direct search, inverse search does not work
Date: Tue, 23 Apr 2019 13:17:42 -0500
Solved. It seems some Ubuntu package installed Evince through Flatpak,
which does not communicate with D-Bus.

Thank you very much Ikumi for your insight.




Information forwarded to bug-auctex <at> gnu.org:
bug#35310; Package auctex. (Wed, 24 Apr 2019 08:46:02 GMT) Full text and rfc822 format available.

Message #29 received at 35310 <at> debbugs.gnu.org (full text, mbox):

From: Ikumi Keita <ikumi <at> ikumi.que.jp>
To: Cédric Martínez Campos
 <cedricmartinezcampos <at> gmail.com>
Cc: 35310 <at> debbugs.gnu.org
Subject: Re: bug#35310: 11.91;
 AUCTeX/Evince: server does not start, poor direct search, inverse
 search does not work
Date: Wed, 24 Apr 2019 17:45:51 +0900
>>>>> Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com> writes:
> Solved. It seems some Ubuntu package installed Evince through Flatpak,
> which does not communicate with D-Bus.

> Thank you very much Ikumi for your insight.

You're welcome.  I'll close this bug.

Bye,
Ikumi Keita




Added tag(s) notabug. Request was from Ikumi Keita <ikumi <at> ikumi.que.jp> to control <at> debbugs.gnu.org. (Wed, 24 Apr 2019 08:47:01 GMT) Full text and rfc822 format available.

bug closed, send any further explanations to 35310 <at> debbugs.gnu.org and Cédric Martínez Campos <cedricmartinezcampos <at> gmail.com> Request was from Ikumi Keita <ikumi <at> ikumi.que.jp> to control <at> debbugs.gnu.org. (Wed, 24 Apr 2019 08:47:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 22 May 2019 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 334 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.