Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"View documentation" link on \usepackage{...} hover doesn't work with Snap version of VSCode #2437

Closed
FMuro opened this issue Dec 15, 2020 · 26 comments
Labels
external issue Issue with something else than LaTeX-Wokshop

Comments

@FMuro
Copy link
Contributor

FMuro commented Dec 15, 2020

Preliminary questions [Required]

Disable all the other extensions except for LaTeX Workshop, and check that you still see this issue. [Required]

You still see this issue?: Yes

Make sure to visit the wiki FAQ before filling an issue.

You visited the wiki?: Yes, texdoc is in path. I've tried with the full path and it doesn't work either. BTW, texdoc works without issues from terminal.

Describe the bug [Required]

Hover a \usepackage{...} and click on "view documentation", or run "LaTex Workshop: Show package documentation" or "LaTex Workshop: Show package documentation actually used". None of them works,

To Reproduce

Steps to reproduce the behavior:

  1. Hover a \usepackage{...}
  2. Click on "view documentation"
  3. You don't get any outcome

Or:

  1. Run "LaTex Workshop: Show package documentation actually used"
  2. Select one of the packages
  3. You don't get any outcome

Or:

  1. Run "LaTex Workshop: Show package documentation"
  2. Write a package name
  3. You don't get any outcome

Expected behavior

A PDF with the docs should open. I've tested with packages which all have docs, and running texdoc from CLI works as expected. The similar functionality in Emacs also works.

Logs [Required]

Please paste the whole log messages here, not parts of ones. The log should start with Initializing LaTeX Workshop. It is very important to identify problems.

LaTeX Workshop Output [Required]

To access the log, click the 'TeX' icon on the Activity Bar on the left side, select 'View Log Messages', then select 'View LaTeX Workshop extension log'.

