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

Dictionary files <pt_BR.dic> & <pt_BR.aff> not recognized. #114

Open
leodrivera opened this issue Aug 23, 2022 · 2 comments
Open

Dictionary files <pt_BR.dic> & <pt_BR.aff> not recognized. #114

leodrivera opened this issue Aug 23, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@leodrivera
Copy link

Description

Dictionary files <pt_BR.dic> & <pt_BR.aff>, from the LibreOffice and Chromium, are not recognized nor loaded as online dictionaries.

Reproduce

I've tried both as online and offline dictionaries:

  • On the online attempt, used the following config in SpellChecker settings, under JupyterLab.

    [
        {
            "id": "pt_BR",
            "aff": "https://raw.githubusercontent.com/LibreOffice/dictionaries/master/pt_BR/pt_BR.aff",
            "dic": "https://raw.githubusercontent.com/LibreOffice/dictionaries/master/pt_BR/pt_BR.dic",
            "name": "Português (Brasil)"
        }
    ]
    
    

    When I try to load the dict, it keeps eternally showing Loading dictionary…

    I also tested using the dict that is shown in the example, and it worked correctly:

[
    {
        "id": "en_US-online",
        "aff": "https://cdn.jsdelivr.net/codemirror.spell-checker/latest/en_US.aff",
        "dic": "https://cdn.jsdelivr.net/codemirror.spell-checker/latest/en_US.dic",
        "name": "My favorite variant of English"
    }
]
  • On the offline attempt, I followed what is described in the README
    After adding the these 2 files (pt_BR.aff and pt_BR.dic), no new dictionary appeared. Tested with the files from both LibreOffice and Chromium repos.

Expected behavior

That the dictionaries were loaded correctly, both by the "online" and "offline" method

Context

  • Python package version:

pip 22.2.2

  • Extension version:

Config dir: /home/leodrivera/venv/data-analise/etc/jupyter
jupyter_server_mathjax enabled
- Validating jupyter_server_mathjax...
jupyter_server_mathjax OK
jupyterlab enabled
- Validating jupyterlab...
jupyterlab 3.4.4 OK
jupyterlab_git enabled
- Validating jupyterlab_git...
jupyterlab_git 0.37.1 OK
jupyterlab_pullrequests enabled
- Validating jupyterlab_pullrequests...
jupyterlab_pullrequests 3.0.2 OK
jupyterlab_spellchecker enabled
- Validating jupyterlab_spellchecker...
jupyterlab_spellchecker 0.7.2 OK
jupyterlab_templates enabled
- Validating jupyterlab_templates...
jupyterlab_templates 0.3.1 OK
nbclassic enabled
- Validating nbclassic...
nbclassic 0.4.3 OK
nbdime enabled
- Validating nbdime...
nbdime 3.1.1 OK
notebook_shim enabled
- Validating notebook_shim...
notebook_shim OK
voila.server_extension enabled
- Validating voila.server_extension...
voila.server_extension OK

  • Operating System and its version:
    Ubuntu 20.04.4 LTS
  • Browser and its version:
    Google Chrome Version 104.0.5112.101 (Official Build) (64-bit)
@leodrivera leodrivera added the bug Something isn't working label Aug 23, 2022
@ocordes
Copy link
Collaborator

ocordes commented Aug 25, 2022

OK, that is understandable ... The reason is that the underlying spellcheck engine has a lot of problems with the aff-files in the case of roman languages with a lot of differentiations due to grammar rules. I had the same problem with the italien dictionary I found for free. The engine is simply enrolling all rules into a list of words, which is huge in your case ;-) we are looking for a better engine which also will solve some other problems, e.g. multi/mixed languages support.

@leodrivera
Copy link
Author

@ocordes
You said on the last comment that you guys were looking after a new engine. Since it has passed almost 3 years and a lot of contributions were made since them, do we still have this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants