#4693 closed defect (fixed)
Exporting files doesn't create the files in the correct folder
Reported by: | Uwe Stöhr | Owned by: | lasgouttes |
---|---|---|---|
Priority: | high | Milestone: | 1.6.0 |
Component: | converters | Version: | 1.6.0svn |
Severity: | critical | Keywords: | regression |
Cc: | younes@…, syntheticpp@…, torbjorn.sund@…, hylkema@… |
Description
The problem occurs in trunk since around March 14 2008:
Open an existing LyX file and export it as e.g. PDF. But the PDF is not created
in the folder of the LyX file as expected. The file is only created in LyX's the
temp folder. So when closing LyX, the temp folder is deleted and also the
exported file.
What is broken is to copy the exported file from the temp folder where it is
generated to the folder of the LyX file.
This is a release blocker as LyX users won't get any output.
This bug only occurs on Windows - Stefan tested that it works fine on Mac:
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg137177.html
Can anybody confirm it on Linux?
Attachments (1)
Change History (85)
comment:1 by , 16 years ago
Keywords: | regression added |
---|---|
Milestone: | → 1.6.0 |
comment:2 by , 16 years ago
Component: | general → export |
---|
comment:3 by , 16 years ago
op_sys: | other → Windows XP |
---|
comment:5 by , 16 years ago
Cc: | added |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
This is fixed AFAICS.
Not for me, the PDF is still only generated in the temp folder and not moved to
the folder of the LyX file.
comment:6 by , 16 years ago
Weird...
What about other format (ps, html, dvi,etc)? Do you have the same problem? I
suspect some issue with your pdfview program or whatever the name is...
Abdel.
comment:7 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
What about other format (ps, html, dvi,etc)? Do you have the same problem?
The problem is the same, no matter what format I export, PS, DVI, other LyX formats...
comment:8 by , 16 years ago
Do you use Vista? I do too (very bad OS) but I have no problem. Also, are you
sure you have the full rights for the directory where your LyX file is? On
multple occasion Vista simply refused to move a file somewhere complaining about
user rights...
comment:9 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Do you use Vista?
No, XP, Win2000, and Win XP x64 - the latter one is a very good OS btw.
Also, are you sure you have the full rights for the directory where your LyX file is?
Yes, I can log in as admin and install to every directory. I played very long to fix this issue
without success.
But a as I said in the initial comment the problem appears from one day to another and I changed
nothing in my system I think.
comment:10 by , 16 years ago
Then the only way to fix it is to debug it. If you cannot use the debugger, try
first '-dbg files'. If that does not exhibits a problem, try to put some lyxerr
statement here and there in FileName.cpp in order to see where the problem is.
comment:11 by , 16 years ago
Resolution: | → invalid |
---|---|
Status: | reopened → closed |
For some odd reason the preferences file was not updates when reconfiguring. I
fixed this by reinstalling the complete beast and removing all of LyX's user
setting folders.
comment:12 by , 16 years ago
Resolution: | invalid |
---|---|
Status: | closed → reopened |
I finally found the bug:
You are not able to export a file when you don't have a preferences file. But
right after installing LyX you don't have and don't need it. So unless you
change the preferences to get a preferences file, this bug occur.
LyX 1.5 don't have this bug - you get output no matter if you have changed the
preferences or not.
This bug must have been introduces before March 14 2008.
comment:13 by , 16 years ago
I erased my user directory, checked that there is no preference file and I still
cannot reproduce the problem under Vista.
comment:14 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I erased my user directory, checked that there is no preference file and I still
cannot reproduce the problem under Vista.
I still can, also on a Vista Laptop PC of a collegue.
To reproduce assure that you don't have a preferences file in the "lyx16" folder in the user
directories (also for the other users on your PC). Also assure that you don't have a preferences
file in the installation folder of LyX 1.6svn.
I'll release a windows installer for alpha2 today. Please check this out under Vista - you should
see the bug.
comment:15 by , 16 years ago
To reproduce assure that you don't have a preferences file in the
"lyx16" folder in the user directories (also for the other users on
your PC).
That's what I did already.
Also assure that you don't have a preferences file in the
installation folder of LyX 1.6svn.
I use LyX in its develpment tree and there are none. So I suspect a bug in scons
install here...
Please try to launch LyX in its tree (potentially using -sysdir) without
installing it and then try to reproduce the bug again.
comment:16 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I use LyX in its develpment tree and there are none. So I suspect a bug in scons
install here...
Please try to launch LyX in its tree (potentially using -sysdir) without
installing it and then try to reproduce the bug again.
I uninstalled LyX 1.6svn, then I started LyX directly from its SVN tree, and can reproduce the bug:
I get no output when there is no preferences file. I also checked with -sysdir.
While doing this, I uncovered the crash #4791.
comment:17 by , 16 years ago
I got it now more exact: You get no output as long as you don't have a
preferences file that has a path given for
\tempdir_path
in the files section.
comment:18 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Fixed by the patch for #4815.
comment:19 by , 16 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Reopening, what I said in comment 15 is still true:
- copy the attached preferences file to LyX's installation folder
"Resources" (the folder where e.g. the CREDITS file is located)
Then File -> Export does nothing.
This is regression to LyX 1.5
comment:20 by , 16 years ago
Severity: | blocker → critical |
---|
comment:21 by , 16 years ago
I am tempted to mark this bug as invalid. The 'preferences' file should not be
copied in the Resource directory. This is a user file that should go in the user
directory. That is 'C:\Users\abdel\AppData\Roaming\lyx\preferences' under MS
Vista for example. I don't have a '\tempdir_path' tag in there and there is no
problem.
comment:23 by , 16 years ago
Uwe, please test and report.
Author: younes
Date: Mon Jun 9 15:05:24 2008
New Revision: 25207
URL: http://www.lyx.org/trac/changeset/25207
Log:
Hopefully fix #4918
Modified:
lyx-devel/trunk/src/LyX.cpp
lyx-devel/trunk/src/support/Package.cpp
lyx-devel/trunk/src/support/Package.h
Modified: lyx-devel/trunk/src/LyX.cpp
URL: http://www.lyx.org/trac/file/lyx-devel/trunk/src/LyX.cpp?rev=25207
==============================================================================
--- lyx-devel/trunk/src/LyX.cpp (original)
+++ lyx-devel/trunk/src/LyX.cpp Mon Jun 9 15:05:24 2008
@@ -846,7 +846,7 @@
if (document_path.exists() && document_path.isDirectory())
package().document_dir() = document_path;
- package().temp_dir() = createLyXTmpDir(FileName(lyxrc.tempdir_path));
+ package().set_temp_dir(createLyXTmpDir(FileName(lyxrc.tempdir_path)));
if (package().temp_dir().empty()) {
Alert::error(_("Could not create temporary directory"),
bformat(_("Could not create a temporary directory in\n"
Modified: lyx-devel/trunk/src/support/Package.cpp
URL: http://www.lyx.org/trac/file/lyx-devel/trunk/src/support/Package.cpp?rev=25207
==============================================================================
--- lyx-devel/trunk/src/support/Package.cpp (original)
+++ lyx-devel/trunk/src/support/Package.cpp Mon Jun 9 15:05:24 2008
@@ -159,6 +159,15 @@
<< "\ttemp_dir " << temp_dir().absFilename() << '\n'
<< "\thome_dir " << home_dir().absFilename() << '\n'
<< "</package>\n");
+}
+
+
+void Package::set_temp_dir(FileName const & temp_dir) const
+{
+ if (temp_dir.empty())
+ temp_dir_ = system_temp_dir_;
+ else
+ temp_dir_ = temp_dir;
}
Modified: lyx-devel/trunk/src/support/Package.h
URL: http://www.lyx.org/trac/file/lyx-devel/trunk/src/support/Package.h?rev=25207
==============================================================================
--- lyx-devel/trunk/src/support/Package.h (original)
+++ lyx-devel/trunk/src/support/Package.h Mon Jun 9 15:05:24 2008
@@ -116,7 +116,10 @@
- (Eg /tmp/lyx_tmpdir800nBI1z9 on *nix.)
- Can be reset by LyXRC. */
- FileName & temp_dir() const { return temp_dir_; }
+ @{
+ FileName const & temp_dir() const { return temp_dir_; }
+ void set_temp_dir(FileName const & temp_dir) const;
+ @}
/ Used when setting the user_support directory.
- Used also when expanding "~/" or contracting to "~/". (filetools.cpp)
comment:25 by , 16 years ago
The 'preferences' file should not be copied in the Resource directory. This is
a user file that should go in the user directory. That is
'C:\Users\abdel\AppData\Roaming\lyx\preferences' under MS Vista for example.
But this must be possible: At work we want to install LyX for all users of a
Computer, but we don't know at install time how man user account we have on a
computer and surely new accounts will be made. But LyX should be the same for
all users. So we detect e.g. in the Win installers if e.g. Inkscape is installed
and add entries for the SVG format to the preferences file in LyX's Resources
folder.
In LyX the rule is:
- when there is a preferences file in the user folder, use it
- when there is no preferences file in the user folder, use the one that is in
the resources folder
This assures that all users on a PC, also accounts that were created after LyX
has been installed, will start LyX with the same settings.
I don't have a '\tempdir_path' tag in there and there is no problem.
But THIS IS THE BUG! When I open my preferences file in the user folder and
delete there the existing \tempdir_path entry, I can no longer export. I
therefore thried to specify an empty path:
\tempdir_path ""
and foung #4918, but now also with an empty temp path I get no exports - the
\tempdir_path has to be specified to get any export and this is the bug.
If you can't reproduce this, please take attachment 2600 as your preferences
file in your user directory.
comment:26 by , 16 years ago
But this must be possible: At work we want to install LyX for all users of a
Computer, but we don't know at install time how man user account we have on a
computer and surely new accounts will be made. But LyX should be the same for
all users.
Then use 'lyxrc.dist'. 'preference' is for user preference, period!
I don't have a '\tempdir_path' tag in there and there is no problem.
But THIS IS THE BUG!
Did you try again?
When I open my preferences file in the user folder and
delete there the existing \tempdir_path entry, I can no longer export. I
therefore thried to specify an empty path:
\tempdir_path ""
and foung #4918,
Did you manage to reproduce #4918 with current trunk?
but now also with an empty temp path I get no exports - the
\tempdir_path has to be specified to get any export and this is the bug.
I don't know why you fiddle with this instead of letting LyX choose the
appropriate folder but anyway...
If you can't reproduce this, please take attachment 2600 as your preferences
file in your user directory.
Why do you think I made the commit above? Because I could reproduce the bug. Now
I can't because well, I fixed the bug. I wonder why I spend so much time on this
bug...
comment:27 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
But this must be possible: At work we want to install LyX for all users of a
Computer, but we don't know at install time how man user account we have on a
computer and surely new accounts will be made. But LyX should be the same for
all users.
Then use 'lyxrc.dist'. 'preference' is for user preference, period!
I'll try if this works. Why are you so enraged? I used the preferences setup since I started the LyX
Windows installer and this time JMarc offered me this method. Neverhteless, I'm open for new
approaches, but please accept that I shout wehn thing don't work that have been worked for years.
I don't have a '\tempdir_path' tag in there and there is no problem.
But THIS IS THE BUG!
Did you try again?
Yes, yesterday evening.
When I open my preferences file in the user folder and
delete there the existing \tempdir_path entry, I can no longer export. I
therefore thried to specify an empty path:
\tempdir_path ""
and foung #4918,
Did you manage to reproduce #4918 with current trunk?
#4918 is fixed, thanks.
but now also with an empty temp path I get no exports - the
\tempdir_path has to be specified to get any export and this is the bug.
I don't know why you fiddle with this instead of letting LyX choose the
appropriate folder but anyway...
I would, but as I wanted to set a preferences file in the resources folder, LyX takes it when there
is no preferences file in the user folder (as I want it but you not ;-) ), but as there is no temp
path specified there, no export is possible. But I cannot assume a tem folder at installation time.
Therefore I fiddled aoroud with this.
If you can't reproduce this, please take attachment 2600 as your preferences
file in your user directory.
Why do you think I made the commit above? Because I could reproduce the bug. Now
I can't because well, I fixed the bug. I wonder why I spend so much time on this
bug...
Well with using attachment 2600 as preferences file I still get this bug that I cannot export
anymore. Your commit fixed #4918 but not this one. I just report what I see and don't want to
make you raged.
comment:28 by , 16 years ago
I'll try if this works. Why are you so enraged?
Because you shout and because I keep repeating the same things without you
trying to understand.
I used the
preferences setup since I started the LyX Windows installer and this
time JMarc offered me this method.
Time to change it to lyxrc.dist then.
Neverhteless, I'm open for new
approaches, but please accept that I shout wehn thing don't work that
have been worked for years.
No, there's no excuse to shout. I don't think I am to blame for this bug but
even if I was, asking politely if I could fix it is the right way. Bugs appear
and go, a 'regression' is the devil thing you want it to appear. Anyway, that is
not the right place to discuss that.
specified there, no export is possible. But I cannot assume a tem
folder at installation time.
I think you always can assume a temp folder with my recent changes.
comment:29 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Neverhteless, I'm open for new
approaches, but please accept that I shout when thing don't work that
have been worked for years.
No, there's no excuse to shout. I don't think I am to blame for this bug
What's going on? I haven't blamed anybody for this. With shout I mean reporting a bug as critical or
regression and eventually also reporting it on the list.
comment:30 by , 16 years ago
Concerning lyxrc.dist and preference files. I still think that:
- lyxrc.dist is for the preparation of the installer
- a preferences can be provided in lyxdir as a way for the local site maintainer
to provide sensible defaults (paths...) for a given site.
It does not seem to me however that the current discussion is about that. How is
this file business related to having or not a \temp_dir setting?
comment:31 by , 16 years ago
I am not sure I agree with JMarc but I apologize to Uwe for my epidermic reactions.
Concerning the temppath issue, I cannot reproduce the bug but I did not try to
put the preference file in lydir. I'd be surprised if that changed anything.
comment:32 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I am not sure I agree with JMarc but I apologize to Uwe for my epidermic reactions.
No problem.
I now tried to use a modified lyxrc.dist file to set e.g. the menu language at install time, but no
matter what I write to the lyxrc.dist file, LyX then crashes immediately when started.
When e.g. this is the content of lyxrc.dist, LyX crashes:
\gui_language "ngerman"
Concerning the temppath issue, I cannot reproduce the bug but I did not try to
put the preference file in lydir. I'd be surprised if that changed anything.
I still can, just use a preferences file that doesn't has a temp folder specification.
comment:33 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
When e.g. this is the content of lyxrc.dist, LyX crashes:
\gui_language "ngerman"
Aha, this is a new bug: I can use every preferences statement also in lyxrc.dist, but whenever I add
the gui_language statement, LyX crashes immediately.
comment:34 by , 16 years ago
Besides the crash when using gui_language in lyxrc.dist this bug is still there:
- I now don't deliver or touch any preferences file.
- I deleted my folder C:\Documents and Settings\<username>\Application Data\lyx16
Now we are on the state of a system where LyX 1.6 has not been installed before.
- Now start LyX, create a new document and export it as PDF.
Result: No PDF is exported.
It first works when you open and close the preferences dialog as then a
preferences file is created defining automatically the correct temp folder for
the current user. This automatic definition is made in LyX 1.5 automatically
when first starting LyX, now the user has to call first the preferencs dialog so
that a preferences file is created.
(I can alternatively define a temp folder in lyxrc.dist to make export work, but
I doesn't know the temp folder at install time.)
comment:35 by , 16 years ago
I erased all preference files, have no lyxrc.dist file, I didn't launch the
prefs dialog, and still I can't reproduce this bug.
comment:36 by , 16 years ago
Could you tell me with '-dbg init' if 'LyX tmp dir' is correctly set to the
system default temp directory?
comment:37 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I erased all preference files, have no lyxrc.dist file, I didn't launch the
prefs dialog, and still I can't reproduce this bug.
Please try to:
- erase the Documents and setting\<username>\Application Data\lyx16 folder
- install LyX 1.6beta4 using my installer
- try to export a document -> doesn't work
It seems that you are running LyX from your SVN tree, but normal users don't have this. If you still
can't reproduce, please install LyX using my beta4 installer on another computer, to see that this
bug is really a blocker for Windows.
Could you tell me with '-dbg init' if 'LyX tmp dir' is correctly set to the
system default temp directory?
I will do this later, but note that there is no system wide default temp directory. Every user has
its own temp directory.
comment:38 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Subject: Re: Exporting files doesn't create the files in the correct
folder
I erased all preference files, have no lyxrc.dist file, I didn't launch the
prefs dialog, and still I can't reproduce this bug.
Please try to:
- erase the Documents and setting\<username>\Application Data\lyx16 folder
I always do that before testing. FYI, on vista this is
C:\Users\<username>\AppData\Roaming\lyx16
- install LyX 1.6beta4 using my installer
I used joost beta3 installer (copying the compiled binary and a few
other thing into the installation directory).
- try to export a document -> doesn't work
It seems that you are running LyX from your SVN tree,
No, see above.
but normal users don't have this. If you still
can't reproduce, please install LyX using my beta4 installer on another computer, to see that this
bug is really a blocker for Windows.
I don't have another computer :-)
Could you tell me with '-dbg init' if 'LyX tmp dir' is correctly set to the
system default temp directory?
I will do this later, but note that there is no system wide default temp directory. Every user has
its own temp directory.
I never side "system wide".
Abdel.
comment:39 by , 16 years ago
Severity: | critical → blocker |
---|
Could you tell me with '-dbg init' if 'LyX tmp dir' is correctly set to the
system default temp directory?
Here it is:
C:\Program Files (x86)\LyX 1.6.0beta4\bin>lyx -dbg init
Setting debug level to init
Debugging `init' (Program initialisation)
D:\LyXSVN\lyx-devel\src\support\Package.cpp(308): Checking whether LyX is run in
place... no
D:\LyXSVN\lyx-devel\src\support\Package.cpp(161): <package>
binary_dir C:/Program Files (x86)/LyX 1.6.0beta4/bin/
system_support C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/
build_support
user_support C:/Documents and Settings/usti/Application Data/lyx16/
locale_dir C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/locale
/
document_dir C:/Documents and Settings/usti/My Documents
temp_dir C:/DOCUME~1/usti/LOCALS~1/Temp
home_dir C:/Documents and Settings/usti
</package>
D:\LyXSVN\lyx-devel\src\LyX.cpp(419): Initializing LyX::init...
D:\LyXSVN\lyx-devel\src\LyX.cpp(877): About to read lyxrc.dist...
D:\LyXSVN\lyx-devel\src\LyX.cpp(881): Found in C:/Program Files (x86)/LyX 1.6.0b
eta4/bin/../Resources/lyxrc.dist
D:\LyXSVN\lyx-devel\src\LyX.cpp(877): About to read lyxrc.defaults...
D:\LyXSVN\lyx-devel\src\LyX.cpp(881): Found in C:/Documents and Settings/usti/Ap
plication Data/lyx16/lyxrc.defaults
D:\LyXSVN\lyx-devel\src\LyX.cpp(877): About to read lyxrc.dist...
D:\LyXSVN\lyx-devel\src\LyX.cpp(881): Found in C:/Program Files (x86)/LyX 1.6.0b
eta4/bin/../Resources/lyxrc.dist
D:\LyXSVN\lyx-devel\src\LyX.cpp(877): About to read preferences...
D:\LyXSVN\lyx-devel\src\LyX.cpp(887): Not found.
D:\LyXSVN\lyx-devel\src\LyX.cpp(912): About to read encodings and unicodesymbols
...
D:\LyXSVN\lyx-devel\src\LyX.cpp(895): About to read languages...
D:\LyXSVN\lyx-devel\src\LyX.cpp(731): Reading layouts...
D:\LyXSVN\lyx-devel\src\LyX.cpp(779): LyX tmp dir: `C:/DOCUME~1/usti/LOCALS~1/Te
mp/lyx_tmpdir2532a00544'
D:\LyXSVN\lyx-devel\src\LyX.cpp(781): Reading session information '.lyx/session'
...
D:\LyXSVN\lyx-devel\src\LyX.cpp(421): Initializing LyX::init...done
lyx: Disabling LyX socket.
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1361): About to read de
fault...
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1382): Found default in
C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/ui/default.ui
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1361): About to read st
dmenus.inc...
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1382): Found stdmenus.i
nc in C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/ui/stdmenus.inc
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1361): About to read st
dcontext.inc...
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1382): Found stdcontext
.inc in C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/ui/stdcontext.inc
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1361): About to read st
dtoolbars.inc...
D:\LyXSVN\lyx-devel\src\frontends\qt4\GuiApplication.cpp(1382): Found stdtoolbar
s.inc in C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/ui/stdtoolbars.i
nc
So LyX recognizes correctly the temp folder and use it internally. But when I
want to export a document to PDF or whatever, The PDF file is only created in
this temp folder but not in the folder of the LyX file.
This bug is for me a blocker since LyX cannot be installed correctly this way. I
don't understand why you cannot reproduce it as my beta4 installer does nothing
special than to copy the needed LyX files to a directory. Setting up the
application folder etc. is done when LyX is first started.
Btw. your recent work fixed this issue, thanks:
When e.g. this is the content of lyxrc.dist, LyX crashes:
\gui_language "ngerman"
comment:41 by , 16 years ago
Other users cannot reproduce the bug:
I have by the way no problem to export to pdf (pdflatex or ps2pdf) on Windows.
Best regards,
Olivier
comment:42 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I have by the way no problem to export to pdf (pdflatex or ps2pdf) on Windows.
Who is this? As I told, the problem does not occur when the user has at least once opened the
preferences dialog aft installing LyX 1.6. So could you please ask Olivier that he delete his
"C:\Documents and Settings\>username>\Application Data\lyx16" folder and try to export a file.
OK, now could you please try with '-dbg files'?
- first LyX is reconfigured as I deleted the lyx16 folder
- then I get this:
D:\LyXSVN\lyx-devel\src\support\filetools.cpp(322): createTmpDir: tempdir=`C:/DO
CUME~1/usti/LOCALS~1/Temp'
createTmpDir: mask=`lyx_tmpdir'
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(401): Temporary file `C:/DOCUME~1/u
sti/LOCALS~1/Temp/lyx_tmpdir564a02648' created.
lyx: Disabling LyX socket.
Checksumming "C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/examples/de
/splash.lyx" lasted 0 ms.
Checksumming "C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/images/buff
er-view_dvi.png" lasted 0 ms.
D:\LyXSVN\lyx-devel\src\insets\InsetGraphics.cpp(451): Comparing C:/Program File
s (x86)/LyX 1.6.0beta4/bin/../Resources/images/buffer-view_dvi.png and C:/DOCUME
~1/usti/LOCALS~1/Temp/lyx_tmpdir564a02648/lyx_tmpbuf0/0CProgram_Filesx86Ly
X_1_6_0beta4_binResources_images_buffer-view_dvi.png
Checksumming "C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/images/buff
er-view_dvi.png" lasted 0 ms.
So LyX created a temp folder. When exporting a file (not viewing) I get after the LaTeX runs:
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir564a0
2648/lyx_tmpbuf0/splash.tex" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir564a0
2648/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images_
buffer-view_dvi.png" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir564a0
2648/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images_
buffer-view_dvi.png" lasted 0 ms.
So as said before, the PDF is created in the temporary temp folder but not in the folder where the
LyX file is. I still have to use the preferences dialog, change there something, restart LyX. Then
the PDF is also correctly copied from the temporary temp folder to the folder where the LyX file is
located.
comment:43 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
So as said before, the PDF is created in the temporary temp folder
but not in the folder where the LyX file is. I still have to use the
preferences dialog, change there something, restart LyX. Then the PDF
is also correctly copied from the temporary temp folder to the folder
where the LyX file is located.
OK, I committed some debug code in there. When I do the same as you, I
get this at the end when exporting to pdf:
..\..\trunk\src\Converter.cpp(342): Converting from ps to pdf
..\..\trunk\src\Converter.cpp(401): Calling ps2pdf13 "splash.ps"
"splash.pdf"
..\..\..\trunk\src\support\FileName.cpp(169): Copying
C:/devel/lyx/trunk/lib/examples/fr/splash.pdf
and this if I export to pdf2:
..\..\..\trunk\src\support\FileName.cpp(169): Copying
C:/devel/lyx/trunk/lib/examples/fr/splash.pdf
Could you please try again to see if FileName::copyTo() is correctly
called in your system.
comment:45 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
OK, I committed some debug code in there. When I do the same as you, I
get this at the end when exporting to pdf:
..\..\trunk\src\Converter.cpp(342): Converting from ps to pdf
..\..\trunk\src\Converter.cpp(401): Calling ps2pdf13 "splash.ps"
"splash.pdf"
..\..\..\trunk\src\support\FileName.cpp(169): Copying
C:/devel/lyx/trunk/lib/examples/fr/splash.pdf
When I now use -dbg files,lyxrc, I get the same as with -dbg files, only this:
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(169): Copying C:/DOCUME~1/usti/LOCA
LS~1/Temp/lyx_tmpdir2396a01036/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta
4_binResources_images_buffer-view_dvi.png
D:\LyXSVN\lyx-devel\src\Converter.cpp(342): Converting from pdflatex to pdf2
D:\LyXSVN\lyx-devel\src\Converter.cpp(368): Running pdflatex
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2396a
01036/lyx_tmpbuf0/splash.tex" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2396a
01036/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images
_buffer-view_dvi.png" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2396a
01036/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images
_buffer-view_dvi.png" lasted 0 ms.
When I use the first time the preferences dialog, LyX does this actions:
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(297): isDirWriteable: C:/Documents
and Settings/usti/Application Data/lyx16/bind/
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(402): Temporary file `C:/Documents
and Settings/usti/Application Data/lyx16/bindlyxwritetest2396a01036' created.
D:\LyXSVN\lyx-devel\src\LyXRC.cpp(364): Reading istream...
Then I need to restart LyX to be able to export to the correct folder. And now I get when I start
LyX instead of
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(402): Temporary file `C:/DOCUME~1/u
sti/LOCALS~1/Temp/lyx_tmpdir2480a02296' created.
this
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(402): Temporary file `C:/Documents
and Settings/usti/Local Settings/Temp/lyx_tmpdir2424a02712' created.
So the created temporary temp dir is no longer
C:/DOCUME~1/usti/LOCALS~1/Temp/
but now correctly this
C:/Documents and Settings/usti/Local Settings/Temp/
and the export work:
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(169): Copying C:/Documents and Sett
ings/usti/Local Settings/Temp/lyx_tmpdir2424a02712/lyx_tmpbuf0/0CProgram_Files
x86LyX_1_6_0beta4_binResources_images_buffer-view_dvi.png
D:\LyXSVN\lyx-devel\src\Converter.cpp(342): Converting from pdflatex to pdf2
D:\LyXSVN\lyx-devel\src\Converter.cpp(368): Running pdflatex
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2424a
02712/lyx_tmpbuf0/splash.tex" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2424a
02712/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images
_buffer-view_dvi.png" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/Temp/lyx_tmpdir2424a
02712/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images
_buffer-view_dvi.png" lasted 0 ms.
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(169): Copying C:/Program Files (x86
)/LyX 1.6.0beta4/bin/../Resources/examples/de/splash.pdf
So it seems that the DOS style like temp folder path name is the problem
comment:46 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
So it seems that the DOS style like temp folder path name is the problem
Looks lit it yes. Good detective work!
comment:47 by , 16 years ago
I am probably a bit late (bugzilla was not working yesterday), but here is my
answer to Uwe's question in comment 40, related to comment 39 which quoted my
message to the user's mailing list:
After deleting my "Application Data\lyx16" directory, I cannot export to pdf any
more.
When I uninstalled the beta3, I chose not to delete the preferences, so it
probably explains why I could export fine with beta4.
comment:48 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
After deleting my "Application Data\lyx16" directory, I cannot export to pdf any
more.
When I uninstalled the beta3, I chose not to delete the preferences, so it
probably explains why I could export fine with beta4.
Thanks for this info. I'm happy that I'm now not the only one seeing this problem.
comment:49 by , 16 years ago
Please try again.
Author: younes
Date: Tue Jul 22 19:45:40 2008
New Revision: 25809
URL: http://www.lyx.org/trac/changeset/25809
Log:
tentatively fix #4693
The problem stems I guess from the use of from_local8bit().
comment:50 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Please try again.
Doesn't help ;-(
comment:51 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Doesn't help ;-(
Could you give me analyse with '-dbg files,lyxrc' one more time please?
comment:52 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
OK, now I understand... This is due to the mess in FileName::tempName()!
comment:53 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Could you give me analyse with '-dbg files,lyxrc' one more time please?
Wait a minute please before committing a new patch, I want to test out an idea.
comment:54 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
OK, now I understand... This is due to the mess in FileName::tempName()!
So in contrast to me, you got an idea. I only found this one and running out of ideas:
http://www.lyx.org/trac/changeset/25810
comment:55 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Uwe Stöhr schrieb:
Wait a minute please before committing a new patch, I want to test out
an idea.
I failed. Please continue as you seem to have the right idea.
regards Uwe
comment:56 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Please try again.
comment:57 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Please try again.
No success, I still get:
D:\LyXSVN\lyx-devel\src\support\filetools.cpp(322): createTmpDir: tempdir=`C:/DO
CUME~1/usti/LOCALS~1/Temp'
createTmpDir: mask=`lyx_tmpdir'
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(371): Temporary file `C:/DOCUME~1/u
sti/LOCALS~1/lyx_tmpdir.qHp904' created.
lyx: Disabling LyX socket.
Checksumming "D:/Download/splash.lyx" lasted 0 ms.
Checksumming "C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/images/buff
er-view_dvi.png" lasted 0 ms.
D:\LyXSVN\lyx-devel\src\insets\InsetGraphics.cpp(451): Comparing C:/Program File
s (x86)/LyX 1.6.0beta4/bin/../Resources/images/buffer-view_dvi.png and C:/DOCUME
~1/usti/LOCALS~1/lyx_tmpdir.qHp904/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0
beta4_binResources_images_buffer-view_dvi.png
Checksumming "C:/Program Files (x86)/LyX 1.6.0beta4/bin/../Resources/images/buff
er-view_dvi.png" lasted 0 ms.
D:\LyXSVN\lyx-devel\src\support\FileName.cpp(193): Copying C:/DOCUME~1/usti/LOCA
LS~1/lyx_tmpdir.qHp904/lyx_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_bin_
_Resources_images_buffer-view_dvi.png
D:\LyXSVN\lyx-devel\src\Converter.cpp(342): Converting from pdflatex to pdf2
D:\LyXSVN\lyx-devel\src\Converter.cpp(368): Running pdflatex
Checksumming "C:/Documents and Settings/usti/Local Settings/lyx_tmpdir.qHp904/ly
x_tmpbuf0/splash.tex" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/lyx_tmpdir.qHp904/ly
x_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images_buffer-
view_dvi.png" lasted 0 ms.
Checksumming "C:/Documents and Settings/usti/Local Settings/lyx_tmpdir.qHp904/ly
x_tmpbuf0/0CProgram_Filesx86LyX_1_6_0beta4_binResources_images_buffer-
view_dvi.png" lasted 0 ms.
And nothing is copied. The temp folder name is the same ugly one.
There must be something else in our temp path handling that works in LyX 1.5 but not in trunk.
I'll try to check this.
comment:58 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I'll check this out
I want to add some debug output but couldn't find where in LyX 1.5 branch the file copy action is done.
comment:59 by , 16 years ago
Uwe, at this point only you can debug this as I think this issue is XP only.
Using CMake is very easy, everything is explained in "INSTALL.cmake".
comment:61 by , 16 years ago
I just had an idea:
We use QDir::tempPath() for the temp path settings. It could well be that this
is a problem of Qt and not Windows. Uwe, which version of Qt do you use? If that
is 4.3 could you please try with Qt4.4?
comment:62 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
We use QDir::tempPath() for the temp path settings. It could well be that this
is a problem of Qt and not Windows. Uwe, which version of Qt do you use? If that
is 4.3 could you please try with Qt4.4?
I use Qt 4.3.3. I have not upgraded to Qt 4.4 because I supply the Windows installer and there are
some known Qt 4.4 bugs. So I decided for me not to upgrade before Qt 4.4.1 comes out. But OK, I'll
give it a try when I find the time.
I had a look again at the docs:
http://doc.trolltech.com/4.3/qtemporaryfile.html
So Qt 4.3 also provides QDir::tempPath() and this works fine in 1.5 branch.
comment:63 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
I use Qt 4.3.3. I have not upgraded to Qt 4.4 because I supply the
Windows installer and there are some known Qt 4.4 bugs. So I decided
for me not to upgrade before Qt 4.4.1 comes out. But OK, I'll give it
a try when I find the time.
It's up to you. We are not going to block the release because of this bug.
I had a look again at the docs:
http://doc.trolltech.com/4.3/qtemporaryfile.html So Qt 4.3 also
provides QDir::tempPath() and this works fine in 1.5 branch.
No, 1.5 don't use it.
Abdel.
comment:64 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
It's up to you. We are not going to block the release because of this bug.
When I see the same using Qt 4.4.0, then it is still a blocker.
comment:65 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
So I decided
for me not to upgrade before Qt 4.4.1 comes out. But OK, I'll give it
a try when I find the time.
It's up to you. We are not going to block the release because of this bug.
I now use Qt 4.4.1 but this bug is still exactly the same :-(
comment:66 by , 16 years ago
I've news on this bug:
I had two Windows system, one with XP and one with Vista, both the 32bit
versions. I installed on both LyX 1.6.0rc1 using my installer.
Result:
Vista: This bug doesn't appear
XP: This bug appears
I'm totally lost. The bug is real for Win XP and 2000 and it's a critical one
there. I don't have a clue why it works fine on Vista.
I also installed LyX 1.5.6 on both PCs and this bug doesn't occur on both
machines. So there must be something new in the temp path code that doesn't work
with Win XP ans Win 2000.
This behavior is independent from Qt 4.3.3 or newer.
Could it be that we now use a function that calls something that is new in the
Windows API for Vista?
comment:67 by , 16 years ago
Severity: | blocker → critical |
---|
resetting severity, since this bug does not match our definition of "blocker"
here:
http://bugzilla.lyx.org/bug_status.html#severity
"Blocks development and/or testing work"
(i.e., "blocker" does not mean: blocks the release).
comment:68 by , 16 years ago
Could it be related to non-Ascii characters in the windows user name? I have an
& in my user name, and I see this bug with 1.6.0rc2, on XP.
Gady
comment:69 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
Could it be related to non-Ascii characters in the windows user name? I have an
& in my user name, and I see this bug with 1.6.0rc2, on XP.
I don't have non-ASCII characters in my user name or path. But the path where LyX is installed is by
default
C:\Program Files\LyX 1.6.0
or
C:\Program Files (x86)\LyX 1.6.0rc3
So perhaps the spaces are a problem. How is it on Vista?
comment:71 by , 16 years ago
Subject: Re: Exporting files doesn't create the files in the correct
folder
please try again with latest rev (26669)
It doesn't fix it. I still have to do a change in the preferences to generate the preferences file,
then restart LyX and then it works.
comment:72 by , 16 years ago
comment:73 by , 16 years ago
Cc: | added |
---|
Additional Info: When I start LyX I now get this:
D:\LyXSVN\lyx-devel\src\support\filetools.cpp(328): LyX could not create
temporary directory in C:/Documents and Settings/usti/Local Settings/Temp'
This file hasn't been changed since 23/07/2008, s this miht be a hint for the
reason of the temp folder problems.
comment:74 by , 16 years ago
Hmm, I get this error message quite randomly and it tells me nothing about the
reason for this bug, so you can ignore my last comment.
comment:75 by , 16 years ago
Until we know a better way to get the long path name
I've checked in the patch:
comment:76 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
comment:77 by , 16 years ago
Cc: | added |
---|
comment:79 by , 16 years ago
blocked: | → 5362 |
---|
comment:80 by , 16 years ago
blocked: | 5362 → , torbjorn.sund@telenor.com |
---|
comment:82 by , 11 years ago
I'm not sure why this is closed. This bug has been a problem for a long time both on windows and on Linux. I have a linux mint 15 cinnamon installation and am using lyx 2.0.3. Any export to pdf via any mechanism will not be written to the directory that contains the document source, but will be written to the /tmp file directory.
This has been true of linux mint, linux ubuntu, versions of fedora and every windows version I've tried. I did verify that actually altering my preferences and saving it, seems to have at least temporarily enabled the exporting of pdf to my document source directory. I've seen that ability disappear after a while however.
comment:83 by , 11 years ago
Hey SevenThunders, I have never had this issue before (Windows 7), exported files are created in the directory of the LyX file. I suppose you could upgrade to LyX 2.0.6
comment:84 by , 10 years ago
Component: | export → converters |
---|
This works fine on Linux. So it looks to be Windows only. And it even works here
with spaces in the pathname, so it's not that issue.