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

No language available #53

Closed
Duffed opened this issue Aug 22, 2017 · 37 comments
Closed

No language available #53

Duffed opened this issue Aug 22, 2017 · 37 comments

Comments

@Duffed
Copy link

Duffed commented Aug 22, 2017

I can't choose any language at one of my PC's for some reason. It's working properly on my main one tho.
I tried to add other system languages but these also don't show up.

I'm using Windows 10. Latest version of everything.

@bartosz-antosik
Copy link
Owner

What is displayed in the list of available languages (F1 -> `SpellRight: Select Dictionary (Language)')?

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

I can only say "Turn off". No language is listed

@bartosz-antosik
Copy link
Owner

Is this regular or insiders build of VSCode? Could you maybe post VSCode's complete version information?

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

image

@bartosz-antosik
Copy link
Owner

bartosz-antosik commented Aug 22, 2017

Could you please find file extension.js (should be in c:\Users{USER}.vscode\extensions\ban.spellright-1.1.22\src) then change:

global.SPELLRIGHT_DEBUG_OUTPUT = false;

to

global.SPELLRIGHT_DEBUG_OUTPUT = true;

restart VSCode and after a while something like this should appear in the DEBUG CONSOLE:

SpellRight bindings: "spellchecker-win32-1.6.6-x64.node".
SpellRight activated (win32, x64).
Configuration file: "c:\Users\ban.necne\Downloads\tex\test.vscode\spellright.json".

Object
language: "en"
documentTypes: Array[4]
0: "markdown"
1: "latex"
2: "plaintext"
3: "http"
groupDictionaries: true
statusBarIndicator: true
suggestionsInHints: true
addToSystemDictionary: false
ignoreRegExps: Array[1]
0: "/tcp/"
ignoreFiles: Array[0]
notificationClass: "error"
SpellRight read 1 words from "c:\Users\ban.necne\Downloads\tex\test.vscode\spellright.dict" dictionary file.
SpellRight read 0 words from "C:\Users\ban.necne\AppData\Roaming\Code\User\spellright.dict" dictionary file.
RegExp prepare: /tcp/ = /tcp/

Array[23]
0: "en-CA"
1: "en-LR"
2: "en-PH"
3: "en-US"
4: "es-ES"
5: "es-ES_tradnl"
6: "fr-015"
7: "fr-029"
8: "fr-BE"
9: "fr-CA"
10: "fr-CD"
11: "fr-CH"
12: "fr-CI"
13: "fr-CM"
14: "fr-FR"
15: "fr-HT"
16: "fr-LU"
17: "fr-MA"
18: "fr-MC"
19: "fr-ML"
20: "fr-RE"
21: "fr-SN"
22: "pl-PL"
Dictionary (language) set to: "en" in "[none]".
Spelling of "c:\Users\ban.necne\Downloads\tex\test\demo.md" [markdown] STARTED.
Spelling of "c:\Users\ban.necne\Downloads\tex\test\demo.md" [markdown] COMPLETED in 0.443s, 15 errors.

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

Hm nothing appears in the Debugging-Console for me when I change global.SPELLRIGHT_DEBUG_OUTPUT to true.

@bartosz-antosik
Copy link
Owner

But you have restarted VSCode? It won't affect any sooner.

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

Yes I tried it multiple times with different files etc. Completely restarted VS each time. I also made sure the task isn't running in the background.

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

image

@bartosz-antosik
Copy link
Owner

Thanks, sorry I have reminded this. This looks mysterious to me. Is this a first time you have installed the extension on this machine or has this state changed recently?

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

No it's the first time. I've used Sublimetext before because I wasn't able to install extensions at all due to a proxy. Now I'm able to and use my prefered editor VS Code. I'm still using a proxy btw. but I figured how to configure it. Could this be a problem maybe?

@bartosz-antosik
Copy link
Owner

I don't thin proxy would have anything to do with this. But! SpellRight uses native module - this is binary module that e.g. connects to the system spelling API on Windows 10. Maybe your system has some sort of limitations here: Antivirus software? Corporate policies?

Maybe a peek to the system event log?

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

Hm I just went to a coworker who also uses VS Code. He installed spell right and it works just fine for him. We are in the same network with the same limitations.

I looked in the system event log. There is one Application Error from code.exe and one "Windows Error Reporting". Not really sure what these say. But nothing specific. I could still post the content if you want me to. But I can't trigger any event just by starting VS Code.

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

I just noticed when I tried to reinstall your extension that it doesn't really work like it should. The "Restart" button won't appear so I guess the uninstallation does not finish?

@bartosz-antosik
Copy link
Owner

No, do not post anything if you are not convinced it is related.

I really, rally would like to help but feel confused. No one reported anything even remotely similar.

@bartosz-antosik
Copy link
Owner

bartosz-antosik commented Aug 22, 2017

Could you maybe check please whether the files in:

c:\Users{USER}.vscode\extensions\ban.spellright-1.1.22\lib\bin

have installed successfully?

There should be something like this:

spellchecker-darwin-1.6.6-x64.node
spellchecker-linux-1.6.6-ia32.node
spellchecker-linux-1.6.6-x64.node
spellchecker-win32-1.6.6-ia32.node
spellchecker-win32-1.6.6-x64.node
spellchecker-win32-1.7.4-ia32.node
spellchecker-win32-1.7.4-x64.node

@Duffed
Copy link
Author

Duffed commented Aug 22, 2017

Okay thank you very much so far. Guess I will try to reinstall VS Code and see if this helps.

Oh I did not send the comment. Yes I looked it up - all the files are present.

@bartosz-antosik
Copy link
Owner

I will close it for now, post to this thread and I will reopen it shall any more facts surface.

@bartosz-antosik
Copy link
Owner

Just out of curiosity - maybe there are some news regarding this issue? Have you tried to reinstall VSCode? Have it changed anything about extensions not working state?

@Duffed
Copy link
Author

Duffed commented Aug 23, 2017

I reinstalled VS Code and tried the Insider version but it's still not working :/

@sergeevabc
Copy link

sergeevabc commented Nov 30, 2017

No languages are visible here as well.

Win 7 x64, VS Code 1.16.1 portable, SpellRight.
Dictionary files dic & aff are placed into VSCode\Data\code\Dictionaries (see directory structure).

@bartosz-antosik
Copy link
Owner

Hi! Thanks for searching for similar issue and reporting it.

I will have to test i with portable version as to say the truth, I did not.

@sergeevabc
Copy link

@bartosz-antosik, did you get a chance to look into this more thoroughly?

@bartosz-antosik
Copy link
Owner

Yes I had. It has been hopefully resolved. Just some testing on other systems (Linux) is required to be sure that that is the way to go. So in few days it should be done.

BTW. There is a workaround: Just put your dictionaries in:

c:\Users{user-name}\AppData\Roaming\Code\Dictionaries

@sergeevabc
Copy link

sergeevabc commented Dec 1, 2017

The very reason to use portable editions is to avoid polluting C:\Users\… with dependencies. In case you need assistance testing the possible fix on Windows, I’m ready to volunteer. And thanks for investing time into promoting tools that reduce the number of mistakes.

@bartosz-antosik
Copy link
Owner

Yes, of course I understand this. I am just saying, that this would be a workaround.

Version 2.0.12 should work for you. Please give it a test and let me know.

This is however hacking, as VSCode does not give any reasonable way to get User Settings location, (which would work in both portable and installed versions) which is a base for finding the location of the folder you attempted to use.

@sergeevabc
Copy link

sergeevabc commented Dec 2, 2017

I see the dictionary’s name in status bar, but words with mistakes are not emphasized. Why?

Settings are as follows

{
    "editor.renderWhitespace": "none",
    "editor.wordWrap": "bounded",
    "workbench.iconTheme": "vs-minimal",
    "spellright.language": "Russian-English Bilingual",
    "spellright.documentTypes": [
        "markdown",
        "latex",
        "plaintext"
    ]
}

@bartosz-antosik
Copy link
Owner

Are you sure the dictionary is UTF-8? (see notes on this in README.md)

Could you maybe try with some more "classic" dictionary from the link in README.md?

@bartosz-antosik
Copy link
Owner

Please stand by. Something is wrong. Your dictionary seems ok. I have tested this but it seems something is not ok.

@bartosz-antosik
Copy link
Owner

Oh, I would like to repeat the question - could you try with e.g. "English - United States" and "Russian" separately?

It seems like hunspell (which is used in case of Windows 7) spelling library does not support merged dictionaries (see #348 and #425).

@sergeevabc
Copy link

sergeevabc commented Dec 2, 2017

This dictionary works fine with Sublime Text 3, which also uses Hunspell, if that matters.
Nevertheless I downloaded and set English (British) dic & aff, but errors are still not emphasized.

@bartosz-antosik
Copy link
Owner

Yes, I see it does work, although it's not obvious, They may however use some different (e.g. patched) version of hunspell.

This is strange about British dictionary not working. It works for me:

image

Could you maybe try with "English (American).dic" so we would have some common ground?

@sergeevabc
Copy link

sergeevabc commented Dec 2, 2017

I assume it is related to how path hack (6993ae7) is implemented. Put VSCode into subdirectory, which name contains non Latin chars, i.e. C:\Test\Редакторы\VSCode, then words with mistakes are not emphasized. But if I put VSCode into Latin path, i.e. C:\Test\VSCode, then one language dictionaries work fine. It is odd, however, to lock a user like this in the age of Unicode, do you agree?

@bartosz-antosik
Copy link
Owner

I will have a look at this later, but I strongly suppose it is again Hunspell's issue.

The library I relay on (node-spellchecker) uses Hunspell implementation which is quite old and there is no traction towards updating it and I am really to little to do this on my own, as it requires building/testing on a couple of platforms.

@bartosz-antosik
Copy link
Owner

If it shows the dictionaries in VSCode's status bar/quick list then it looks like non Latin paths are OK for me but passing them to Hunspell causes problems. Sorry about that but I am afraid the above holds.

@Blacque-Jacque
Copy link

Blacque-Jacque commented Sep 9, 2019

Possible cause ?
I have this issue on my corporate laptop, but I believe I have isolated it down to the run context for VSCode. If I use runas to launch code with a privileged account (which I use for some PS work) I get no language options. If however I logon with an interactive session, Spell Right works perfectly for the same user account.
image

image

A bit more googling leads me to think this is because the profile is not being loaded as part of the run as, not sure how I can do that & achieve elevation too.
I'll keep testing, see if I can figure it out.

@nicoguaro
Copy link

I have the same problem in Linux Mint 20.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants