Skip to content

DOC: do not suggest to sudo pip install Matplotlib #23024

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

Merged
merged 1 commit into from
May 10, 2022

Conversation

tacaswell
Copy link
Member

PR Summary

Skimming the discussion in #23009 I noticed that we are suggesting to use sudo + pip to install things 😱 which is something that you should never do.

PR Checklist

Tests and Styling

  • [N/A] Has pytest style unit tests (and pytest passes).
  • [N/A] Is Flake 8 compliant (install flake8-docstrings and run flake8 --docstring-convention=all).

Documentation

  • [N/A] New features are documented, with examples if plot related.
  • [N/A] New features have an entry in doc/users/next_whats_new/ (follow instructions in README.rst there).
  • [N/A] API changes documented in doc/api/next_api_changes/ (follow instructions in README.rst there).
  • [N/A] Documentation is sphinx and numpydoc compliant (the docs should build without error).

@tacaswell tacaswell added this to the v3.6.0 milestone May 9, 2022
@@ -291,8 +291,6 @@ from the Terminal.app command line::

python3 -m pip install matplotlib

(``sudo python3.6 ...`` on Macports).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we just drop this altogether? We don't give instructions for apt or other package managers, do we? I think we should doc pip and conda and if someone wants to install with macports they can ask macports how to do it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We give basic installation commands (like sudo apt install python-matplotlib) for some package managers, but little package-manager specific setup instructions.

https://github.com/matplotlib/matplotlib/blob/main/doc/users/installing/index.rst#linux-package-manager

This does seem to be a common problem for OSX users, so maybe it might be worth leaving in the installation guide and adding @oscargus suggestion.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I somewhat disagree, or at the least we need to rephrase the docs here. If I was a naive user who had not really heard of conda I'd skip the conda section (what's that?) and go to the MacOS section. Then I would be using crazy macports or brew installs, or worse trying to use the system python, when really by far the easiest solution on a Mac (or most other platforms) is to use conda. All this stuff should be hidden behind links that say "manual OS-specific installs, not recommended".

Copy link
Contributor

@greglucas greglucas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merging as an improvement. Reorganizing the sections/adding brew and macport things can be done in a follow-up PR.

@greglucas greglucas merged commit 826579c into matplotlib:main May 10, 2022
@tacaswell tacaswell deleted the doc_remove_sudo branch May 10, 2022 02:05
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

Successfully merging this pull request may close these issues.

5 participants