Latex-workshop: "Problems" window mapping issues to wrong source file for multi-file documents

Created on 18 Feb 2018  Â·  4Comments  Â·  Source: James-Yu/LaTeX-Workshop

Description

I'm using a multi-file template (Masters/Doctoral Thesis from http://www.LaTeXTemplates.com) and compiling using pdftex+bibtex+pdftex+pdftex. Everything is working great, apart from the fact that the problems window maps any issue to the first chapter file that has any warnings, even if the actual warning relates to a different file.

How to reproduce

  1. Create a multi-file document with 3 chapters.
  2. Add to chapter1.tex and chapter3.tex some text that causes warnings.
  3. Compile
  4. Open the Problems window.

Expected behavior

Warnings displayed for Chapter1.tex and Chapter3.tex

Actual behavior

Warnings in Chapter3.tex displayed as if they were found in Chapter1.tex.

The actual warnings from Chapter1.tex are not displayed at all.

Here's one of the warnings that was actually in Chapter3.tex (same run as in the compile log further down):

file: 'file:///c%3A/Git/Priv/phd/template/Chapters/Chapter1.tex'
severity: ''
message: 'Overfull \hbox (2.589pt too wide) []\T1/ppl/m/n/10.95 W ra-mach prowad-zonych prac oraz w kon-tek�-cie wyko-rzysty-wanych tech-nologii 
'
at: '44,1'
source: 'LaTeX'
code: 'undefined'

Log messages

Compiler Output

This is pdfTeX, Version 3.14159265-2.6-1.40.18 (TeX Live 2017/W32TeX) (preloaded format=pdflatex)
 \write18 enabled.
