nltk / nltk.github.com

NLTK Website
https://www.nltk.org
62 stars 47 forks source link

Don't encourage using sudo for installation. Encourage using virtualenv instead #13

Closed x-ji closed 3 years ago

x-ji commented 6 years ago

Currently the best practice of installing Python packages is to create separate virtual environments for specific projects. However, http://www.nltk.org/install.html suggests running sudo pip install -U nltk, which IMO is not a piece of good advice. Instructions shouldn't contain sudo in them.

Maybe this is done with the consideration that telling the users to create virtual environments can cause further complications when they're using it, since many are still not familiar with the concept. However, would it be at least possible to suggest this as an alternative? Also I'm not sure if there would be some bugs and confusion for the users if they attempt to use sudo with pip, since there seem to be some problems with this on the latest MacOS.

An example is spaCy's getting started guide: https://spacy.io/usage/

purificant commented 3 years ago

Thank you for your feedback. The installation instructions now include pip install --user -U nltk which install the package in user's local directory (https://docs.python.org/3/library/site.html#site.USER_BASE) without requiring privilege elevation via sudo.