LTeX Language Server: LSP language server for LanguageTool :mag::heavy_check_mark: with support for LaTeX :mortar_board:, Markdown :pencil:, and others
Removing the babel package will cause the language detection to default to English. In this case, you get the message info: 'Teset': Possible spelling mistake found. [MORFOLOGIK_RULE_EN_US].
Adding the babel package sets the language accordingly, causing the document to contain no spelling mistakes.
Removing the math expression triggers an orthographic error (info: 'Teset': Encontrado possível erro de ortografia. [HUNSPELL_RULE]).
Therefore (and for some additional tests I performed to verify my assumption) I assume that this error seems to occur every time, the language check passes successfully without anything to report.
Aug 01, 2022 12:49:14 PM org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor run
SEVERE: java.io.IOException: Stream closed
org.eclipse.lsp4j.jsonrpc.JsonRpcException: java.io.IOException: Stream closed
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:122)
at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:113)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.io.IOException: Stream closed
at java.base/java.io.BufferedInputStream.getBufIfOpen(BufferedInputStream.java:176)
at java.base/java.io.BufferedInputStream.read(BufferedInputStream.java:275)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:79)
... 7 more
Describe the bug In portuguese, after the first use of the math delimiters
$$
, Ltex stops working (both ltex-ls and ltex-cli).Steps to reproduce
$$
Expected behavior It should work normally like it does when the line
\usepackage[brazilian]{babel}
is removed.Sample document
LTeX configuration Default lspconfig for neovim.
LTeX LS log
Version information
Additional context/information LanguageTool seems to be working on TexStudio.
Removing the
babel
package will cause the language detection to default to English. In this case, you get the messageinfo: 'Teset': Possible spelling mistake found. [MORFOLOGIK_RULE_EN_US]
. Adding thebabel
package sets the language accordingly, causing the document to contain no spelling mistakes. Removing the math expression triggers an orthographic error (info: 'Teset': Encontrado possível erro de ortografia. [HUNSPELL_RULE]
).Therefore (and for some additional tests I performed to verify my assumption) I assume that this error seems to occur every time, the language check passes successfully without anything to report.
Check out this MWE:
Then run
ltex-cli mwe_en.tex
and see the result:Hey @valentjn, could you have another look at this issue? Currently, it's impossible to
ltex
with Portuguese.Thanks!