[10:04:05] Initializing LaTeX Workshop.
[10:04:05] Extension root: /home/***/.vscode/extensions/james-yu.latex-workshop-8.15.0
[10:04:05] Creating PDF file watcher.
[10:04:05] Creating LaTeX Workshop http and websocket server.
[10:04:05] LaTeX Workshop initialized.
[10:04:05] Current workspace folders: ["file:///home/***/***/***/***/***"]
[10:04:05] Current workspaceRootDir: /home/***/***/***/***/***
[10:04:05] Found root file from active editor: /home/***/***/***/***/***.tex
[10:04:05] Root file changed: from undefined to /home/***/***/***/***/***.tex
[10:04:05] Start to find all dependencies.
[10:04:05] Root file languageId: latex
[10:04:05] Instantiating a new file watcher for /home/***/***/***/***/***.tex
[10:04:05] Creating Bib file watcher.
[10:04:05] Parsing a file and its subfiles: /home/***/***/***/***/***.tex
[10:04:05] Found .bib file: /home/***/***/***/***/***.bib
[10:04:05] Added to bib file watcher: /home/***/***/***/***/***.bib
[10:04:05] Parsing .bib entries from /home/***/***/***/***/***.bib
[10:04:05] Parse fls file.
[10:04:05] Fls file found: /home/***/***/***/***/***.fls
[10:04:06] Parse aux file: /home/***/***/***/***/***.aux
[10:04:06] Found .bib file: /home/***/***/***/***/***.bib
[10:04:06] Server created on 127.0.0.1:34723
[10:04:06] Added to file watcher: /home/***/***/***/***/***.tex
[10:04:06] Snippet data loaded.
[10:04:06] LaTeX Workshop version: 8.15.0
[10:04:06] Parsed 72 bib entries from /home/***/***/***/***/***.bib.
[10:04:23] Opening documentation for amsmath.


Developer Tools Console [Required]

To access the log, click 'help' -> 'Toggle Developer Tools' -> 'Console'. Paste anything suspicious.

Nothing there.

Screenshots

If applicable, add screenshots to help explain your problem.

Desktop [Required]

  • OS: Ubuntu Focal
  • VS Code version: 1.52.0
  • Extension version: 8.15.0
  • TeX distribution version:TeX Live 2019

Additional questions

Are you using VSCodium?

No

Are you using LaTeX Workshop with VS Code Remote?

No

@tamuratak tamuratak added the can't reproduce Issue cannot be reproduced label Dec 15, 2020
@jlelong
Copy link
Collaborator

jlelong commented Dec 15, 2020

I cannot reproduce either.

@FMuro The logs say Opening documentation for amsmath, which means that the command texdoc amsmath returns successfully (exit code 0). Can you execute texdoc amsmath from the command line and paste the output?

@FMuro
Copy link
Contributor Author

FMuro commented Dec 15, 2020

I cannot reproduce either.

@FMuro The logs say Opening documentation for amsmath, which means that the command texdoc amsmath returns successfully (exit code 0). Can you execute texdoc amsmath from the command line and paste the output?

From command line it works like a charm. It just opens the PDF. I have vscode installed as a snap. I don't know if this makes any difference because it's a classic one, though.

@tamuratak
Copy link
Contributor

  1. Please execute texdoc --debug=all amsmath from the terminal.
  2. Please paste the output.

@FMuro
Copy link
Contributor Author

FMuro commented Dec 15, 2020

1. Please execute `texdoc --debug=all  amsmath` from the terminal.

2. Please paste the output.
texdoc debug-version: /usr/share/texlive/texmf-dist/scripts/texdoc/texdoclib.tlu v3.2
texdoc debug-config: Setting "debug_list=all" from command line option "--debug".
texdoc debug-config: Setting "viewer_pdf=(xdg-open %s) &" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 36.
texdoc debug-config: Setting "viewer_ps=(xdg-open %s) &" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 37.
texdoc debug-config: Setting "viewer_dvi=(xdg-open %s) &" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 38.
texdoc debug-config: Setting "viewer_html=(xdg-open %s) &" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 39.
texdoc debug-config: Setting "viewer_txt=(xdg-open %s) &" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 40.
texdoc debug-config: Setting "zipext_list=gz, bz2, xz" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 69.
texdoc debug-config: Setting "unzip_gz=gzip -d -c" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 70.
texdoc debug-config: Setting "unzip_bz2=bzip2 -d -c" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 71.
texdoc debug-config: Setting "unzip_xz=xz --decompress --stdout" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 72.
texdoc debug-config: Setting "suffix_list=doc, -doc, _doc, .doc, /doc, manual, /manual, -manual, userguide, /user_guide, -guide, -user, -man, notes, -info, ref" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 102.
texdoc debug-config: Setting "lastfile_switch=true" in file "/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf" on line 569.
texdoc debug-config: Setting "badbasename_list=readme, 00readme" from built-in defaults.
texdoc debug-config: Setting "ext_list=pdf, htm, html, txt, md, ps, dvi, " from built-in defaults.
texdoc debug-config: Setting "basename_list=readme, 00readme" from built-in defaults.
texdoc debug-config: Setting "max_lines=20" from built-in defaults.
texdoc debug-config: Setting "interact_switch=true" from built-in defaults.
texdoc debug-config: Setting "fuzzy_level=5" from built-in defaults.
texdoc debug-config: Setting "mode=view" from built-in defaults.
texdoc debug-config: Setting "machine_switch=false" from built-in defaults.
texdoc debug-config: Setting "verbosity_level=2" from built-in defaults.
texdoc debug-config: Setting "badext_list=txt, " from built-in defaults.
texdoc debug-config: Setting "rm_dir=rmdir" from built-in defaults.
texdoc debug-config: Setting "rm_file=rm -f" from built-in defaults.
texdoc debug-files: Configuration file(s):
texdoc debug-files: not found	/usr/share/texlive/texmf-dist/texdoc/texdoc-bin.cnf
texdoc debug-files: active	/usr/share/texlive/texmf-dist/texdoc/texdoc.cnf
texdoc debug-files: not found	/usr/share/texlive/texmf-dist/texdoc/texdoc-dist.cnf
texdoc debug-texdocs: texdocs[8] = /home/username/.texlive2019/texmf-config/doc (index_mandatory=false, recursion_allowed=true)
texdoc debug-texdocs: texdocs[7] = /home/username/.texlive2019/texmf-var/doc (index_mandatory=false, recursion_allowed=true)
texdoc debug-texdocs: texdocs[6] = /home/username/texmf/doc (index_mandatory=false, recursion_allowed=true)
texdoc debug-texdocs: texdocs[5] = /usr/local/share/texmf/doc (index_mandatory=true, recursion_allowed=true)
texdoc debug-texdocs: texdocs[4] = /etc/texmf/doc (index_mandatory=false, recursion_allowed=true)
texdoc debug-texdocs: texdocs[3] = /var/lib/texmf/doc (index_mandatory=true, recursion_allowed=true)
texdoc debug-texdocs: texdocs[2] = /usr/share/texmf/doc (index_mandatory=true, recursion_allowed=true)
texdoc debug-texdocs: texdocs[2] using index: /usr/share/texmf (shift=doc/)
texdoc debug-texdocs: texdocs[1] = /usr/share/texlive/texmf-dist/doc (index_mandatory=true, recursion_allowed=true)
texdoc debug-texdocs: texdocs[1] using index: /usr/share/texlive/texmf-dist (shift=doc/)
texdoc debug-tlpdb: Using shipped tlpdb data.
texdoc debug-tlpdb: Getting data from shipped tlpdb data file /usr/share/texlive/texmf-dist/scripts/texdoc/Data.tlpdb.lua
texdoc debug-search: Searching documents for pattern "amsmath"
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/README.md found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsbsy.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amscd.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsgen.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsopn.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amstext.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsxtra.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/manifest.txt found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/subeqn.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/technote.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/testmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsbsy.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsgen.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsopn.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/testidx/samples/sample-idx-amsmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/diffs-m.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/changes.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/ChangeLog found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/diffs-m.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/README.md found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/ams-internal.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath-it/README found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath/ams-external.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/testmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/technote.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/subeqn.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amstext.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsldoc.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/ams-internal.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/ams-external.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/amsmath-it/diffs-m_it.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/manifest.txt found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amscd.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/onlyamsmath.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/changes.txt.gz found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/Makefile found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsxtra.pdf found.
texdoc debug-search: File /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/README found.
texdoc debug-score: (f022f8d) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/README.md
texdoc debug-score: (f022f8d) Name used: latex/amsmath/readme.md
texdoc debug-score: (f022f8d) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (f022f8d) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (f022f8d) New heuristic score: 0.1. Reason: bad basename
texdoc debug-score: (f022f8d) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (f022f8d) Final heuristic score: 1.6
texdoc debug-score: (f022f8d) Max pattern score: 1.6
texdoc debug-score: (f022f8d) Catalogue "readme" bonus: +0.1
texdoc debug-score: (f022f8d) Adjust by 0.1 from global pattern "readme"
texdoc debug-score: (f022f8d) Final score: 1.8
texdoc debug-score: (49b491e) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsbsy.pdf
texdoc debug-score: (49b491e) Name used: latex/amsmath/amsbsy.pdf
texdoc debug-score: (49b491e) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (49b491e) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (49b491e) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (49b491e) Final heuristic score: 2.5
texdoc debug-score: (49b491e) Max pattern score: 2.5
texdoc debug-score: (49b491e) Final score: 2.5
texdoc debug-score: (18cab9a) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amscd.pdf
texdoc debug-score: (18cab9a) Name used: latex/amsmath/amscd.pdf
texdoc debug-score: (18cab9a) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (18cab9a) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (18cab9a) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (18cab9a) Final heuristic score: 2.5
texdoc debug-score: (18cab9a) Max pattern score: 2.5
texdoc debug-score: (18cab9a) Final score: 2.5
texdoc debug-score: (69ac8ac) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsgen.pdf
texdoc debug-score: (69ac8ac) Name used: latex/amsmath/amsgen.pdf
texdoc debug-score: (69ac8ac) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (69ac8ac) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (69ac8ac) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (69ac8ac) Final heuristic score: 2.5
texdoc debug-score: (69ac8ac) Max pattern score: 2.5
texdoc debug-score: (69ac8ac) Final score: 2.5
texdoc debug-score: (99d78f1) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf
texdoc debug-score: (99d78f1) Name used: latex/amsmath/amsldoc.pdf
texdoc debug-score: (99d78f1) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (99d78f1) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (99d78f1) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (99d78f1) Final heuristic score: 2.5
texdoc debug-score: (99d78f1) Matching alias "amsldoc", score: 10.0
texdoc debug-score: (99d78f1) Max pattern score: 10.0
texdoc debug-score: (99d78f1) Catalogue details bonus: +1.5
texdoc debug-score: (99d78f1) Final score: 11.5
texdoc debug-score: (118b1a4) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsmath.pdf
texdoc debug-score: (118b1a4) Name used: latex/amsmath/amsmath.pdf
texdoc debug-score: (118b1a4) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (118b1a4) New heuristic score: 4.0. Reason: exact match
texdoc debug-score: (118b1a4) New heuristic score: 5.5. Reason: directory bonus
texdoc debug-score: (118b1a4) Final heuristic score: 5.5
texdoc debug-score: (118b1a4) Max pattern score: 5.5
texdoc debug-score: (118b1a4) Final score: 5.5
texdoc debug-score: (85fb032) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsopn.pdf
texdoc debug-score: (85fb032) Name used: latex/amsmath/amsopn.pdf
texdoc debug-score: (85fb032) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (85fb032) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (85fb032) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (85fb032) Final heuristic score: 2.5
texdoc debug-score: (85fb032) Max pattern score: 2.5
texdoc debug-score: (85fb032) Final score: 2.5
texdoc debug-score: (345a445) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amstext.pdf
texdoc debug-score: (345a445) Name used: latex/amsmath/amstext.pdf
texdoc debug-score: (345a445) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (345a445) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (345a445) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (345a445) Final heuristic score: 2.5
texdoc debug-score: (345a445) Max pattern score: 2.5
texdoc debug-score: (345a445) Final score: 2.5
texdoc debug-score: (abb2564) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsxtra.pdf
texdoc debug-score: (abb2564) Name used: latex/amsmath/amsxtra.pdf
texdoc debug-score: (abb2564) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (abb2564) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (abb2564) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (abb2564) Final heuristic score: 2.5
texdoc debug-score: (abb2564) Max pattern score: 2.5
texdoc debug-score: (abb2564) Final score: 2.5
texdoc debug-score: (e106fa1) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/manifest.txt
texdoc debug-score: (e106fa1) Name used: latex/amsmath/manifest.txt
texdoc debug-score: (e106fa1) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (e106fa1) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (e106fa1) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (e106fa1) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (e106fa1) Final heuristic score: 1.6
texdoc debug-score: (e106fa1) Max pattern score: 1.6
texdoc debug-score: (e106fa1) Final score: 1.6
texdoc debug-score: (8364f3d) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/subeqn.pdf
texdoc debug-score: (8364f3d) Name used: latex/amsmath/subeqn.pdf
texdoc debug-score: (8364f3d) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (8364f3d) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (8364f3d) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (8364f3d) Final heuristic score: 2.5
texdoc debug-score: (8364f3d) Max pattern score: 2.5
texdoc debug-score: (8364f3d) Catalogue details bonus: +1.5
texdoc debug-score: (8364f3d) Final score: 4.0
texdoc debug-score: (e0f56d3) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/technote.pdf
texdoc debug-score: (e0f56d3) Name used: latex/amsmath/technote.pdf
texdoc debug-score: (e0f56d3) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (e0f56d3) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (e0f56d3) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (e0f56d3) Final heuristic score: 2.5
texdoc debug-score: (e0f56d3) Max pattern score: 2.5
texdoc debug-score: (e0f56d3) Catalogue details bonus: +1.5
texdoc debug-score: (e0f56d3) Final score: 4.0
texdoc debug-score: (35e6df5) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/testmath.pdf
texdoc debug-score: (35e6df5) Name used: latex/amsmath/testmath.pdf
texdoc debug-score: (35e6df5) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (35e6df5) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (35e6df5) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (35e6df5) Final heuristic score: 2.5
texdoc debug-score: (35e6df5) Max pattern score: 2.5
texdoc debug-score: (35e6df5) Catalogue details bonus: +1.5
texdoc debug-score: (35e6df5) Final score: 4.0
texdoc debug-score: (c1c68ce) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsbsy.pdf
texdoc debug-score: (c1c68ce) Name used: latex-dev/amsmath/amsbsy.pdf
texdoc debug-score: (c1c68ce) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (c1c68ce) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (c1c68ce) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (c1c68ce) Final heuristic score: 2.5
texdoc debug-score: (c1c68ce) Max pattern score: 2.5
texdoc debug-score: (c1c68ce) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (c1c68ce) Final score: 0.5
texdoc debug-score: (a730ec3) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsgen.pdf
texdoc debug-score: (a730ec3) Name used: latex-dev/amsmath/amsgen.pdf
texdoc debug-score: (a730ec3) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (a730ec3) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (a730ec3) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (a730ec3) Final heuristic score: 2.5
texdoc debug-score: (a730ec3) Max pattern score: 2.5
texdoc debug-score: (a730ec3) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (a730ec3) Final score: 0.5
texdoc debug-score: (7169c27) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsopn.pdf
texdoc debug-score: (7169c27) Name used: latex-dev/amsmath/amsopn.pdf
texdoc debug-score: (7169c27) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (7169c27) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (7169c27) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (7169c27) Final heuristic score: 2.5
texdoc debug-score: (7169c27) Max pattern score: 2.5
texdoc debug-score: (7169c27) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (7169c27) Final score: 0.5
texdoc debug-score: (c8b0e8c) Start scoring /usr/share/texlive/texmf-dist/doc/latex/testidx/samples/sample-idx-amsmath.pdf
texdoc debug-score: (c8b0e8c) Name used: latex/testidx/samples/sample-idx-amsmath.pdf
texdoc debug-score: (c8b0e8c) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (c8b0e8c) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (c8b0e8c) Final heuristic score: 1.0
texdoc debug-score: (c8b0e8c) Max pattern score: 1.0
texdoc debug-score: (c8b0e8c) Adjust by -1.0 from global pattern "samples"
texdoc debug-score: (c8b0e8c) Final score: 0.0
texdoc debug-score: (932cc07) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/diffs-m.txt.gz
texdoc debug-score: (932cc07) Name used: latex/amsmath/diffs-m.txt.gz
texdoc debug-score: (932cc07) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (932cc07) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (932cc07) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (932cc07) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (932cc07) Final heuristic score: 1.6
texdoc debug-score: (932cc07) Max pattern score: 1.6
texdoc debug-score: (932cc07) Final score: 1.6
texdoc debug-score: (eb99d0a) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/changes.txt.gz
texdoc debug-score: (eb99d0a) Name used: latex/amsmath/changes.txt.gz
texdoc debug-score: (eb99d0a) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (eb99d0a) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (eb99d0a) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (eb99d0a) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (eb99d0a) Final heuristic score: 1.6
texdoc debug-score: (eb99d0a) Max pattern score: 1.6
texdoc debug-score: (eb99d0a) Final score: 1.6
texdoc debug-score: (8fcc73c) Start scoring /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/ChangeLog
texdoc debug-score: (8fcc73c) Name used: latex/onlyamsmath/changelog
texdoc debug-score: (8fcc73c) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (8fcc73c) Final heuristic score: -10.0
texdoc debug-score: (8fcc73c) Max pattern score: -10.0
texdoc debug-score: (8fcc73c) Final score: -10.0
texdoc debug-score: (ac6f9d6) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/diffs-m.txt.gz
texdoc debug-score: (ac6f9d6) Name used: latex-dev/amsmath/diffs-m.txt.gz
texdoc debug-score: (ac6f9d6) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (ac6f9d6) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (ac6f9d6) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (ac6f9d6) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (ac6f9d6) Final heuristic score: 1.6
texdoc debug-score: (ac6f9d6) Max pattern score: 1.6
texdoc debug-score: (ac6f9d6) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (ac6f9d6) Final score: -0.4
texdoc debug-score: (90ca93a) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/README.md
texdoc debug-score: (90ca93a) Name used: latex-dev/amsmath/readme.md
texdoc debug-score: (90ca93a) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (90ca93a) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (90ca93a) New heuristic score: 0.1. Reason: bad basename
texdoc debug-score: (90ca93a) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (90ca93a) Final heuristic score: 1.6
texdoc debug-score: (90ca93a) Max pattern score: 1.6
texdoc debug-score: (90ca93a) Adjust by 0.1 from global pattern "readme"
texdoc debug-score: (90ca93a) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (90ca93a) Final score: -0.3
texdoc debug-score: (1ad4500) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/ams-internal.txt.gz
texdoc debug-score: (1ad4500) Name used: latex/amsmath/ams-internal.txt.gz
texdoc debug-score: (1ad4500) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (1ad4500) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (1ad4500) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (1ad4500) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (1ad4500) Final heuristic score: 1.6
texdoc debug-score: (1ad4500) Max pattern score: 1.6
texdoc debug-score: (1ad4500) Final score: 1.6
texdoc debug-score: (e08c51a) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath-it/README
texdoc debug-score: (e08c51a) Name used: latex/amsmath-it/readme
texdoc debug-score: (e08c51a) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (e08c51a) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (e08c51a) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (e08c51a) New heuristic score: 0.1. Reason: bad basename
texdoc debug-score: (e08c51a) Final heuristic score: 0.1
texdoc debug-score: (e08c51a) Max pattern score: 0.1
texdoc debug-score: (e08c51a) Adjust by 0.1 from global pattern "readme"
texdoc debug-score: (e08c51a) Final score: 0.2
texdoc debug-score: (cf07feb) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath/ams-external.txt.gz
texdoc debug-score: (cf07feb) Name used: latex/amsmath/ams-external.txt.gz
texdoc debug-score: (cf07feb) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (cf07feb) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (cf07feb) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (cf07feb) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (cf07feb) Final heuristic score: 1.6
texdoc debug-score: (cf07feb) Max pattern score: 1.6
texdoc debug-score: (cf07feb) Final score: 1.6
texdoc debug-score: (c2f0a8e) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/testmath.pdf
texdoc debug-score: (c2f0a8e) Name used: latex-dev/amsmath/testmath.pdf
texdoc debug-score: (c2f0a8e) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (c2f0a8e) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (c2f0a8e) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (c2f0a8e) Final heuristic score: 2.5
texdoc debug-score: (c2f0a8e) Max pattern score: 2.5
texdoc debug-score: (c2f0a8e) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (c2f0a8e) Final score: 0.5
texdoc debug-score: (4ea6421) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/technote.pdf
texdoc debug-score: (4ea6421) Name used: latex-dev/amsmath/technote.pdf
texdoc debug-score: (4ea6421) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (4ea6421) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (4ea6421) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (4ea6421) Final heuristic score: 2.5
texdoc debug-score: (4ea6421) Max pattern score: 2.5
texdoc debug-score: (4ea6421) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (4ea6421) Final score: 0.5
texdoc debug-score: (f424ce5) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/subeqn.pdf
texdoc debug-score: (f424ce5) Name used: latex-dev/amsmath/subeqn.pdf
texdoc debug-score: (f424ce5) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (f424ce5) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (f424ce5) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (f424ce5) Final heuristic score: 2.5
texdoc debug-score: (f424ce5) Max pattern score: 2.5
texdoc debug-score: (f424ce5) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (f424ce5) Final score: 0.5
texdoc debug-score: (a4a69d8) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amstext.pdf
texdoc debug-score: (a4a69d8) Name used: latex-dev/amsmath/amstext.pdf
texdoc debug-score: (a4a69d8) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (a4a69d8) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (a4a69d8) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (a4a69d8) Final heuristic score: 2.5
texdoc debug-score: (a4a69d8) Max pattern score: 2.5
texdoc debug-score: (a4a69d8) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (a4a69d8) Final score: 0.5
texdoc debug-score: (e83d403) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsmath.pdf
texdoc debug-score: (e83d403) Name used: latex-dev/amsmath/amsmath.pdf
texdoc debug-score: (e83d403) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (e83d403) New heuristic score: 4.0. Reason: exact match
texdoc debug-score: (e83d403) New heuristic score: 5.5. Reason: directory bonus
texdoc debug-score: (e83d403) Final heuristic score: 5.5
texdoc debug-score: (e83d403) Max pattern score: 5.5
texdoc debug-score: (e83d403) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (e83d403) Final score: 3.5
texdoc debug-score: (0e62af6) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsldoc.pdf
texdoc debug-score: (0e62af6) Name used: latex-dev/amsmath/amsldoc.pdf
texdoc debug-score: (0e62af6) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (0e62af6) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (0e62af6) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (0e62af6) Final heuristic score: 2.5
texdoc debug-score: (0e62af6) Matching alias "amsldoc", score: 10.0
texdoc debug-score: (0e62af6) Max pattern score: 10.0
texdoc debug-score: (0e62af6) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (0e62af6) Final score: 8.0
texdoc debug-score: (052be08) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/ams-internal.txt.gz
texdoc debug-score: (052be08) Name used: latex-dev/amsmath/ams-internal.txt.gz
texdoc debug-score: (052be08) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (052be08) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (052be08) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (052be08) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (052be08) Final heuristic score: 1.6
texdoc debug-score: (052be08) Max pattern score: 1.6
texdoc debug-score: (052be08) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (052be08) Final score: -0.4
texdoc debug-score: (5b6610f) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/ams-external.txt.gz
texdoc debug-score: (5b6610f) Name used: latex-dev/amsmath/ams-external.txt.gz
texdoc debug-score: (5b6610f) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (5b6610f) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (5b6610f) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (5b6610f) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (5b6610f) Final heuristic score: 1.6
texdoc debug-score: (5b6610f) Max pattern score: 1.6
texdoc debug-score: (5b6610f) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (5b6610f) Final score: -0.4
texdoc debug-score: (d1e49ae) Start scoring /usr/share/texlive/texmf-dist/doc/latex/amsmath-it/diffs-m_it.txt.gz
texdoc debug-score: (d1e49ae) Name used: latex/amsmath-it/diffs-m_it.txt.gz
texdoc debug-score: (d1e49ae) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (d1e49ae) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (d1e49ae) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (d1e49ae) Final heuristic score: 0.1
texdoc debug-score: (d1e49ae) Max pattern score: 0.1
texdoc debug-score: (d1e49ae) Final score: 0.1
texdoc debug-score: (3138b51) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/manifest.txt
texdoc debug-score: (3138b51) Name used: latex-dev/amsmath/manifest.txt
texdoc debug-score: (3138b51) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (3138b51) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (3138b51) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (3138b51) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (3138b51) Final heuristic score: 1.6
texdoc debug-score: (3138b51) Max pattern score: 1.6
texdoc debug-score: (3138b51) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (3138b51) Final score: -0.4
texdoc debug-score: (1cf61f0) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amscd.pdf
texdoc debug-score: (1cf61f0) Name used: latex-dev/amsmath/amscd.pdf
texdoc debug-score: (1cf61f0) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (1cf61f0) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (1cf61f0) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (1cf61f0) Final heuristic score: 2.5
texdoc debug-score: (1cf61f0) Max pattern score: 2.5
texdoc debug-score: (1cf61f0) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (1cf61f0) Final score: 0.5
texdoc debug-score: (4fe1e4c) Start scoring /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/onlyamsmath.pdf
texdoc debug-score: (4fe1e4c) Name used: latex/onlyamsmath/onlyamsmath.pdf
texdoc debug-score: (4fe1e4c) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (4fe1e4c) Final heuristic score: -10.0
texdoc debug-score: (4fe1e4c) Max pattern score: -10.0
texdoc debug-score: (4fe1e4c) Catalogue details bonus: +1.5
texdoc debug-score: (4fe1e4c) Final score: -8.5
texdoc debug-score: (f48c6f2) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/changes.txt.gz
texdoc debug-score: (f48c6f2) Name used: latex-dev/amsmath/changes.txt.gz
texdoc debug-score: (f48c6f2) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (f48c6f2) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (f48c6f2) New heuristic score: 0.1. Reason: bad extension
texdoc debug-score: (f48c6f2) New heuristic score: 1.6. Reason: directory bonus
texdoc debug-score: (f48c6f2) Final heuristic score: 1.6
texdoc debug-score: (f48c6f2) Max pattern score: 1.6
texdoc debug-score: (f48c6f2) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (f48c6f2) Final score: -0.4
texdoc debug-score: (142dc64) Start scoring /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/Makefile
texdoc debug-score: (142dc64) Name used: latex/onlyamsmath/makefile
texdoc debug-score: (142dc64) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (142dc64) Final heuristic score: -10.0
texdoc debug-score: (142dc64) Max pattern score: -10.0
texdoc debug-score: (142dc64) Adjust by -1000.0 from global pattern "/makefile"
texdoc debug-score: (142dc64) Final score: -1010.0
texdoc debug-score: (9aafc9d) Start scoring /usr/share/texlive/texmf-dist/doc/latex-dev/amsmath/amsxtra.pdf
texdoc debug-score: (9aafc9d) Name used: latex-dev/amsmath/amsxtra.pdf
texdoc debug-score: (9aafc9d) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (9aafc9d) New heuristic score: 1.0. Reason: subword match
texdoc debug-score: (9aafc9d) New heuristic score: 2.5. Reason: directory bonus
texdoc debug-score: (9aafc9d) Final heuristic score: 2.5
texdoc debug-score: (9aafc9d) Max pattern score: 2.5
texdoc debug-score: (9aafc9d) Adjust by -2.0 from global pattern "/latex-dev/"
texdoc debug-score: (9aafc9d) Final score: 0.5
texdoc debug-score: (eaba422) Start scoring /usr/share/texlive/texmf-dist/doc/latex/onlyamsmath/README
texdoc debug-score: (eaba422) Name used: latex/onlyamsmath/readme
texdoc debug-score: (eaba422) Start heuristic scoring with pattern: amsmath
texdoc debug-score: (eaba422) Final heuristic score: -10.0
texdoc debug-score: (eaba422) Max pattern score: -10.0
texdoc debug-score: (eaba422) Catalogue "readme" bonus: +0.1
texdoc debug-score: (eaba422) Adjust by 0.1 from global pattern "readme"
texdoc debug-score: (eaba422) Final score: -9.8
texdoc debug-view: Using "viewer_pdf" to open the file.
texdoc info: View command: (xdg-open "/usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf") &
texdoc info: Setting environment LC_CTYPE to: en_US.UTF-8

@jlelong
Copy link
Collaborator

jlelong commented Dec 15, 2020

Does it work when you run the texdoc from VSCode's terminal? Can you create a recipe that runs the command xdg-open "/usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf" and tell us if it works?

@jlelong jlelong added the need more info More information needed to identify the issue label Dec 15, 2020
@FMuro
Copy link
Contributor Author

FMuro commented Dec 15, 2020

Does it work when you run the texdoc from VSCode's terminal?

It does.

Can you create a recipe that runs the command xdg-open "/usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf" and tell us if it works?

This doesn't work from the recipe (although it does from terminal). From the recipe, I get:

[17:37:57] RECIPES command invoked.
[17:38:00] BUILD command invoked.
[17:38:00] The document of the active editor: output:extension-output-%232
[17:38:00] The languageId of the document: Log
[17:38:00] Cannot find LaTeX root file.

@FMuro

This comment has been minimized.

@jlelong

This comment has been minimized.

@FMuro

This comment has been minimized.

@jlelong
Copy link
Collaborator

jlelong commented Dec 15, 2020

console.ts:137 [Extension Host] stack trace: TypeError: Cannot read property 'command' of undefined	at Builder.buildStep (/home/***/.vscode/extensions/james-yu.latex-workshop-8.15.0/out/src/components/builder.js:277:87)	at Builder.buildInitiator (/home/***/.vscode/extensions/james-yu.latex-workshop-8.15.0/out/src/components/builder.js:186:14)	at Builder.build (/home/***/.vscode/extensions/james-yu.latex-workshop-8.15.0/out/src/components/builder.js:248:18)	at processTicksAndRejections (internal/process/task_queues.js:94:5)	at async Commander.build (/home/***/.vscode/extensions/james-yu.latex-workshop-8.15.0/out/src/commander.js:115:9)
t.log @ console.ts:112

