Skip to content

Make pyenchant an optional dependency #10

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

Open
codingjoe opened this issue May 3, 2019 · 3 comments
Open

Make pyenchant an optional dependency #10

codingjoe opened this issue May 3, 2019 · 3 comments

Comments

@codingjoe
Copy link
Contributor

Since pyenchant is no longer maintained, I would recommend to make it an optional dependency via extras_require.
That would mean you would need to run pip install msgcheck[pyenchant] or pip install msgcheck[spelling] to install pyenchant and spell checking support.

What do you think @flashcode ? Currently I can't install this package on travis-ci because of the hard pyenchant dependency.

@flashcode
Copy link
Owner

flashcode commented May 3, 2019

Hi @codingjoe,
Maybe a better long-term solution would be to replace pyenchant by something else that is actively maintained?

@codingjoe
Copy link
Contributor Author

@flashcode yes, that would be cool, but I don't see anything on the horizon. The only thing open source tool, that provides proper spell-checking is languagetools. Aspell or hundspell are all pretty mediocre. I think a local spelling dictionary can never get close to an online crowd sourced one.

I would be happy to implement languagetools support, but people would need to set up their own server or provide an API token.

Anyways, I don't know if it isn't a good move to make spell checking optional anyways. No matter how it's implemented, since it will never work without a 3rd party dependency. Something like pip install msgcheck[spelling] would be future prove.

@codingjoe
Copy link
Contributor Author

codingjoe commented May 15, 2019

@flashcode I did some digging. I would recommend to use pyLanguagetool. This seems to be a pretty good. What do you think?

I believe with pyLanguagetool it's a question on whether that package isn't the better place to implement .po file language checking. My advice would be, implement language checking support inside that library and hook into that behavior here. And keep it an extra dependency. Similar to mccabe in flake8.

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

No branches or pull requests

2 participants