entering extended mode
(c:/Git/Priv/phd/template/main.tex
LaTeX2e <2017-04-15>
Babel <3.17> and hyphenation patterns for 84 language(s) loaded.
(./MastersDoctoralThesis.cls
Document Class: MastersDoctoralThesis 2016/11/22 v1.5 LaTeXTemplates.com
(c:/texlive/2017/texmf-dist/tex/latex/etoolbox/etoolbox.sty)
(c:/texlive/2017/texmf-dist/tex/latex/l3packages/xparse/xparse.sty
(c:/texlive/2017/texmf-dist/tex/latex/l3kernel/expl3.sty
(c:/texlive/2017/texmf-dist/tex/latex/l3kernel/expl3-code.tex)
(c:/texlive/2017/texmf-dist/tex/latex/l3kernel/l3pdfmode.def)))
(c:/texlive/2017/texmf-dist/tex/latex/base/book.cls
Document Class: book 2014/09/29 v1.4h Standard LaTeX document class
(c:/texlive/2017/texmf-dist/tex/latex/base/bk11.clo))
(c:/texlive/2017/texmf-dist/tex/generic/babel/babel.sty
(c:/texlive/2017/texmf-dist/tex/generic/babel/switch.def)
(c:/texlive/2017/texmf-dist/tex/generic/babel-english/english.ldf
(c:/texlive/2017/texmf-dist/tex/generic/babel/babel.def
(c:/texlive/2017/texmf-dist/tex/generic/babel/switch.def)
(c:/texlive/2017/texmf-dist/tex/generic/babel/txtbabel.def))))
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrbase.sty
(c:/texlive/2017/texmf-dist/tex/latex/graphics/keyval.sty)
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrlfile.sty))
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrhack.sty
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrkbase.sty)
(c:/texlive/2017/texmf-dist/tex/latex/xpatch/xpatch.sty))
(c:/texlive/2017/texmf-dist/tex/latex/setspace/setspace.sty)
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/setspace.hak)
(c:/texlive/2017/texmf-dist/tex/latex/tools/longtable.sty)
(c:/texlive/2017/texmf-dist/tex/latex/siunitx/siunitx.sty
(c:/texlive/2017/texmf-dist/tex/latex/amsmath/amstext.sty
(c:/texlive/2017/texmf-dist/tex/latex/amsmath/amsgen.sty))
(c:/texlive/2017/texmf-dist/tex/latex/tools/array.sty)
(c:/texlive/2017/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty)
(c:/texlive/2017/texmf-dist/tex/latex/translator/translator.sty))
(c:/texlive/2017/texmf-dist/tex/latex/graphics/graphicx.sty
(c:/texlive/2017/texmf-dist/tex/latex/graphics/graphics.sty
(c:/texlive/2017/texmf-dist/tex/latex/graphics/trig.sty)
(c:/texlive/2017/texmf-dist/tex/latex/graphics-cfg/graphics.cfg)
(c:/texlive/2017/texmf-dist/tex/latex/graphics-def/pdftex.def)))
(c:/texlive/2017/texmf-dist/tex/latex/booktabs/booktabs.sty)
(c:/texlive/2017/texmf-dist/tex/latex/caption/caption.sty
(c:/texlive/2017/texmf-dist/tex/latex/caption/caption3.sty)
(c:/texlive/2017/texmf-dist/tex/latex/caption/ltcaption.sty))
(c:/texlive/2017/texmf-dist/tex/latex/xcolor/xcolor.sty
(c:/texlive/2017/texmf-dist/tex/latex/graphics-cfg/color.cfg))
(c:/texlive/2017/texmf-dist/tex/latex/geometry/geometry.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/ifpdf.sty)
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/ifvtex.sty)
(c:/texlive/2017/texmf-dist/tex/generic/ifxetex/ifxetex.sty))
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrlayer-scrpage.sty
(c:/texlive/2017/texmf-dist/tex/latex/koma-script/scrlayer.sty))
1: chapter
1: chapter
1: section
) (c:/texlive/2017/texmf-dist/tex/latex/base/inputenc.sty
(c:/texlive/2017/texmf-dist/tex/latex/base/utf8.def
(c:/texlive/2017/texmf-dist/tex/latex/base/t1enc.dfu)
(c:/texlive/2017/texmf-dist/tex/latex/base/ot1enc.dfu)
(c:/texlive/2017/texmf-dist/tex/latex/base/omsenc.dfu)))
(c:/texlive/2017/texmf-dist/tex/latex/base/fontenc.sty
(c:/texlive/2017/texmf-dist/tex/latex/base/t1enc.def))
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/mathpazo.sty)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/biblatex.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/infwarerr.sty)
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/ifluatex.sty)
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/ltxcmds.sty))
(c:/texlive/2017/texmf-dist/tex/latex/oberdiek/kvoptions.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/kvsetkeys.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/etexcmds.sty)))
(c:/texlive/2017/texmf-dist/tex/latex/logreq/logreq.sty
(c:/texlive/2017/texmf-dist/tex/latex/logreq/logreq.def))
(c:/texlive/2017/texmf-dist/tex/latex/base/ifthen.sty)
(c:/texlive/2017/texmf-dist/tex/latex/url/url.sty)
(c:/texlive/2017/texmf-dist/tex/generic/xstring/xstring.sty
(c:/texlive/2017/texmf-dist/tex/generic/xstring/xstring.tex))
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/blx-dm.def)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/blx-compat.def)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/blx-bibtex.def

