James-Yu / LaTeX-Workshop

Boost LaTeX typesetting efficiency with preview, compile, autocomplete, colorize, and more.
MIT License
10.47k stars 519 forks source link

Forward sync not working properly in Mac with Skim. #4210

Closed KingJadeLight closed 4 months ago

KingJadeLight commented 4 months ago

Please fill the following fields with a star (*) and provide as much related information as possible.

Pre-checks*

Please change the following [ ] to [x] for confirmation.

  • [x ] The issue has not been reported in this repository.
  • [ x] The issue remains after disabling all other extensions and restarting Visual Studio Code.
  • [ x] The FAQ cannot address the issue.
  • [ x] The issue is not related to compiling a document, or the document can be successfully compiled in the OS terminal but not in Visual Studio Code with this extension.

Environment*

Please write exact version numbers instead of descriptors such as latest.

  • Operating System: [Mac OS 14.4 (M2 Max)]
  • Visual Studio Code Version: [ 1.87.2 ]
  • LaTeX Workshop Version: [9.19.1]
  • TeX Distribution Version: [TeX Live 2022]

Please list the environment and version number if you are using VSCodium, Snap or Flatpack versions of Visual Studio Code, and/or Visual Studio Code Remote Containers/SSH/WSL.

  • I am not using any of those.

The Issue*

Please briefly describe the issue you come across.

  • Forward PDFsync not working properly.

Reproduction Steps

Please list out the steps to reproduce your bug. Include relevant environmental variables or any other configuration.

  1. Open a simple tex file.
  2. Compile the tex file. cmd+alt+v works, and backward sync also works.
  3. cmd+alt+j works only for the first time. After that, pressing the key bindings will lead me to the skim window, but not to the line, nor highlight the line. Only after I close the skim window will it work again, but only for the first time again.

Expected Behavior

What were you expecting to see? Include any relevant examples or documentation links.

  • Forward sync should work as expected.

Logs

LaTeX Workshop Output*

Please paste the whole log messages below, not parts of ones. The log should start with New log placeholder %WS1% registered.

output is empty.

Developer Tools Console

Please paste the whole log messages below, not parts of ones. This console logs can sometimes be very important in many cases. To access the log, click Help -> Toggle Developer Tools -> Console.

log.ts:417 INFO Started local extension host with pid 9841. workspace.contribution.ts:330 AI generated workspace trust dialog contents not available. (anonymous) @ workspace.contribution.ts:330 log.ts:417 INFO [perf] Render performance baseline is 13ms TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/TeX.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/TeX.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex.latex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/LaTeX.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/LaTeX.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.bibtex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/Bibtex.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/Bibtex.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex.markdown_latex_combined. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/markdown-latex-combined.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/markdown-latex-combined.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope source.cpp.embedded.latex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/cpp-grammar-bailout.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/cpp-grammar-bailout.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/TeX.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/TeX.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex.latex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/LaTeX.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/LaTeX.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.bibtex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/Bibtex.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/Bibtex.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope text.tex.markdown_latex_combined. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/markdown-latex-combined.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/markdown-latex-combined.tmLanguage.json register @ TMScopeRegistry.ts:46 TMScopeRegistry.ts:46 Overwriting grammar scope name to file mapping for scope source.cpp.embedded.latex. Old grammar file: file:///Applications/Visual%20Studio%20Code.app/Contents/Resources/app/extensions/latex/syntaxes/cpp-grammar-bailout.tmLanguage.json. New grammar file: file:///Users/yuliang/.vscode/extensions/james-yu.latex-workshop-9.19.1/syntax/cpp-grammar-bailout.tmLanguage.json register @ TMScopeRegistry.ts:46 webviewElement.ts:511 An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing. mountTo @ webviewElement.ts:511 webviewElement.ts:511 An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing. mountTo @ webviewElement.ts:511



## Anything Else?
> _Add any other context about the problem below._
- None.
James-Yu commented 4 months ago

We don’t provide support to external pdf viewers unfortunately.

jlelong commented 4 months ago

As @James-Yu said, we do not provide official support for external viewers. Yet, I am interesting in the logs of the extension when you call forward synctex both when it works and when it does not. If quitting and relaunching Skim fixes the issue, the problem is likely to come from Skim not from the extension.