emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Suspected bug with LaTeX export: the pdf does not open
@ 2018-08-18  4:52 Alain.Cochard
  2018-08-18 19:34 ` Robert Klein
  0 siblings, 1 reply; 10+ messages in thread
From: Alain.Cochard @ 2018-08-18  4:52 UTC (permalink / raw)
  To: emacs-orgmode


Hello.

I read in the manual:

   'C-c C-e l o'
   Export as LaTeX file and convert it to PDF, then open the PDF
   using the default viewer.

I have the file ~/tmp/scr.org which contains only 

   * head 
   blah

and file ~/.emacs.debug which contains only

   (add-to-list 'load-path "/home/cochard/Org/Coch-git/org-mode/lisp")
   (find-file "~/tmp/scr.org")

I do:

   emacs -Q -l ~/.emacs.debug

and then:

   C-c C-e l o

The compilation is OK and the pdf file is created, but not open.
With 'M-x buffer-menu' one can see that the only buffers are:

   .   scr.org                  13 Org              ~/tmp/scr.org
	   *scratch*               191 Lisp Interaction 
	%* *Messages*              367 Messages         
	%* *Org PDF LaTeX O...    4577 Compilation      

I have:

   Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
   3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
   Org mode version 9.1.13 (release_9.1.13-894-gf79545 @
   /home/cochard/Org/Coch-git/org-mode/lisp/)

By contrast, with simply

   emacs -Q

which corresponds to

   Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
   3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
   Org-mode version 8.2.10 (release_8.2.10 @
   /usr/share/emacs/24.5/lisp/org/)
 
when visiting the scr.org file and typing 'C-c C-e l o', the frame
splits into 2 windows and the pdf appears in one of them, as I'd
expect.  The buffers are

   .   scr.org                  13 Org              ~/tmp/scr.org
	%  scr.pdf               50938 DocView          ~/tmp/scr.pdf
	   *scratch*               191 Lisp Interaction 
	%* *Messages*              283 Messages         
	 * *Org PDF LaTeX O...    4702 Fundamental      

Regards







-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-18  4:52 Suspected bug with LaTeX export: the pdf does not open Alain.Cochard
@ 2018-08-18 19:34 ` Robert Klein
  2018-08-18 20:59   ` Alain.Cochard
  0 siblings, 1 reply; 10+ messages in thread
From: Robert Klein @ 2018-08-18 19:34 UTC (permalink / raw)
  To: Alain.Cochard; +Cc: emacs-orgmode

Hi,

On Sat, 18 Aug 2018 06:52:19 +0200
Alain.Cochard@unistra.fr wrote:

> Hello.
> 
> I read in the manual:
> 
>    'C-c C-e l o'
>    Export as LaTeX file and convert it to PDF, then open the PDF
>    using the default viewer.
> 
> I have the file ~/tmp/scr.org which contains only 
> 
>    * head 
>    blah
> 
> and file ~/.emacs.debug which contains only
> 
>    (add-to-list 'load-path "/home/cochard/Org/Coch-git/org-mode/lisp")
>    (find-file "~/tmp/scr.org")
> 
> I do:
> 
>    emacs -Q -l ~/.emacs.debug
> 
> and then:
> 
>    C-c C-e l o
> 
> The compilation is OK and the pdf file is created, but not open.
> With 'M-x buffer-menu' one can see that the only buffers are:
> 
>    .   scr.org                  13 Org              ~/tmp/scr.org
> 	   *scratch*               191 Lisp Interaction 
> 	%* *Messages*              367 Messages         
> 	%* *Org PDF LaTeX O...    4577 Compilation      
> 
> I have:
> 
>    Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
>    3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
>    Org mode version 9.1.13 (release_9.1.13-894-gf79545 @
>    /home/cochard/Org/Coch-git/org-mode/lisp/)
> 
> By contrast, with simply
> 
>    emacs -Q
> 
> which corresponds to
> 
>    Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
>    3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
>    Org-mode version 8.2.10 (release_8.2.10 @
>    /usr/share/emacs/24.5/lisp/org/)
>  
> when visiting the scr.org file and typing 'C-c C-e l o', the frame
> splits into 2 windows and the pdf appears in one of them, as I'd
> expect.  The buffers are
> 
>    .   scr.org                  13 Org              ~/tmp/scr.org
> 	%  scr.pdf               50938 DocView          ~/tmp/scr.pdf
> 	   *scratch*               191 Lisp Interaction 
> 	%* *Messages*              283 Messages         
> 	 * *Org PDF LaTeX O...    4702 Fundamental      
> 



I tried to reproduce this, but can't.  I tested org-mode master using
Emacs 24.4, 24.5, 25.1, 25.2, 25.3, and 26.1, and the only difference I
find is that in Emacs 24.x an external viewer (gv) is used instead of
Emacs' DocView mode.

Your Org version, master (which is three commits ahead of your
version), maint, and the bundled versions (9.1.9 for Emacs 26.1, 8.2.10
for the others) behave the same.

Do you have any information in the *Messages* buffer which might help?

Best regards
Robert

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-18 19:34 ` Robert Klein
@ 2018-08-18 20:59   ` Alain.Cochard
  2018-08-19  2:31     ` Tim Cross
  2018-08-20 15:50     ` Nick Dokos
  0 siblings, 2 replies; 10+ messages in thread
From: Alain.Cochard @ 2018-08-18 20:59 UTC (permalink / raw)
  To: Robert Klein; +Cc: emacs-orgmode


Hi Robert, thanks much for your time.

Robert Klein writes on Sat 18 Aug 2018 21:34:

 > Do you have any information in the *Messages* buffer which might
 > help?

For the configuration that opens the pdf, that is:

   Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
   3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
   Org-mode version 8.2.10 (release_8.2.10 @
   /usr/share/emacs/24.5/lisp/org/)

the *Messages* buffer contains:

   For information about GNU Emacs and the GNU system, type C-h C-a.
   Saving file /home/cochard/tmp/scr.tex...
   Wrote /home/cochard/tmp/scr.tex
   Processing LaTeX file ./scr.tex...
   Process completed.
   Type C-c C-c to toggle between editing or viewing the document.

For the configuration that does not open the pdf:

   Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
   3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
   Org mode version 9.1.13 (release_9.1.13-894-gf79545 @
   /home/cochard/Org/Coch-git/org-mode/lisp/)

the *Messages* buffer contains:

   For information about GNU Emacs and the GNU system, type C-h C-a.
   Saving file /home/cochard/tmp/scr.tex...
   Wrote /home/cochard/tmp/scr.tex
   Processing LaTeX file scr.tex...
   PDF file produced.
   Running /usr/bin/xdg-open /home/cochard/tmp/scr.pdf...done

This does not ring any bell for me, but maybe it will for you or
someone else.

In view of your results, I have now tried with emacs 26 and master:

   Emacs : GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version
   3.18.9) of 2018-05-30 Package: Org mode version 9.1.13
   (release_9.1.13-894-gf79545 @
   /home/cochard/Org/Coch-git/org-mode/lisp/)

and the pdf does open as expected.  The *Messages* buffer contains

   For information about GNU Emacs and the GNU system, type C-h C-a.
   Saving file /home/cochard/tmp/scr.tex...
   Wrote /home/cochard/tmp/scr.tex
   Processing LaTeX file scr.tex...
   PDF file produced.

So I guess this suggests that there is a problem with my emacs 24.5.1,
which is the default on my Fedora 23 distribution.  (NB: The emacs
26.1 used above is built from source and I can't make it fully work
for regular use, i.e., with my normal .emacs.)

Regards

-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-18 20:59   ` Alain.Cochard
@ 2018-08-19  2:31     ` Tim Cross
  2018-08-19  4:21       ` Alain.Cochard
  2018-08-20 15:50     ` Nick Dokos
  1 sibling, 1 reply; 10+ messages in thread
From: Tim Cross @ 2018-08-19  2:31 UTC (permalink / raw)
  To: alain.cochard; +Cc: emacs-orgmode, Robert Klein


Given the problem appears to only occur with older setups which are
using an external PDF viewer, he problem might be with the xdg settings
on the system. The line

   Running /usr/bin/xdg-open /home/cochard/tmp/scr.pdf...done

might be worth more investigation. What program is xdg using to open PDF
files? What happens if you try to run that viewer manually on the PDF
file?

Tim

Alain.Cochard@unistra.fr writes:

> Hi Robert, thanks much for your time.
>
> Robert Klein writes on Sat 18 Aug 2018 21:34:
>
>  > Do you have any information in the *Messages* buffer which might
>  > help?
>
> For the configuration that opens the pdf, that is:
>
>    Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
>    3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
>    Org-mode version 8.2.10 (release_8.2.10 @
>    /usr/share/emacs/24.5/lisp/org/)
>
> the *Messages* buffer contains:
>
>    For information about GNU Emacs and the GNU system, type C-h C-a.
>    Saving file /home/cochard/tmp/scr.tex...
>    Wrote /home/cochard/tmp/scr.tex
>    Processing LaTeX file ./scr.tex...
>    Process completed.
>    Type C-c C-c to toggle between editing or viewing the document.
>
> For the configuration that does not open the pdf:
>
>    Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
>    3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
>    Org mode version 9.1.13 (release_9.1.13-894-gf79545 @
>    /home/cochard/Org/Coch-git/org-mode/lisp/)
>
> the *Messages* buffer contains:
>
>    For information about GNU Emacs and the GNU system, type C-h C-a.
>    Saving file /home/cochard/tmp/scr.tex...
>    Wrote /home/cochard/tmp/scr.tex
>    Processing LaTeX file scr.tex...
>    PDF file produced.
>    Running /usr/bin/xdg-open /home/cochard/tmp/scr.pdf...done
>
> This does not ring any bell for me, but maybe it will for you or
> someone else.
>
> In view of your results, I have now tried with emacs 26 and master:
>
>    Emacs : GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version
>    3.18.9) of 2018-05-30 Package: Org mode version 9.1.13
>    (release_9.1.13-894-gf79545 @
>    /home/cochard/Org/Coch-git/org-mode/lisp/)
>
> and the pdf does open as expected.  The *Messages* buffer contains
>
>    For information about GNU Emacs and the GNU system, type C-h C-a.
>    Saving file /home/cochard/tmp/scr.tex...
>    Wrote /home/cochard/tmp/scr.tex
>    Processing LaTeX file scr.tex...
>    PDF file produced.
>
> So I guess this suggests that there is a problem with my emacs 24.5.1,
> which is the default on my Fedora 23 distribution.  (NB: The emacs
> 26.1 used above is built from source and I can't make it fully work
> for regular use, i.e., with my normal .emacs.)
>
> Regards


--
Tim Cross

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-19  2:31     ` Tim Cross
@ 2018-08-19  4:21       ` Alain.Cochard
  2018-09-23  8:41         ` Alain.Cochard
  0 siblings, 1 reply; 10+ messages in thread