is probably the result of an error in the recipe definition. Can you try

    "latex-workshop.latex.recipes": [
        {
            "name": "xdg",
            "tools": [
                "xdg"
            ]
        }
    ],
    "latex-workshop.latex.tools": [
        {
            "name": "xdg",
            "command": "xdg-open",
            "args": [
                  "/usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf"
            ],
            "env": {}
        }
    ]

@FMuro
Copy link
Contributor Author

FMuro commented Dec 15, 2020

Thanks for elaborating. Here you have what I get:

[23:09:03] RECIPES command invoked.
[23:09:04] BUILD command invoked.
[23:09:04] The document of the active editor: file:///home/***/Documents/***/***/***/***.tex
[23:09:04] The languageId of the document: latex
[23:09:04] Current workspace folders: ["file:///home/***/Documents/***/***/***"]
[23:09:04] Current workspaceRootDir: /home/***/Documents/***/***/***
[23:09:04] Found root file from active editor: /home/***/Documents/***/***/***/***.tex
[23:09:04] Keep using the same root file: /home/***/Documents/***/***/***/***.tex
[23:09:04] Building root file: /home/***/Documents/***/***/***/***.tex
[23:09:04] Build root file /home/***/Documents/***/***/***/***.tex
[23:09:04] Recipe step 1: xdg-open, /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf
[23:09:04] Recipe step env: {}
[23:09:04] cwd: /home/***/Documents/***/***/***
[23:09:04] LaTeX build process spawned. PID: 28682.
[23:09:04] Recipe of length 1 finished. PID: 28682.
[23:09:04] Successfully built /home/***/Documents/***/***/***/***.tex.
[23:09:04] No PDF viewer connected for /home/***/Documents/***/***/***/***.pdf
[23:09:04] Parse fls file.
[23:09:04] Fls file found: /home/***/Documents/***/***/***/***.fls
[23:09:04] Parse aux file: /home/***/Documents/***/***/***/***.aux

