Suddenly some commands stopped working, Specifically Label Based on Current Word / Selection… and "Citation (Ref-TeX Style)"
In both cases I get the following error message (off course with different header).
Failure running “Label Based on Current Word / Selection…”.
/Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:19:in `initialize': No such file or directory - JUR11-Permission.tex (Errno::ENOENT) from /Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:19:in `open' from /Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:19:in `options' from /Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:39:in `master' from /Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:56:in `get_labels' from Label Based on Current Word / Selection…:8
Also I have noticed a different behaviour when clicking the button in the output window. The commands are executed but no message appears in the output window.
All the best
Guido
On May 27, 2013, at 19:44, Guido Governatori gvdgdo@gmail.com wrote:
Suddenly some commands stopped working […] Failure running “Label Based on Current Word / Selection…”.
/Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:19:in `initialize': No such file or directory - JUR11-Permission.tex (Errno::ENOENT)
Could it be that you have TM_LATEX_MASTER set to ‘JUR11-Permission.tex’? Does this master file exist? If it does, is it set via a relative or absolute path? If the former, that might be what changed, since the command’s working directory has changed (I haven’t looked closer at the LaTeX bundle to see if it resolves relative paths via the project directory or current working directory).
Also, what version of TM (nightly builds)?
Also I have noticed a different behaviour when clicking the button in the output window. The commands are executed but no message appears in the output window.
A more detailed step-by-step would be appreciated here.
On 31/05/2013, at 11:26 AM, Allan Odgaard mailinglist@textmate.org wrote:
On May 27, 2013, at 19:44, Guido Governatori gvdgdo@gmail.com wrote:
Suddenly some commands stopped working […] Failure running “Label Based on Current Word / Selection…”.
/Users/guido/Library/Application Support/TextMate/Managed/Bundles/LaTeX.tmbundle/Support/lib/LaTeXUtils.rb:19:in `initialize': No such file or directory - JUR11-Permission.tex (Errno::ENOENT)
Could it be that you have TM_LATEX_MASTER set to ‘JUR11-Permission.tex’? Does this master file exist? If it does, is it set via a relative or absolute path? If the former, that might be what changed, since the command’s working directory has changed (I haven’t looked closer at the LaTeX bundle to see if it resolves relative paths via the project directory or current working directory).
I have TM_LATEX_MASTER is set to a master file with relative path. If I use an absolute path (or the variable is not set) the problem disappears.
There is another difference. If I use \ref{} and then call the command (with the caret between the curly brackets), then I get the following error:
Label Based on Current Word / Selection…:9: invalid regular expression; there's no previous pattern, to which '{' would define cardinality at 1: /{}/ (RegexpError)
It used to work with previous versions,
Similarly if I call the command with \ref{s} I get the full list of labels not only those one starting with "s".
Also, what version of TM (nightly builds)?
2.0-alpha.9427
Also I have noticed a different behaviour when clicking the button in the output window. The commands are executed but no message appears in the output window.
A more detailed step-by-step would be appreciated here.
Compile a latex file with cmd-r (the output window appears the log of the compilation (as usual) click the "Run bib" button at the bottom of the output window. Nothing visible happens (however the related bibtex/biber command is executed) click the "Re-Run pdflatex" button at the bottom of the output window. Nothing visible happens (however, the latex file is compiled).
The problem with the "Rub bib" is that one does not know when the process terminates (to re-run pdflatex), and whether it is successful or not. The problem with the "Re-run pdflatex" is that one does not see the warning of the compilation.
All the best
Guido
On May 31, 2013, at 11:36, Guido Governatori gvdgdo@gmail.com wrote:
[…] Could it be that you have TM_LATEX_MASTER set to ‘JUR11-Permission.tex’? Does this master file exist? If it does, is it set via a relative or absolute path? […]
I have TM_LATEX_MASTER is set to a master file with relative path. If I use an absolute path (or the variable is not set) the problem disappears.
OK, for now you can set it like this (.tm_properties in your project):
TM_LATEX_MASTER = "$CWD/JUR11-Permission.tex"
Here $CWD is a plcaeholder for the folder containing the .tm_properties file.
I am not sure if relative paths were fully supported in the past, for example if you had a project like:
chapters/intro.tex master.tex
And set TM_LATEX_MASTER to ‘master.tex’ and built with ‘intro.tex’ open, then I think it would have failed, as ‘master.tex’ would be resolved against the folder of ‘intro.tex’.
There is another difference. If I use \ref{} and then call the command (with the caret between the curly brackets), then I get the following error: […] It used to work with previous versions
Sounds like the same issue that this commit solves (but for another command) https://github.com/textmate/latex.tmbundle/commit/f95d2b89d1a030145e768743bb...
Though see my comment about this probably being fixed in a wrong way.
Also I have noticed a different behaviour when clicking the button in the output window. The commands are executed but no message appears in the output window.
A more detailed step-by-step would be appreciated here.
Compile a latex file […]
Thanks for the additional info, I have tracked down the problematic commit and should have a fix for next build.