From: Alain.Cochard @ 2018-08-19  4:21 UTC (permalink / raw)
  To: Tim Cross; +Cc: emacs-orgmode, alain.cochard, Robert Klein

Tim Cross writes on Sun 19 Aug 2018 12:31:
 > 
 > Given the problem appears to only occur with older setups which are
 > using an external PDF viewer, he problem might be with the xdg settings
 > on the system. The line
 > 
 >    Running /usr/bin/xdg-open /home/cochard/tmp/scr.pdf...done
 > 
 > might be worth more investigation. What program is xdg using to open PDF
 > files? What happens if you try to run that viewer manually on the PDF
 > file?

When running the command 

   /usr/bin/xdg-open /home/cochard/tmp/scr.pdf

from a standard linux terminal or a shell terminal within emacs (M-x
shell) the file is open with evince.  However nothing happens if doing
it from an eshell terminal (M-x eshell).

Also if I visit (C-x C-f) the file in emacs, it is displayed properly;
the modeline says '(DocView)'

If I add the line 

   (setq process-connection-type nil)

to my minimal .emacs, then, upon 'C-c C-e l o', the file does open,
although not within emacs -- but with evince.  So it does not fully
solve the problem, but it is already a rather decent workaround for
me.  Thanks a lot!

-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-18 20:59   ` Alain.Cochard
  2018-08-19  2:31     ` Tim Cross