Package biblatex Warning: Using fall-back BibTeX(8) backend:
(biblatex)                functionality may be reduced/unavailable.

) (c:/texlive/2017/texmf-dist/tex/latex/biblatex/biblatex.def)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/blx-natbib.def)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/bbx/authoryear.bbx
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/bbx/standard.bbx))
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/biblatex.cfg))
(c:/texlive/2017/texmf-dist/tex/latex/csquotes/csquotes.sty
(c:/texlive/2017/texmf-dist/tex/latex/csquotes/csquotes.def)
(c:/texlive/2017/texmf-dist/tex/latex/csquotes/csquotes.cfg))
(c:/texlive/2017/texmf-dist/tex/latex/hyperref/hyperref.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/hobsub-hyperref.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/hobsub-generic.sty))
(c:/texlive/2017/texmf-dist/tex/latex/oberdiek/auxhook.sty)
(c:/texlive/2017/texmf-dist/tex/latex/hyperref/pd1enc.def)
(c:/texlive/2017/texmf-dist/tex/latex/latexconfig/hyperref.cfg))
(c:/texlive/2017/texmf-dist/tex/latex/hyperref/hpdftex.def
(c:/texlive/2017/texmf-dist/tex/latex/oberdiek/rerunfilecheck.sty))
(c:/texlive/2017/texmf-dist/tex/latex/hyperref/puenc.def)
(c:/texlive/2017/texmf-dist/tex/latex/biblatex/lbx/english.lbx) (./main.aux
(./Chapters/Chapter1.aux) (./Chapters/Chapter2.aux) (./Chapters/Chapter3.aux)
(./Appendices/AppendixA.aux))
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/t1ppl.fd)
(c:/texlive/2017/texmf-dist/tex/latex/base/ts1enc.dfu)
(c:/texlive/2017/texmf-dist/tex/latex/translator/translator-basic-dictionary-En
glish.dict)
(c:/texlive/2017/texmf-dist/tex/latex/siunitx/siunitx-abbreviations.cfg)
(c:/texlive/2017/texmf-dist/tex/context/base/mkii/supp-pdf.mkii
[Loading MPS to PDF converter (version 2006.09.02).]
) (c:/texlive/2017/texmf-dist/tex/latex/oberdiek/epstopdf-base.sty
(c:/texlive/2017/texmf-dist/tex/latex/oberdiek/grfext.sty)
(c:/texlive/2017/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg))
*geometry* driver: auto-detecting
*geometry* detected driver: pdftex
(./main.bbl) (c:/texlive/2017/texmf-dist/tex/latex/hyperref/nameref.sty
(c:/texlive/2017/texmf-dist/tex/generic/oberdiek/gettitlestring.sty))
(./main.out) (./main.out)
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/ot1ppl.fd)
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/omlzplm.fd)
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/omszplm.fd)
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/omxzplm.fd)
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/ot1zplm.fd)
1: section
[1{c:/texlive/2017/texmf-var/fonts/map/pdftex/updmap/pdftex.map}] [2]
--------------------
 Declaration of Authorship
--------------------
(c:/texlive/2017/texmf-dist/tex/latex/psnfss/omsppl.fd)
Underfull \hbox (badness 10000) in paragraph at lines 153--154

1: section
[3] [4] [5] [6]
--------------------
 Abstract
--------------------
1: section
[7] [8]
--------------------
 Acknowledgements
--------------------
1: section
[9] [10] (./main.toc (c:/texlive/2017/texmf-dist/tex/latex/base/t1cmtt.fd)
1: section
[11]) [12] (./main.lof)
1: section
[13] [14] (./main.lot)
1: section
[15] [16]
1: section
[17] [18]
1: section
[19] [20]
1: section
[21] [22]
--------------------
 Dedicatory