@jlelong
Copy link
Collaborator

jlelong commented Dec 16, 2020

Great. Does the amsmath documentation open ?

@FMuro
Copy link
Contributor Author

FMuro commented Dec 16, 2020

Great. Does the amsmath documentation open ?

Unfortunately not. I hoped you'd find some clue here, maybe the "No PDF viewer connected...", although the file referred to therein is not the doc file.

@jlelong
Copy link
Collaborator

jlelong commented Dec 16, 2020

So, we have narrowed down the original issue -- texdoc not opening any documentation -- to the inability of xdg-open /usr/share/texlive/texmf-dist/doc/latex/amsmath/amsldoc.pdf to actually open the PDF file when spawn from vscode (this is what the recipe mechanism does). You can change the viewer used by texdoc by passing -c viewer_pdf="my_pdf_viewer %s &". Use latex-workshop.texdoc.args to do so

"latex-workshop.texdoc.args": [
    "-c",
    "viewer_pdf=\"my_pdf_viewer %s &\"",
    "--view"
]

The No PDF viewer connected... message is related to the recipe not producing a PDF file from the .tex file. Here, it does not matter.

@jlelong jlelong removed the need more info More information needed to identify the issue label Dec 16, 2020
@jlelong
Copy link
Collaborator

jlelong commented Dec 16, 2020