@ 2018-08-20 15:50     ` Nick Dokos
  2018-08-20 16:27       ` Alain.Cochard
  1 sibling, 1 reply; 10+ messages in thread
From: Nick Dokos @ 2018-08-20 15:50 UTC (permalink / raw)
  To: emacs-orgmode

Alain.Cochard@unistra.fr writes:

> ...
> So I guess this suggests that there is a problem with my emacs 24.5.1,
> which is the default on my Fedora 23 distribution.  (NB: The emacs
> 26.1 used above is built from source and I can't make it fully work
> for regular use, i.e., with my normal .emacs.)
>

If the above is not a typo, quite apart from PDF problems, you have
security problems: the current Fedora is 28, Fedora 26 is either end-of-life
already or about to be shortly, and Fedora 23 is obsolete and possibly
dangerous. Please consider upgrading.

-- 
Nick

"There are only two hard problems in computer science: cache
invalidation, naming things, and off-by-one errors." -Martin Fowler

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-20 15:50     ` Nick Dokos
@ 2018-08-20 16:27       ` Alain.Cochard
  2018-08-20 16:59         ` Nick Dokos
  0 siblings, 1 reply; 10+ messages in thread
From: Alain.Cochard @ 2018-08-20 16:27 UTC (permalink / raw)
  To: Nick Dokos; +Cc: emacs-orgmode

Nick Dokos writes on Mon 20 Aug 2018 11:50:

 > [...] you have security problems: the current Fedora is 28, Fedora
 > 26 is either end-of-life already or about to be shortly, and Fedora
 > 23 is obsolete and possibly dangerous. Please consider upgrading.

Thanks.  Yes, 23 is obsolete.  But what do you mean "possibly
dangerous"?  What are the risks?

In addition to the unexpected problems that regularly occur (to me
anyway) at each distribution change and which take time to fix, I know
-- considering the latest emacs version -- that I have a high risk of
facing a dreadful problem for me (coupling Xfce workspaces and emacs
'other-frame') that I don't even know how to fix.  So generally I
"upgrade" when I change my computer.  That would be different if there
existed an easy and robust way to downgrade...

Regards




-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-20 16:27       ` Alain.Cochard
@ 2018-08-20 16:59         ` Nick Dokos
  0 siblings, 0 replies; 10+ messages in thread
From: Nick Dokos @ 2018-08-20 16:59 UTC (permalink / raw)
  To: emacs-orgmode

Alain.Cochard@unistra.fr writes:

> Nick Dokos writes on Mon 20 Aug 2018 11:50:
>
>  > [...] you have security problems: the current Fedora is 28, Fedora
>  > 26 is either end-of-life already or about to be shortly, and Fedora
>  > 23 is obsolete and possibly dangerous. Please consider upgrading.
>
> Thanks.  Yes, 23 is obsolete.  But what do you mean "possibly
> dangerous"?  What are the risks?
>

I'm pretty sure you have not had security updates for it for a while: see

   https://fedoramagazine.org/fedora-23-end-of-life/

so you are running with unpatched bugs since Dec. 2016. Some of these
bugs *might* be remotely exploitable. I would not use such a machine
to e.g. check my bank account from a public place - *I* would not use it
from a private place over WiFi either - maybe over hardwired ethernet
but that would depend on other factors; but different people
tolerate the possibility of such problems differently: you will have
to decide what to do in your case. I hope this information can help
you make an informed decision.

-- 
Nick

"There are only two hard problems in computer science: cache
invalidation, naming things, and off-by-one errors." -Martin Fowler

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-08-19  4:21       ` Alain.Cochard
@ 2018-09-23  8:41         ` Alain.Cochard
  2018-09-24  3:37           ` Alain.Cochard
  0 siblings, 1 reply; 10+ messages in thread