--------------------
1: section
[23] [24]
1: section
(./Chapters/Chapter1.tex
Chapter 1.
1: section
[1]
Overfull \hbox (12.15245pt too wide) in paragraph at lines 74--76
\T1/ppl/m/n/10.95 site, here: [][]$\T1/cmtt/m/n/10.95 http : / / www . ecs . so
ton . ac . uk / ~srg / softwaretools / document / templates/$[][] 
[2] [3] [4] [5]
Overfull \hbox (8.37132pt too wide) in paragraph at lines 182--183
\T1/ppl/m/n/10.95 sided print-ing is as sim-ple as un-com-ment-ing the \T1/cmtt
/m/it/10.95 oneside \T1/ppl/m/n/10.95 op-tion of the \T1/cmtt/m/n/10.95 documen
tclass
[6] [7] [8 <./Figures/Electron.pdf>]
Overfull \hbox (0.90797pt too wide) in paragraph at lines 310--311
\T1/ppl/m/n/10.95 au-to-mat-i-cally builds a ta-ble of Con-tents by look-ing at
 all the [][]\T1/cmtt/m/n/10.95 \chapter{}[]\T1/ppl/m/n/10.95 , [][]\T1/cmtt/m/
n/10.95 \section{}

Overfull \hbox (0.45015pt too wide) in paragraph at lines 312--313
[]\T1/ppl/m/n/10.95 The Ta-ble of Con-tents should only list the sec-tions to t
hree (3) lev-els. A [][]\T1/cmtt/m/n/10.95 chapter{}
[9]) [10] (./Chapters/Chapter2.tex
Chapter 2.
)
1: section
[11] [12] (./Chapters/Chapter3.tex
Chapter 3.
1: section
[13]
Overfull \hbox (0.45015pt too wide) in paragraph at lines 42--43
[]\T1/ppl/m/n/10.95 The Ta-ble of Con-tents should only list the sec-tions to t
hree (3) lev-els. A [][]\T1/cmtt/m/n/10.95 chapter{}

Overfull \hbox (2.589pt too wide) in paragraph at lines 44--46
[]\T1/ppl/m/n/10.95 W ra-mach prowad-zonych prac oraz w kon-tek�-cie wyko-rzyst
y-wanych tech-nologii

Overfull \hbox (2.01466pt too wide) in paragraph at lines 47--48
\T1/ppl/m/n/10.95 lowanie dziedziny oraz wnioskowanie se-man-ty-czne w pro-ce-s
ie ewalu-acji regu�

Overfull \hbox (38.43422pt too wide) in paragraph at lines 50--51
\T1/ppl/m/n/10.95 postaci on-to-log-icznej. Metoda nie wymaga zna-jo-mo�ci sche
matu przetwarzanego

Overfull \hbox (16.26047pt too wide) in paragraph at lines 53--54
[]\T1/ppl/m/n/10.95 Projekt i im-ple-men-tacja nowa-torskiego mod-elu zarz�dza-
nia pry-wat-no�-ci� danych

Overfull \hbox (8.25603pt too wide) in paragraph at lines 53--54
\T1/ppl/m/n/10.95 wo�ci danych i za-u-fa-nia do pod-miotu. Opra-cow-anie on-tol
ogii opisu-j�cej dziedz-

Overfull \hbox (22.83089pt too wide) in paragraph at lines 54--55
\T1/ppl/m/n/10.95 pode-j�-cia, kt�re, jako pier-wsze, pozwala na bu-dowanie za-
g-nie�d�onych warunk�w

Overfull \hbox (4.14946pt too wide) in paragraph at lines 54--55
\T1/ppl/m/n/10.95 i dy-nam-icznie pod-powiada u�ytkown-ikowi dost�p-nych el-e-m
en-t�w z on-tologii,
) [14] (./Appendices/AppendixA.tex
Appendix A.
)
1: section
[15] [16]
1: section
[17] (./main.aux (./Chapters/Chapter1.aux) (./Chapters/Chapter2.aux)
(./Chapters/Chapter3.aux) (./Appendices/AppendixA.aux)) )
(see the transcript file for additional information){c:/texlive/2017/texmf-dist
/fonts/enc/dvips/cm-super/cm-super-t1.enc}{c:/texlive/2017/texmf-dist/fonts/enc
/dvips/base/8r.enc}<c:/texlive/2017/texmf-dist/fonts/type1/public/amsfonts/cm/c
mr10.pfb><c:/texlive/2017/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy10.pfb>
<c:/texlive/2017/texmf-dist/fonts/type1/public/mathpazo/fplmri.pfb><c:/texlive/
2017/texmf-dist/fonts/type1/public/cm-super/sfit1095.pfb><c:/texlive/2017/texmf
-dist/fonts/type1/public/cm-super/sfst1095.pfb><c:/texlive/2017/texmf-dist/font
s/type1/public/cm-super/sftt1000.pfb><c:/texlive/2017/texmf-dist/fonts/type1/pu
blic/cm-super/sftt1095.pfb><c:/texlive/2017/texmf-dist/fonts/type1/public/cm-su
per/sftt1440.pfb><c:/texlive/2017/texmf-dist/fonts/type1/urw/palatino/uplb8a.pf
b><c:/texlive/2017/texmf-dist/fonts/type1/urw/palatino/uplr8a.pfb><c:/texlive/2
017/texmf-dist/fonts/type1/urw/palatino/uplr8a.pfb><c:/texlive/2017/texmf-dist/
fonts/type1/urw/palatino/uplri8a.pfb>
Output written on main.pdf (41 pages, 300254 bytes).
SyncTeX written on main.synctex.gz.
Transcript written on main.log.

LaTeX Workshop Output