When you run the xdg recipe, is there any error in the Console? Use Toggle Developer tools from the Command Palette to access it.

@jlelong
Copy link
Collaborator

jlelong commented Dec 16, 2020

I did not pay much attention when you mentioned snap. Could it be related to https://forum.snapcraft.io/t/ubuntu-xdg-open-fails-to-launch-browser/1531?

@jlelong jlelong added the external issue Issue with something else than LaTeX-Wokshop label Dec 16, 2020
@FMuro
Copy link
Contributor Author

FMuro commented Dec 17, 2020

You can change the viewer used by texdoc by passing -c viewer_pdf="my_pdf_viewer %s &". Use latex-workshop.texdoc.args to do so

"latex-workshop.texdoc.args": [
    "-c",
    "viewer_pdf=\"my_pdf_viewer %s &\"",
    "--view"
]

This doesn't work either. So strange... It fails exactly in the same way as the default command. It reports to be opening it but nothing shows up. No errors in the console, either with the xdg recipe or with the new arguments for texdoc. Since these new parameters don't work, maybe it's not really related to xdg. (BTW, I had to escape the underscore).

@jlelong
Copy link
Collaborator

jlelong commented Dec 17, 2020

(BTW, I had to escape the underscore)

Which underscore are you talking about? Which viewer did you try for my_pdf_viewer? Did you try the full path to the viewer?