From: Alain.Cochard @ 2018-09-23  8:41 UTC (permalink / raw)
  To: emacs-orgmode; +Cc: Tim Cross, Robert Klein

Alain.Cochard@unistra.fr writes on Sun 19 Aug 2018 06:21:

 > If I add the line 
 > 
 >    (setq process-connection-type nil)
 > 
 > to my minimal .emacs, then, upon 'C-c C-e l o', the file does open,
 > although not within emacs -- but with evince.  So it does not fully
 > solve the problem, but it is already a rather decent workaround for
 > me.  Thanks a lot!

But this line causes a problem with 'M-x shell'.

Instead of the regular bash prompt:

   [cochard@frac tmp]$

I get

   bash: cannot set terminal process group (-1): Inappropriate ioctl
   for device
   bash: no job control in this shell
   [cochard@frac tmp]$ 

Then, at least bash completion and 'su' don't work; so rather
useless.

Any idea to cure the cure?

Regards

-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Suspected bug with LaTeX export: the pdf does not open
  2018-09-23  8:41         ` Alain.Cochard
@ 2018-09-24  3:37           ` Alain.Cochard
  0 siblings, 0 replies; 10+ messages in thread
From: Alain.Cochard @ 2018-09-24  3:37 UTC (permalink / raw)
  To: emacs-orgmode; +Cc: Tim Cross, Robert Klein


PS: I realize that it is not directly related to org-mode, so I have
sent a message to help-gnu-emacs.

-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2018-09-24  3:37 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-18  4:52 Suspected bug with LaTeX export: the pdf does not open Alain.Cochard
2018-08-18 19:34 ` Robert Klein
2018-08-18 20:59   ` Alain.Cochard
2018-08-19  2:31     ` Tim Cross
2018-08-19  4:21       ` Alain.Cochard
2018-09-23  8:41         ` Alain.Cochard
2018-09-24  3:37           ` Alain.Cochard
2018-08-20 15:50     ` Nick Dokos
2018-08-20 16:27       ` Alain.Cochard
2018-08-20 16:59         ` Nick Dokos

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).