[00:07:52] Found root file from active editor: c:\Git\Priv\phd\template\main.tex
[00:07:52] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.
[00:07:54] Found root file by magic comment: c:\Git\Priv\phd\template\main.tex
[00:07:54] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.
[00:07:58] BUILD command invoked.
[00:07:58] Found root file by magic comment: c:\Git\Priv\phd\template\main.tex
[00:07:58] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.
[00:07:58] Building root file: c:\Git\Priv\phd\template\main.tex
[00:07:58] Build root file c:\Git\Priv\phd\template\main.tex
[00:07:58] Toolchain step 1: pdflatex, -synctex=1,-interaction=nonstopmode,-file-line-error,--shell-escape,c:/Git/Priv/phd/template/main
[00:08:01] LaTeX log parsed with 10 messages.
[00:08:01] Toolchain step 2: bibtex, main
[00:08:01] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.
[00:08:01] Toolchain step 3: pdflatex, -synctex=1,-interaction=nonstopmode,-file-line-error,--shell-escape,c:/Git/Priv/phd/template/main
[00:08:04] LaTeX log parsed with 10 messages.
[00:08:04] Toolchain step 4: pdflatex, -synctex=1,-interaction=nonstopmode,-file-line-error,--shell-escape,c:/Git/Priv/phd/template/main
[00:08:06] LaTeX log parsed with 10 messages.
[00:08:06] Toolchain of length 4 finished.
[00:08:06] Successfully built c:\Git\Priv\phd\template\main.tex
[00:08:06] Refresh PDF viewer for c:\Git\Priv\phd\template\main.pdf
[00:08:06] Preview PDF file: c:\Git\Priv\phd\template\main.pdf
[00:08:19] Found root file by magic comment: c:\Git\Priv\phd\template\main.tex
[00:08:19] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.
[00:08:48] Root file remains unchanged from: c:\Git\Priv\phd\template\main.tex.

Additional Information

Most helpful comment

Following the conclusion of my previous post, I think the issue can be closed.

All 4 comments

Can you please provide a minimal working example? I cannot reproduce the problem, and the same issue should already been handled in previous commits.

I've uploaded an example to https://github.com/mdrozdo/latex_workshop_420. In this case it actually reports all overfull warnings as if they were in main.tex.

I'm running the 3.13.0 version.

Here's my toolchain config:

"latex-workshop.latex.toolchain": [
        {
            "command": "pdflatex",
            "args": [
                "-synctex=1",
                "-interaction=nonstopmode",
                "-file-line-error",
                "--shell-escape",
                "%DOC%"
            ]
        },
        {
            "command": "bibtex",
            "args": [
                "%DOCFILE%"
            ]
        },
        {
            "command": "pdflatex",
            "args": [
                "-synctex=1",
                "-interaction=nonstopmode",
                "-file-line-error",
                "--shell-escape",
                "%DOC%"
            ]
        },
        {
            "command": "pdflatex",
            "args": [
                "-synctex=1",
                "-interaction=nonstopmode",
                "-file-line-error",
                "--shell-escape",
                "%DOC%"
            ]
        }
    ]

I have played a bit with your example. Here is an extract from the log output

(./chapters/myfile1.tex)
Overfull \hbox (6.98837pt too wide) in paragraph at lines 3--9
[][]\OT1/cmtt/m/n/10 chapter{} []\OT1/cmr/m/n/10 is level zero (0). A [][]\OT1/
cmtt/m/n/10 \section{} []\OT1/cmr/m/n/10 is level one (1) and so a [][]\OT1/cmt
t/m/n/10 \subsection{}

Note that the overfull warning appears after the closing bracket of (./chapters/myfile1.tex), which means that the scope of warning is the main file.

If you replace include by input in your main.tex, then the log looks like

(./chapters/myfile2.tex
Overfull \hbox (6.98837pt too wide) in paragraph at lines 3--2
[][]\OT1/cmtt/m/n/10 chapter{} []\OT1/cmr/m/n/10 is level zero (0). A [][]\OT1/
cmtt/m/n/10 \section{} []\OT1/cmr/m/n/10 is level one (1) and so a [][]\OT1/cmt
t/m/n/10 \subsection{}

Overfull \hbox (8.68488pt too wide) in paragraph at lines 3--2
[]\OT1/cmr/m/n/10 is level two (2). In your the-sis it is likely that you will
even use a [][]\OT1/cmtt/m/n/10 subsubsection{}[]\OT1/cmr/m/n/10 ,
)

This time, the warning appears within the scope of myfile2.tex.

Your problem does not seem related to the LaTeX Workshop extension. You may consider reporting your problem on a LaTeX forum.

Following the conclusion of my previous post, I think the issue can be closed.

Was this page helpful?
0 / 5 - 0 ratings