My feeling is that all this is related to snap. Could you install vscode using an alternative approach, for instance a .deb?

@FMuro
Copy link
Contributor Author

FMuro commented Dec 17, 2020

(BTW, I had to escape the underscore)

Which underscore are you talking about?

viewer\_pdf

Which viewer did you try for my_pdf_viewer?

evince and okular

Did you try the full path to the viewer?

I tried with and without, both.

My feeling is that all this is related to snap. Could you install vscode using an alternative approach, for instance a .deb?

Sure, I'll do this this afternoon.

@jlelong
Copy link
Collaborator

jlelong commented Dec 17, 2020

Searching "ubuntu snap open pdf" on Google, you will find a lot of posts on issues opening pdf files from snap applications.

I am afraid we cannot do much on our side, so I am closing the issue. If you come up with solution, please let us know.

@jlelong jlelong closed this as completed Dec 17, 2020
@FMuro
Copy link
Contributor Author

FMuro commented Dec 17, 2020

I've tried with the tar.gz downloaded from VSCode's site and it doesn't work either, so it's not snaps. I thank you a lot for your quick responses. I would leave this open in case someone drops by with an idea.

@jlelong

This comment has been minimized.

@FMuro

This comment has been minimized.

@FMuro
Copy link
Contributor Author

FMuro commented Dec 17, 2020

No, wait a minute. I was trying to run the downloaded binary from the command line in the usual way, but somehow it was another copy of the snap what was launched. Just checked the processes. Closing the snap and running the binary, everything works. Sorry for the confusion. Keep this closed, I'll report to the snap people.

@jlelong
Copy link
Collaborator

jlelong commented Dec 17, 2020

I am so happy, we have finally found the issue!

@FMuro
Copy link
Contributor Author

FMuro commented Dec 17, 2020

Yeah, it might be the same as this one, where I've posted a link to this report: https://forum.snapcraft.io/t/xdg-open-not-working-on-firefox/17670/16

@jlelong jlelong removed the can't reproduce Issue cannot be reproduced label Dec 17, 2020
Repository owner locked as resolved and limited conversation to collaborators Jan 4, 2021
@jlelong jlelong changed the title "View documentation" link on \usepackage{...} hover doesn't work (nor the commands in the palette) "View documentation" link on \usepackage{...} hover doesn't work with Snap version of VSCode Jan 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
external issue Issue with something else than LaTeX-Wokshop
Projects
None yet
Development

No branches or pull requests

3 participants